History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: JRUBY-1685
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Critical Critical
Assignee: Unassigned
Reporter: Vladimir Sizikov
Votes: 0
Watchers: 1
Operations

If you were logged in you would be able to see more operations.
JRuby

Can't run Rails 2.0 app due to exception

Created: 07/Dec/07 01:07 PM   Updated: 22/Dec/07 06:26 AM
Component/s: Core Classes/Modules
Affects Version/s: None
Fix Version/s: JRuby 1.0.3, JRuby 1.1RC1

Time Tracking:
Not Specified

File Attachments: 1. File rails2_exception.diff (0.7 kb)

Environment: Latest JRuby from trunk, 1.1b1, Rails v2.0.1

Patch Submitted: Yes


 Description  « Hide
Basically, any time I access the standard http://fedora:3000/rails/info/properties, I get the exception with the following stacktrace:

/opt/work/jruby/lib/ruby/gems/1.8/gems/activerecord-2.0.1/lib/active_record/vendor/mysql.rb:111:in `real_connect'
/opt/work/jruby/lib/ruby/gems/1.8/gems/activerecord-2.0.1/lib/active_record/connection_adapters/mysql_adapter.rb:471:in `connect'
/opt/work/jruby/lib/ruby/gems/1.8/gems/activerecord-2.0.1/lib/active_record/connection_adapters/mysql_adapter.rb:165:in `initialize'
/opt/work/jruby/lib/ruby/gems/1.8/gems/activerecord-2.0.1/lib/active_record/connection_adapters/mysql_adapter.rb:88:in `new'
/opt/work/jruby/lib/ruby/gems/1.8/gems/activerecord-2.0.1/lib/active_record/connection_adapters/mysql_adapter.rb:88:in `mysql_connection'
/opt/work/jruby/lib/ruby/gems/1.8/gems/activerecord-2.0.1/lib/active_record/connection_adapters/abstract/connection_specification.rb:291:in `connection='
/opt/work/jruby/lib/ruby/gems/1.8/gems/activerecord-2.0.1/lib/active_record/connection_adapters/abstract/connection_specification.rb:259:in `retrieve_connection'
/opt/work/jruby/lib/ruby/gems/1.8/gems/activerecord-2.0.1/lib/active_record/connection_adapters/abstract/connection_specification.rb:78:in `connection'
/opt/work/jruby/lib/ruby/gems/1.8/gems/activerecord-2.0.1/lib/active_record/query_cache.rb:8:in `cache'
/opt/work/jruby/lib/ruby/gems/1.8/gems/actionpack-2.0.1/lib/action_controller/caching.rb:677:in `perform_action_with_caching'
/opt/work/jruby/lib/ruby/gems/1.8/gems/actionpack-2.0.1/lib/action_controller/caching.rb:677:in `process'
/opt/work/jruby/lib/ruby/gems/1.8/gems/actionpack-2.0.1/lib/action_controller/filters.rb:685:in `process_with_filters'
/opt/work/jruby/lib/ruby/gems/1.8/gems/actionpack-2.0.1/lib/action_controller/session_management.rb:123:in `process_with_session_management_support'
/opt/work/jruby/lib/ruby/gems/1.8/gems/actionpack-2.0.1/lib/action_controller/base.rb:388:in `process'
/opt/work/jruby/lib/ruby/gems/1.8/gems/actionpack-2.0.1/lib/action_controller/dispatcher.rb:171:in `handle_request'
/opt/work/jruby/lib/ruby/gems/1.8/gems/actionpack-2.0.1/lib/action_controller/dispatcher.rb:115:in `dispatch'
/opt/work/jruby/lib/ruby/gems/1.8/gems/actionpack-2.0.1/lib/action_controller/dispatcher.rb:126:in `dispatch_cgi'
/opt/work/jruby/lib/ruby/gems/1.8/gems/actionpack-2.0.1/lib/action_controller/dispatcher.rb:9:in `dispatch'
/opt/work/jruby/lib/ruby/gems/1.8/gems/mongrel-1.1.1-jruby/lib/mongrel/rails.rb:76:in `process'
/opt/work/jruby/lib/ruby/gems/1.8/gems/mongrel-1.1.1-jruby/lib/mongrel/rails.rb:74:in `synchronize'
/opt/work/jruby/lib/ruby/gems/1.8/gems/mongrel-1.1.1-jruby/lib/mongrel/rails.rb:74:in `process'
/opt/work/jruby/lib/ruby/gems/1.8/gems/mongrel-1.1.1-jruby/lib/mongrel/rails.rb:74:in `process_client'
/opt/work/jruby/lib/ruby/gems/1.8/gems/mongrel-1.1.1-jruby/lib/mongrel.rb:154:in `each'
/opt/work/jruby/lib/ruby/gems/1.8/gems/mongrel-1.1.1-jruby/lib/mongrel.rb:154:in `process_client'
/opt/work/jruby/lib/ruby/gems/1.8/gems/mongrel-1.1.1-jruby/lib/mongrel.rb:154:in `run'
/opt/work/jruby/lib/ruby/gems/1.8/gems/mongrel-1.1.1-jruby/lib/mongrel.rb:281:in `initialize'

This is due to fact that JRuby's TCPSocket can't handle nil as a host parameter, while MRI can.

The proposed patch fixes the porblem



 All   Comments   Work Log   Change History      Sort Order: Ascending order - Click to sort in descending order
There are no comments yet on this issue.