# Dump format error - stale\_session\_check

**URL:** <https://www.ruby-forum.com/t/dump-format-error-stale-session-check/154708>\
**Category:** JRuby\
**Created:** [December 3, 2008, 6:03am UTC](https://www.ruby-forum.com/t/dump-format-error-stale-session-check/154708 "2008-12-03T06:03:44Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![vmvipin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/v/c0e974/32.png) [@vmvipin](https://www.ruby-forum.com/u/vmvipin)\
**Post date:** [December 3, 2008, 6:03am UTC](https://www.ruby-forum.com/t/dump-format-error-stale-session-check/154708/1 "2008-12-03T06:03:44Z")

</div>

Hi all,

Am using jruby with rails 2.2.2. Its starting successfully and running.  
After 3 or 4 clicks am getting this error.

vipin$ jruby -S jetty\_rails -e production -p 3000  
JRuby limited openssl loaded. gem install jruby-openssl for full  
support.  
[http://wiki.jruby.org/wiki/JRuby\_Builtin\_OpenSSL](http://wiki.jruby.org/wiki/JRuby_Builtin_OpenSSL)  
2008-12-03 10:20:28.092::INFO: Logging to STDERR via  
org.mortbay.log.StdErrLog  
starting 3000  
2008-12-03 10:20:28.161::INFO: jetty-6.1.9  
2008-12-03 10:20:28.394::INFO: NO JSP Support for /, did not find  
org.apache.jasper.servlet.JspServlet  
2008-12-03 10:20:29.883:/:INFO: Info: using runtime pool timeout of 30  
seconds  
2008-12-03 10:20:29.883:/:INFO: Info: received min runtimes = 1  
2008-12-03 10:20:29.883:/:INFO: Info: received max runtimes = 5  
JRuby limited openssl loaded. gem install jruby-openssl for full  
support.  
[http://wiki.jruby.org/wiki/JRuby\_Builtin\_OpenSSL](http://wiki.jruby.org/wiki/JRuby_Builtin_OpenSSL)  
GLoc v1.1 running in development mode. Strings can be modified at  
runtime.  
2008-12-03 10:20:38.209:/:INFO: Info: add application to the pool. size  
now = 1  
2008-12-03 10:20:38.226::INFO: Started  
SelectChannelConnector@0.0.0.0:3000

2008-12-03 10:21:21.020:/:INFO: /!\ FAILSAFE /!\ Wed Dec 03 10:21:21  
+0530 2008  
Status: 500 Internal Server Error  
dump format error( )  
/Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action\_controller/cgi\_process.rb:146:in  
`stale_session_check!' /Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/cgi_process.rb:78:in `session’  
/Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action\_controller/base.rb:1205:in  
`assign_shortcuts' /Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/flash.rb:166:in `assign\_shortcuts\_with\_flash’  
/Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action\_controller/base.rb:519:in  
`process' /Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/filters.rb:606:in `process\_with\_filters’  
/Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action\_controller/session\_management.rb:134:in  
`process_with_session_management_support' /Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/base.rb:392:in `process’  
/Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action\_controller/dispatcher.rb:183:in  
`handle_request' /Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:110:in `dispatch\_unlocked’  
/Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action\_controller/dispatcher.rb:120:in  
`dispatch' /Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:132:in `dispatch\_cgi’  
/Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action\_controller/dispatcher.rb:39:in  
`dispatch' file:/Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/jetty-rails-0.6/lib/jruby-rack-0.9.2.jar!/rack/adapter/rails.rb:37:in `serve\_rails’  
file:/Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/jetty-rails-0.6/lib/jruby-rack-0.9.2.jar!/rack/adapter/rails.rb:44:in  
`call' file:/Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/jetty-rails-0.6/lib/jruby-rack-0.9.2.jar!/jruby/rack/rails.rb:145:in `call’  
file:/Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/jetty-rails-0.6/lib/jruby-rack-0.9.2.jar!/rack/handler/servlet.rb:17:in  
`call’

What could be wrong?  
Vipin

---

<div class="post-metadata">

**Author:** ![vmvipin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/v/c0e974/32.png) [@vmvipin](https://www.ruby-forum.com/u/vmvipin)\
**Post date:** [December 6, 2008, 4:51am UTC](https://www.ruby-forum.com/t/dump-format-error-stale-session-check/154708/2 "2008-12-06T04:51:05Z")

</div>

Hi Wyatt,

Thanks a lot… let me check with my code regarding BigDecimal 🙂

Vipin

Wyatt Kapastin wrote:

> Hi,
> 
> I was having this same issue when I upgraded my JRuby/Rails app to JRuby  
> 1.1.5. I finally figured out that it doesn’t like it when you put a  
> BigDecimal in the session. I had the code below, where account.balance  
> was a BigDecimal:
> 
> session[:balance] = account.balance
> 
> When I changed it to following it resolved the issue:
> 
> session[:balance] = account.balance.to\_f
> 
> This issue does not exist in JRuby 1.1.4 or trunk - it seems to be  
> isolated to 1.1.5. I’m also not sure if there are other data types that  
> it doesn’t like in the session… This issue cost me about 2 days, so I  
> hope this helps you!
> 
> -Wyatt

---

<div class="post-metadata">

**Author:** ![vmvipin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/v/c0e974/32.png) [@vmvipin](https://www.ruby-forum.com/u/vmvipin)\
**Post date:** [December 6, 2008, 3:14am UTC](https://www.ruby-forum.com/t/dump-format-error-stale-session-check/154708/3 "2008-12-06T03:14:33Z")

</div>

Hi,

I was having this same issue when I upgraded my JRuby/Rails app to JRuby  
1.1.5. I finally figured out that it doesn’t like it when you put a  
BigDecimal in the session. I had the code below, where account.balance  
was a BigDecimal:

session[:balance] = account.balance

When I changed it to following it resolved the issue:

session[:balance] = account.balance.to\_f

This issue does not exist in JRuby 1.1.4 or trunk - it seems to be  
isolated to 1.1.5. I’m also not sure if there are other data types that  
it doesn’t like in the session… This issue cost me about 2 days, so I  
hope this helps you!

-Wyatt

Vipin Vm wrote:

> Hi all,
> 
> Am using jruby with rails 2.2.2. Its starting successfully and running.  
> After 3 or 4 clicks am getting this error.
> 
> vipin$ jruby -S jetty\_rails -e production -p 3000  
> JRuby limited openssl loaded. gem install jruby-openssl for full  
> support.  
> [http://wiki.jruby.org/wiki/JRuby\_Builtin\_OpenSSL](http://wiki.jruby.org/wiki/JRuby_Builtin_OpenSSL)  
> 2008-12-03 10:20:28.092::INFO: Logging to STDERR via  
> org.mortbay.log.StdErrLog  
> starting 3000  
> 2008-12-03 10:20:28.161::INFO: jetty-6.1.9  
> 2008-12-03 10:20:28.394::INFO: NO JSP Support for /, did not find  
> org.apache.jasper.servlet.JspServlet  
> 2008-12-03 10:20:29.883:/:INFO: Info: using runtime pool timeout of 30  
> seconds  
> 2008-12-03 10:20:29.883:/:INFO: Info: received min runtimes = 1  
> 2008-12-03 10:20:29.883:/:INFO: Info: received max runtimes = 5  
> JRuby limited openssl loaded. gem install jruby-openssl for full  
> support.  
> [http://wiki.jruby.org/wiki/JRuby\_Builtin\_OpenSSL](http://wiki.jruby.org/wiki/JRuby_Builtin_OpenSSL)  
> GLoc v1.1 running in development mode. Strings can be modified at  
> runtime.  
> 2008-12-03 10:20:38.209:/:INFO: Info: add application to the pool. size  
> now = 1  
> 2008-12-03 10:20:38.226::INFO: Started  
> SelectChannelConnector@0.0.0.0:3000
> 
> 2008-12-03 10:21:21.020:/:INFO: /!\ FAILSAFE /!\ Wed Dec 03 10:21:21  
> +0530 2008  
> Status: 500 Internal Server Error  
> dump format error( )  
> /Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action\_controller/cgi\_process.rb:146:in  
> `stale_session_check!' /Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/cgi_process.rb:78:in `session’  
> /Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action\_controller/base.rb:1205:in  
> `assign_shortcuts' /Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/flash.rb:166:in `assign\_shortcuts\_with\_flash’  
> /Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action\_controller/base.rb:519:in  
> `process' /Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/filters.rb:606:in `process\_with\_filters’  
> /Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action\_controller/session\_management.rb:134:in  
> `process_with_session_management_support' /Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/base.rb:392:in `process’  
> /Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action\_controller/dispatcher.rb:183:in  
> `handle_request' /Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:110:in `dispatch\_unlocked’  
> /Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action\_controller/dispatcher.rb:120:in  
> `dispatch' /Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:132:in `dispatch\_cgi’  
> /Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action\_controller/dispatcher.rb:39:in  
> `dispatch' file:/Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/jetty-rails-0.6/lib/jruby-rack-0.9.2.jar!/rack/adapter/rails.rb:37:in `serve\_rails’  
> file:/Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/jetty-rails-0.6/lib/jruby-rack-0.9.2.jar!/rack/adapter/rails.rb:44:in  
> `call' file:/Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/jetty-rails-0.6/lib/jruby-rack-0.9.2.jar!/jruby/rack/rails.rb:145:in `call’  
> file:/Developer/ruby/jruby-1.1.5/lib/ruby/gems/1.8/gems/jetty-rails-0.6/lib/jruby-rack-0.9.2.jar!/rack/handler/servlet.rb:17:in  
> `call’
> 
> What could be wrong?  
> Vipin

---

<div class="post-metadata">

**Author:** ![vmvipin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/v/c0e974/32.png) [@vmvipin](https://www.ruby-forum.com/u/vmvipin)\
**Post date:** [February 3, 2009, 2:50pm UTC](https://www.ruby-forum.com/t/dump-format-error-stale-session-check/154708/4 "2009-02-03T14:50:57Z")

</div>

I have this same issue with Jruby 1.1.5 running RoR 2.2.2. It is a  
known issue as documented here -  
[http://jira.codehaus.org/browse/JRUBY-3228](http://jira.codehaus.org/browse/JRUBY-3228), which is unassigned as of  
the moment.

Vipin Vm wrote:

> Hi Wyatt,
> 
> Thanks a lot… let me check with my code regarding BigDecimal 🙂
> 
> Vipin
