-
Notifications
You must be signed in to change notification settings - Fork 240
Sessions
Geddy has sessions built in, and offers a number of different ways to persist session-data:
-
Memory (the default): useful mostly for development. Session-data is saved at the worker-process level, so in-memory sessions cannot be used with a Geddy app and multiple worker-processes. Also, all sessions disappear when the app is restarted.
-
Cookie: Session-data is passed back and forth in (encrypted) cookies in the request/response. Sessions will persist when the app restarts, but the amount of data you can save in a session is much more limited.
-
Memcache: Requires a Memcache server or cluster. Uses Arnout Kazemier's 'memcached' module.
-
Redis: Requires a Redis server or cluster. Uses Matt Ranney's 'redis' module.
You will probably want to develop with in-memory sessions, and use cookie, Memcache, or Redis sessions for production (depending on how much data you want to save in the session).