Il 07/03/18 15:51, Anthony ha scritto:
> Be aware, that will require a database select on every request. If you
> want to minimize the database hits, you could also store in the
> session the time of the last database lookup, and then only check the
> database every X minutes (the tradeoff being that it could take up to
> X minutes to disable the first session after the second session has
> begun -- if you must ensure zero overlap of sessions, then you'll have
> to do the database check on every request).

What if I cache on disk the result of a function that returns the
session id and I check if it corresponds to the real value? In this case
how can I force to logout all other user logged in with the same
username? I would prefer to give precedence to the last one who login.



- (Documentation)
- (Source code)
- (Report Issues)
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
For more options, visit

Reply via email to