Frederick C. a Ã©crit, le 07/09/2008 03:44 PM :
Don’t use the cookie store (which is limited by the fact that
cookies should not be > 4k)
And I should add that sticking lots of data in the session isn’t
usually a great idea.
Indeed, in most cases replacing AR objects with their ids is enough.
There are cases where that isn’t enough though (like storing a long
temporary list of ids in session) in this case you have the choice of
storing whatever is too big locally (on disk or in DB) with a reference
to it in the session but it may not be better than simply using the
activerecord/memcache/… sessions. It depends on your actual use case.