google app engine session

*爱你&永不变心* 提交于 2020-01-12 07:50:10

问题


  1. what is java app engine,default session time out ?
  2. will that be any bad impact if we set sesion time out to very very long time, since google app engine session is just store in datastore by default? (just like facebook, each time you go to the page, the session still exist forever) ?

回答1:


  1. Default session timeout is set to 30 Minutes. (you can verify it calling getMaxInactiveInterval method)
  2. With that fairly limited info about your app, I don't see any impact.
    Using setMaxInactiveInterval(-1) indicates that the Session should never timeout. Keep in mind that you also need to overwrite the JSESSIONID cookie MaxAge to prevent to lose the Session when the browser is closed.



回答2:


  1. I've just tested on my GAE webapp and the default timeout is getMaxInactiveInterval()=86400 (s) = 24 hours = 1 day


来源:https://stackoverflow.com/questions/4496144/google-app-engine-session

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!