StackOverflowError with Net::HTTP request method patched by rest-client gem ---------------------------------------------------------------------------
Key: JRUBY-5951 URL: https://jira.codehaus.org/browse/JRUBY-5951 Project: JRuby Issue Type: Bug Components: Ruby 1.8.7 Affects Versions: JRuby 1.6.3, JRuby 1.5.2 Environment: Cent OS, SUN JDK1.6_24 x64 bit JRuby 1.5.2, JRuby-Rack deployed in Tomcat Rails2.3.9 Reporter: mv We saw this error in our production log when we restarted it. The server(Tomcat/Jruby-rack/Rails2.3.9) was running fine before restarting it. The error kept on showing up until we restarted it. The Net::HTTP.request method is patched inside the rest-client gem as shown below. # File 'lib/restclient/net_http_ext.rb', line 12 12 def request(req, body=nil, &block) 13 if body != nil && body.respond_to?(:read) 14 req.body_stream = body 15 return __request__(req, nil, &block) 16 else 17 return __request__(req, body, &block) 18 end 19 end More at. http://rubydoc.info/gems/rest-client/1.6.0/Net/HTTP#request-instance_method Java::JavaLang::StackOverflowError (): org.jruby.javasupport.util.RuntimeHelpers.processBlockArgument(RuntimeHelpers.java:760) ruby.jit.request_AE1E09B26A77A19AF8D0318FDFFFD30E683C42BC.__file__(net_http_ext.rb) ruby.jit.request_AE1E09B26A77A19AF8D0318FDFFFD30E683C42BC.__file__(net_http_ext.rb) org.jruby.ast.executable.AbstractScript.__file__(AbstractScript.java:43) org.jruby.internal.runtime.methods.JittedMethod.call(JittedMethod.java:204) org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:199) org.jruby.internal.runtime.methods.AliasMethod.call(AliasMethod.java:91) org.jruby.runtime.callsite.CachingCallSite.callBlock(CachingCallSite.java:195) org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:202) ruby.jit.request_AE1E09B26A77A19AF8D0318FDFFFD30E683C42BC.__file__(net_http_ext.rb:17) ruby.jit.request_AE1E09B26A77A19AF8D0318FDFFFD30E683C42BC.__file__(net_http_ext.rb) org.jruby.ast.executable.AbstractScript.__file__(AbstractScript.java:43) org.jruby.internal.runtime.methods.JittedMethod.call(JittedMethod.java:204) org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:199) org.jruby.internal.runtime.methods.AliasMethod.call(AliasMethod.java:91) org.jruby.runtime.callsite.CachingCallSite.callBlock(CachingCallSite.java:195) org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:202) ruby.jit.request_AE1E09B26A77A19AF8D0318FDFFFD30E683C42BC.__file__(net_http_ext.rb:17) ruby.jit.request_AE1E09B26A77A19AF8D0318FDFFFD30E683C42BC.__file__(net_http_ext.rb) org.jruby.ast.executable.AbstractScript.__file__(AbstractScript.java:43) org.jruby.internal.runtime.methods.JittedMethod.call(JittedMethod.java:204) org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:199) org.jruby.internal.runtime.methods.AliasMethod.call(AliasMethod.java:91) org.jruby.runtime.callsite.CachingCallSite.callBlock(CachingCallSite.java:195) org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:202) ruby.jit.request_AE1E09B26A77A19AF8D0318FDFFFD30E683C42BC.__file__(net_http_ext.rb:17) ruby.jit.request_AE1E09B26A77A19AF8D0318FDFFFD30E683C42BC.__file__(net_http_ext.rb) org.jruby.ast.executable.AbstractScript.__file__(AbstractScript.java:43) org.jruby.internal.runtime.methods.JittedMethod.call(JittedMethod.java:204) org.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:199) org.jruby.internal.runtime.methods.AliasMethod.call(AliasMethod.java:91) org.jruby.runtime.callsite.CachingCallSite.callBlock(CachingCallSite.java:195) org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:202) -- This message is automatically generated by JIRA. For more information on JIRA, see: http://www.atlassian.com/software/jira --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email