On Wed, Apr 23, 2014 at 3:59 PM, wilk <[email protected]> wrote:

> Could you give an example of a serializer object wich will record the
> session on a dict in memory for example ?
>

https://gist.github.com/mmerickel/8035611

 Unfortunately there's one little quirk that you can't reuse the session
id, so it changes per request, which may be a problem if you're using a
session in combination with concurrent ajax requests (a problem with any
blob-based session storage really). This could be fixed by using
get_current_request() or by modifying the Pyramid api slightly to pass the
request into the serializer.

Nice part about this is that the session cookie is securely tracked by
Pyramid and you're only responsible for cleaning up old sessions in the
backend.

-- 
You received this message because you are subscribed to the Google Groups 
"pylons-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/pylons-discuss.
For more options, visit https://groups.google.com/d/optout.

Reply via email to