-
Notifications
You must be signed in to change notification settings - Fork 137
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Asynchronous processing in JRuby-Rack? #119
Comments
Hi Man, I just realized it's really not possible with JRuby-Rack to do right now due the way how we handle responses. It's doable but the "main" problem (at least for me) is how to do it - see there's no Rack standard way of returning an async response, I've seen |
I have took a look at https://github.com/matadon/mizuno/blob/master/lib/mizuno/rack_servlet.rb. It's also using a "hacking-way" (catch :async) but it seems to integrate better with servlet container. |
You're right but it's a good fit, it's only unfortunate that it might break a Rack middleware or two. |
Can I extend https://github.com/jruby/jruby-rack/blob/master/src/main/java/org/jruby/rack/RackServlet.java with asyncSupported then configure to use it in web.xml? It sounds crazy? |
I'm sorry for mis-guiding you that won't be enough for JRuby-Rack since you need to dig deeper the source to find the response handling code (as opposed to mizuno's response handling in the servlet). Here's an old attempt I did but gave up due some middleware issuers it has been rebased to match the current master thus do not expet it to work but it shall show you where to get started (hope it helps): kares@2f3a8b0 (async-support branch of my fork) |
Me too! I found this issue while search for jruby/rails async servlet integration. I'm not sure that I can do anything to help, but getting async support for long file upload/downloads in our app will be very good for our thread count and memory use. |
I'm building an API with the wonderful Grape framework that pushes requests to a message queue and sends back responses from the queue using the AMQP gem. The AMQP gem does requests asynchronously, hence the only working solution I found using JRuby was Mizuno. |
Does JRuby-Rack support asynchronous processing as in Java Servlet 3.0 API ?
As I know, we can create an async. servlet (http://developerlife.com/tutorials/?p=1437). Is there anyway we can do that with JRuby-Rack?
Thanks.
This issue seems to be lacking activity, you can change that by posting a bounty.
The text was updated successfully, but these errors were encountered: