Yes, increasing the number of runtimes did it (the default was 1). Thanks
much!
oaw wrote:
>
> I'm on JRuby 1.4.0 (JDK version 1.6.0_17). The following code hangs my
> JRuby on Rails app.
>
> require 'net/http'
> require 'timeout'
>
> begin
> Timeout::timeout(5) do
> res =
> Net::HTTP.get_response("http://localhost:8080/projects/1/email_approved")
> res.body
> end
> rescue Exception => e
> RAILS_DEFAULT_LOGGER.error e
> RAILS_DEFAULT_LOGGER.error e.backtrace.join('\n\t')
> end
>
> Non-local URLs work; only local URLs hang. It just hangs with no
> stacktrace. It works fine in MRI Ruby. I've tried to resolve this for days
> with no success. Googling around, I found that timeout.rb is not reliable
> in previous versions of JRuby, so I upgraded to JRuby 1.4.0 but I still
> have this problem.
>
> Could someone please help? It would be greatly appreciated. I am at a
> complete loss.
>
> Thanks!
>
--
View this message in context:
http://old.nabble.com/Net%3A%3AHTTP-hangs-in-JRuby-on-Rails-app---please-help%21-tp27181232p27182093.html
Sent from the JRuby - Dev mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email