Perhaps, we can take this discussion to glassfish gem forum at: http://rubyforge.org/forum/forum.php?forum_id=21309.
Anyway, to answer your question:
Vivek Pandey wrote:
Huh! What is overkill with GlassFish? With glassfish v3 server, you can
deploy your Rails application without any packaging. Just to run your
Rails
app on a Java server should not ask you to package it as WAR file.
Get glassfish v3 preview from here:
http://download.java.net/glassfish/v3-preview/release/glassfish-v3-preview.zip
and try it it is fast, reliable and suports deployment of Rails
applications
developed on JRuby without any need to do any additional
packaging/configuration etc.
-vivek.
Hi Vivek,
Can you perhaps point me in a direction on how to get our rails app up
and running with glassfish v3 server? We need to bring our app to
production soon. Currently we are running with the glassfish gem, but it
has the limitation that jdbc connection pooling can’t be enabled. We
really should enable this for production.
Right it is a pending feature request for gem, I can try to implement this feature request in the next gem release.
Also it seems the gem suffers from some memory problems. We configure it
to use maximum 4 instances, but after some time it just crashes with an
out of memory error. In the logs it looks like many more instances are
created than the maximum, which supposedly causes the memory to run out
after some time.
This should not happen. You may be better off by fixing the pool size. The dynamic pool behavior might be causing issues.
Try this argument so that the dynamic pooling does not try to shrink the pool size:
–runtimes-min 4
We start glassfish with this command on a 8 core windows server 2003
with 4GB of memory:
jruby -J-server -J-Xmx1400m -J-Xms1400m -J-XX:PermSize=256m
-J-XX:MaxPermSize=256m -S glassfish -n 4 --runtimes-max 4 -e prd -p 3010
D:\MPP\jruby\rails
These settings look ok.
See instructions to run your rails app on glassfish v3:
http://wiki.glassfish.java.net/Wiki.jsp?page=DeployAndRunRailsOnGlassFishV3
You can reach me at vivek.pandey at gmail.com and I can help you go to production for any specific need.
-vivek.