[development] sessions problem
Larry Garfield
larry at garfieldtech.com
Wed Dec 24 03:15:11 UTC 2008
On Tuesday 23 December 2008 8:53:49 pm Sheryl (Permutations Software) wrote:
*snip*
> To fix this problem, I need to know how Drupal decides what to save as
> sessions data, and in what source code file this is done (so I can modify
> it to ignore phpFreeChat). Could someone give me some insight and point me
> in the right direction? My community really likes phpFreeChat and I don't
> want to lose my hosting account.
>
>
>
> Thank you in advance.
Drupal's session handling is really not that complicated. It saves whatever
is in $_SESSION to the sessions table at the end of each page request, per PHP
standard. That could be almost no data or could be a megabyte of crap
depending on what modules decide to stick stuff in there.
If the phpFreeChat module has a lot of data in there, I'd look at the module
to see what it's doing with $_SESSION. It may be storing data there it
doesn't need to and/or not removing data later on when it doesn't need it
anymore. It really depends on the modules you have installed. OG, for
instance, stores the complete node of the current group a user is viewing in
the session, which makes the session table get really big (far too big, IMO).
Other modules don't store more than int or two in the session, if that.
If you look in includes/session.inc you'll see the entirety of the code. As I
said, it's really not very complex.
--
Larry Garfield
larry at garfieldtech.com
More information about the development
mailing list