szimek
2008-Apr-17 19:24 UTC
Do I need to use sessions if I don''t store anything in them?
Hi, I got very small app that has user part and admin part. The problem is that after a while the sessions table has ~150mb. I don''t really need to store any user data in the session for the user part. I only need it for the admin part. Can I simply turn session off in controllers from the user part? Are there any drawbacks of turning the session off? Regards --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Frederick Cheung
2008-Apr-17 19:33 UTC
Re: Do I need to use sessions if I don''t store anything in them?
On 17 Apr 2008, at 20:24, szimek wrote:> > Hi, > > I got very small app that has user part and admin part. The problem is > that after a while the sessions table has ~150mb. I don''t really need > to store any user data in the session for the user part. I only need > it for the admin part. > > Can I simply turn session off in controllers from the user part? Are > there any drawbacks of turning the session off? >Just stick session :off in the relevant controllers. Other than not being able to use it, no. Fred> Regards > >--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
szimek
2008-Apr-17 20:08 UTC
Re: Do I need to use sessions if I don''t store anything in them?
On 17 Kwi, 21:33, Frederick Cheung <frederick.che...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> On 17 Apr 2008, at 20:24, szimek wrote: > > > > > Hi, > > > I got very small app that has user part and admin part. The problem is > > that after a while the sessions table has ~150mb. I don''t really need > > to store any user data in the session for the user part. I only need > > it for the admin part. > > > Can I simply turn session off in controllers from the user part? Are > > there any drawbacks of turning the session off? > > Just stick session :off > in the relevant controllers. > Other than not being able to use it, no. > > Fred > > > RegardsThanks --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
AndyV
2008-Apr-18 12:43 UTC
Re: Do I need to use sessions if I don''t store anything in them?
If you''re having non-admin users login then obviously you''re going to lose the ability to remember who they are unless you make their id part of every page/postback. On Apr 17, 4:08 pm, szimek <szi...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> On 17 Kwi, 21:33, Frederick Cheung <frederick.che...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > > > On 17 Apr 2008, at 20:24, szimek wrote: > > > > Hi, > > > > I got very small app that has user part and admin part. The problem is > > > that after a while the sessions table has ~150mb. I don''t really need > > > to store any user data in the session for the user part. I only need > > > it for the admin part. > > > > Can I simply turn session off in controllers from the user part? Are > > > there any drawbacks of turning the session off? > > > Just stick session :off > > in the relevant controllers. > > Other than not being able to use it, no. > > > Fred > > > > Regards > > Thanks--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Russell Norris
2008-Apr-21 11:42 UTC
Re: Do I need to use sessions if I don''t store anything in them?
Also, you''ll lose the ability to have store messages in the flash. (flash[:whatever]) messages. In case that''s something you''re using currently. RSL On Fri, Apr 18, 2008 at 8:43 AM, AndyV <AndyVanasse-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> > If you''re having non-admin users login then obviously you''re going to > lose the ability to remember who they are unless you make their id > part of every page/postback. > > On Apr 17, 4:08 pm, szimek <szi...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > On 17 Kwi, 21:33, Frederick Cheung <frederick.che...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > > > > > > > On 17 Apr 2008, at 20:24, szimek wrote: > > > > > > Hi, > > > > > > I got very small app that has user part and admin part. The problem > is > > > > that after a while the sessions table has ~150mb. I don''t really > need > > > > to store any user data in the session for the user part. I only need > > > > it for the admin part. > > > > > > Can I simply turn session off in controllers from the user part? Are > > > > there any drawbacks of turning the session off? > > > > > Just stick session :off > > > in the relevant controllers. > > > Other than not being able to use it, no. > > > > > Fred > > > > > > Regards > > > > Thanks > > >--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---