GithubHelp home page GithubHelp logo

beaker_redis's Introduction

一、当前使用说明:

python setup.py install

或者

  1. python setup.py sdist
  2. sudo pip install dist/beaker_redis-1.0.2.tar.gz

第1句打包源码 第2句使用pip安装

二、配置

对pyramid的项目ini文件类似如下配置:

``` ; For pyramid_beaker ;session.type = mongodb ;session.url = mongodb://192.168.1.245:27017/beaker.sessions

session.type = redis ;session.url = [email protected]:5379/1 session.url = sentinel:[email protected]:25379/session7/1 session.hkey_prefix = session.key =JSESSIONID session.block_custom_class = true ```

*注意:*

  1. 可以实现共享,但是判断登录条件之类,需要采用共同的字段才能保证
  2. 自定义class对象有些问题,java的自定义对象python无法识别,但是python不会破坏,可以继续使用。python的自定义对象会被java破坏,所以别用
  3. 要避免同样的session key存储不一样的东西,那样会互相破坏
  4. Java的自定义对象需要实现Serializable接口才可以设置到session,否则异常

beaker_redis's People

Contributors

zzzsochi avatar duanjingyu007 avatar frgtn avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.