This suddenly started happening to my app today. No code changes, so I expect that this has something to do with a server change. I''m using Login Engine and ActiveRecord sessions. LE stores the whole user object in the session, then pulls it out as needed with UserController#current_user. Out of the blue today this starts failing with the infamous "you''re serializing AR objects into the db so you''re getting a ''marshal data too short'' error". No code has changed in this app in weeks and suddenly I''m getting this error. I can clear all sessions from the DB, do something to create a session and store a user, then hit another page that pulls the user out of the DB and I get a Application Error with the log saying "marshal data too short." Thoughts? thx, --dwf --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Danny Burkes
2006-Oct-20 03:37 UTC
Re: Login Engine, user object "marshal data too short"?
> I can clear all sessions from the DB, do something to create a session > and store a user, then hit another page that pulls the user out of the > DB and I get a Application Error with the log saying "marshal data too > short."If you are using ActiveRecord session store, you may need to change the type of your :data column in the :sessions table. You can do this by creating a migration that ups the :limit on the :data column, like so: def self.up change_column :sessions, :data, :text, { :limit => 1.megabyte } end - Danny -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---