# Problem with warbler

**URL:** <https://www.ruby-forum.com/t/problem-with-warbler/151056>\
**Category:** Ruby\
**Created:** [October 16, 2008, 11:40am UTC](https://www.ruby-forum.com/t/problem-with-warbler/151056 "2008-10-16T11:40:30Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![bahaw](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/f19dbf/32.png) [@bahaw](https://www.ruby-forum.com/u/bahaw)\
**Post date:** [October 16, 2008, 11:40am UTC](https://www.ruby-forum.com/t/problem-with-warbler/151056/1 "2008-10-16T11:40:30Z")

</div>

I am using jruby 1.1.4 and installed warbler 0.9.11 in Windows XP. When  
I run jruby -S warble war, I always get this. It fails when rake  
reaches the target war:jar. I checked my JAVA\_HOME and I can run jar  
command in a command line.

\*\* Execute war:jar  
jar cf shoplet.war -C tmp/war .  
/usr/bin/sh: call: command not found  
rake aborted!  
Command failed with status (127): [jar cf shoplet.war -C tmp/war …]  
D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:971:in `sh' D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:984:in`call’  
D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:984:in `sh' D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:1076:in`sh’  
D:/workspace/shoplet/vendor/plugins/warbler-0.9.11/tasks/…/lib/warbler/task.rb:  
174:in `define_jar_task' D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:617:in`call’  
D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:617:in  
`execute' D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:612:in`each’  
D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:612:in  
`execute' D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:578:in`invoke\_with  
\_call\_chain’  
D:/jruby-1.1.4/lib/ruby/1.8/monitor.rb:191:in `mon_synchronize' D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:571:in`invoke\_with  
\_call\_chain’  
D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:588:in  
`invoke_prer equisites' D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:585:in`each’  
D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:585:in  
`invoke_prer equisites' D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:577:in`invoke\_with  
\_call\_chain’  
D:/jruby-1.1.4/lib/ruby/1.8/monitor.rb:191:in `mon_synchronize' D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:571:in`invoke\_with  
\_call\_chain’  
D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:564:in  
`invoke' D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:2019:in`invoke\_tas  
k’  
D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:1997:in  
`top\_level’

D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:1997:in  
`each' D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:1997:in`top\_level’

D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:2036:in  
`standard_e xception_handling' D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:1991:in`top\_level’

D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:1970:in  
`run' D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:2036:in`standard\_e  
xception\_handling’  
D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake.rb:1967:in  
`run' D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/bin/rake:31 D:/jruby-1.1.4/lib/ruby/gems/1.8/gems/rake-0.8.3/bin/rake:19:in`load’  
d:\jruby-1.1.4\bin\rake:19

---

<div class="post-metadata">

**Author:** ![bahaw](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/f19dbf/32.png) [@bahaw](https://www.ruby-forum.com/u/bahaw)\
**Post date:** [October 16, 2008, 11:41am UTC](https://www.ruby-forum.com/t/problem-with-warbler/151056/2 "2008-10-16T11:41:19Z")

</div>

Btw, I am using JDK 1.5.

---

<div class="post-metadata">

**Author:** ![bahaw](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/f19dbf/32.png) [@bahaw](https://www.ruby-forum.com/u/bahaw)\
**Post date:** [October 16, 2008, 4:39pm UTC](https://www.ruby-forum.com/t/problem-with-warbler/151056/3 "2008-10-16T16:39:07Z")

</div>

Bahaw A. wrote:

> Btw, I am using JDK 1.5.

I think I have solve the problem with conflicting rake versions. I can  
build the war now, but when deployed in Tomcat, it is asking for  
RAILS\_GEM\_VERSION.

---

<div class="post-metadata">

**Author:** ![bahaw](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/f19dbf/32.png) [@bahaw](https://www.ruby-forum.com/u/bahaw)\
**Post date:** [October 16, 2008, 7:42pm UTC](https://www.ruby-forum.com/t/problem-with-warbler/151056/4 "2008-10-16T19:42:39Z")

</div>

On Thu, Oct 16, 2008 at 12:20 PM, Bahaw A. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> Missing the Rails 2.1.1 gem. Please `gem install -v=2.1.1 rails`, update  
> your RA  
> ILS\_GEM\_VERSION setting in config/environment.rb for the Rails version  
> you do ha  
> ve installed, or comment out RAILS\_GEM\_VERSION to use the latest version  
> install  
> ed.

Can you check if the Rails gem was included in your war file by doing  
“jar tf myapp.war | grep rails” or similar? Also, feel free to stop by  
the jruby lists to troubleshoot the problem further.

Regards,  
/Nick

---

<div class="post-metadata">

**Author:** ![bahaw](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/f19dbf/32.png) [@bahaw](https://www.ruby-forum.com/u/bahaw)\
**Post date:** [October 16, 2008, 7:20pm UTC](https://www.ruby-forum.com/t/problem-with-warbler/151056/5 "2008-10-16T19:20:37Z")

</div>

Bahaw A. wrote:

> Bahaw A. wrote:
> 
> > Btw, I am using JDK 1.5.
> 
> I think I have solve the problem with conflicting rake versions. I can  
> build the war now, but when deployed in Tomcat, it is asking for  
> RAILS\_GEM\_VERSION.

This is what I get when I run Tomcat. My app was running in Mongrel and  
I’m sure I’m using Rails 2.1.1.

Missing the Rails 2.1.1 gem. Please `gem install -v=2.1.1 rails`, update  
your RA  
ILS\_GEM\_VERSION setting in config/environment.rb for the Rails version  
you do ha  
ve installed, or comment out RAILS\_GEM\_VERSION to use the latest version  
install  
ed.

---

<div class="post-metadata">

**Author:** ![bahaw](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/f19dbf/32.png) [@bahaw](https://www.ruby-forum.com/u/bahaw)\
**Post date:** [October 16, 2008, 7:50pm UTC](https://www.ruby-forum.com/t/problem-with-warbler/151056/6 "2008-10-16T19:50:24Z")

</div>

Nick S. wrote:

> On Thu, Oct 16, 2008 at 12:20 PM, Bahaw A. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:
> 
> > Missing the Rails 2.1.1 gem. Please `gem install -v=2.1.1 rails`, update  
> > your RA  
> > ILS\_GEM\_VERSION setting in config/environment.rb for the Rails version  
> > you do ha  
> > ve installed, or comment out RAILS\_GEM\_VERSION to use the latest version  
> > install  
> > ed.
> 
> Can you check if the Rails gem was included in your war file by doing  
> “jar tf myapp.war | grep rails” or similar? Also, feel free to stop by  
> the jruby lists to troubleshoot the problem further.
> 
> Regards,  
> /Nick

Nick, thanks for the reply.  
I tried that command, this is what I got.

$ jar tf shoplet.war | grep rails  
images/rails.png  
WEB-INF/config/initializers/new\_rails\_defaults.rb

I create my war using jruby -S warble war command.

Also, below what I got from my log file which I think is related to this  
bug - [http://www.nabble.com/Jruby-Tomcat-error-td17662084.html](http://www.nabble.com/Jruby-Tomcat-error-td17662084.html) and  
[http://jira.codehaus.org/browse/JRUBY-2507](http://jira.codehaus.org/browse/JRUBY-2507)

Appreciate the help.

======================

SEVERE: Exception caught  
org.jruby.rack.RackInitializationException: exit  
from d:/tomcat/webapps/shoplet/WEB-INF/config/boot.rb:38:in `run' from file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/jruby/rack/rails_boot.rb:20:in `run’  
from d:/tomcat/webapps/shoplet/WEB-INF/config/boot.rb:11:in `boot!' from d:/tomcat/webapps/shoplet/WEB-INF/config/boot.rb:109 from d:/tomcat/webapps/shoplet/WEB-INF/config/boot.rb:11:in `require’  
from d:/tomcat/webapps/shoplet/WEB-INF/config/environment.rb:11  
from d:/tomcat/webapps/shoplet/WEB-INF/config/environment.rb:29:in  
`load' from file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/jruby/rack/rails.rb:29:in `load\_environment’  
from  
file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/jruby/rack/rails.rb:152:in  
`new' from <script>:3 from file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/rack/builder.rb:22:in `instance\_eval’  
from  
file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/rack/builder.rb:22:in  
`initialize’  
from :3

at  
org.jruby.rack.DefaultRackApplicationFactory$4.init(DefaultRackApplicationFactory.java:154)  
at  
org.jruby.rack.DefaultRackApplicationFactory.getApplication(DefaultRackApplicationFactory.java:53)  
at  
org.jruby.rack.PoolingRackApplicationFactory.getApplication(PoolingRackApplicationFactory.java:92)  
at  
org.jruby.rack.DefaultRackDispatcher.process(DefaultRackDispatcher.java:31)  
at org.jruby.rack.RackFilter.doFilter(RackFilter.java:51)  
at  
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)  
at  
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)  
at  
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)  
at  
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)  
at  
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)  
at  
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)  
at  
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)  
at  
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)  
at  
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:845)  
at  
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)  
at  
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)  
at java.lang.Thread.run(Thread.java:619)  
Caused by: org.jruby.exceptions.RaiseException  
at  
Rails::GemBoot.load\_rails\_gem(d:/tomcat/webapps/shoplet/WEB-INF/config/boot.rb:53)  
at  
Rails::GemBoot.load\_initializer(d:/tomcat/webapps/shoplet/WEB-INF/config/boot.rb:38)  
at  
Rails::Boot.run(file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/jruby/rack/rails\_boot.rb:20)  
at  
Rails::BootHook.run(d:/tomcat/webapps/shoplet/WEB-INF/config/boot.rb:11)  
at  
#Class:01x18a2977.boot!(d:/tomcat/webapps/shoplet/WEB-INF/config/boot.rb:109)  
at  
(unknown).(unknown)(d:/tomcat/webapps/shoplet/WEB-INF/config/boot.rb:11)  
at  
Kernel.require(d:/tomcat/webapps/shoplet/WEB-INF/config/environment.rb:11)  
at  
(unknown).(unknown)(d:/tomcat/webapps/shoplet/WEB-INF/config/environment.rb:29)  
at  
Kernel.load(file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/jruby/rack/rails.rb:29)  
at  
JRuby::Rack::RailsServletHelper.load\_environment(file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/jruby/rack/rails.rb:152)  
at #Class:01x46136.new(:3)  
at  
(unknown).(unknown)(file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/rack/builder.rb:22)  
at  
Kernel.instance\_eval(file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/rack/builder.rb:22)  
at  
Kernel.instance\_eval(file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/rack/builder.rb:22)  
at Rack::Builder.initialize(:3)  
at (unknown).(unknown)(:1)  
Oct 17, 2008 1:45:08 AM org.apache.catalina.core.ApplicationContext log  
SEVERE: Exception caught  
org.jruby.rack.RackInitializationException: exit  
from d:/tomcat/webapps/shoplet/WEB-INF/config/boot.rb:38:in `run' from file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/jruby/rack/rails_boot.rb:20:in `run’  
from d:/tomcat/webapps/shoplet/WEB-INF/config/boot.rb:11:in `boot!' from d:/tomcat/webapps/shoplet/WEB-INF/config/boot.rb:109 from d:/tomcat/webapps/shoplet/WEB-INF/config/boot.rb:11:in `require’  
from d:/tomcat/webapps/shoplet/WEB-INF/config/environment.rb:11  
from d:/tomcat/webapps/shoplet/WEB-INF/config/environment.rb:29:in  
`load' from file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/jruby/rack/rails.rb:29:in `load\_environment’  
from  
file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/jruby/rack/rails.rb:152:in  
`new' from <script>:3 from file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/rack/builder.rb:22:in `instance\_eval’  
from  
file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/rack/builder.rb:22:in  
`initialize’  
from :3

at  
org.jruby.rack.DefaultRackApplicationFactory$4.init(DefaultRackApplicationFactory.java:154)  
at  
org.jruby.rack.DefaultRackApplicationFactory.getApplication(DefaultRackApplicationFactory.java:53)  
at  
org.jruby.rack.PoolingRackApplicationFactory.getApplication(PoolingRackApplicationFactory.java:92)  
at  
org.jruby.rack.DefaultRackDispatcher.process(DefaultRackDispatcher.java:31)  
at org.jruby.rack.RackFilter.doFilter(RackFilter.java:51)  
at  
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)  
at  
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)  
at  
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)  
at  
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)  
at  
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)  
at  
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)  
at  
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)  
at  
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)  
at  
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:845)  
at  
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)  
at  
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)  
at java.lang.Thread.run(Thread.java:619)  
Caused by: org.jruby.exceptions.RaiseException  
at  
Rails::GemBoot.load\_rails\_gem(d:/tomcat/webapps/shoplet/WEB-INF/config/boot.rb:53)  
at  
Rails::GemBoot.load\_initializer(d:/tomcat/webapps/shoplet/WEB-INF/config/boot.rb:38)  
at  
Rails::Boot.run(file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/jruby/rack/rails\_boot.rb:20)  
at  
Rails::BootHook.run(d:/tomcat/webapps/shoplet/WEB-INF/config/boot.rb:11)  
at  
#Class:01x7ab89d.boot!(d:/tomcat/webapps/shoplet/WEB-INF/config/boot.rb:109)  
at  
(unknown).(unknown)(d:/tomcat/webapps/shoplet/WEB-INF/config/boot.rb:11)  
at  
Kernel.require(d:/tomcat/webapps/shoplet/WEB-INF/config/environment.rb:11)  
at  
(unknown).(unknown)(d:/tomcat/webapps/shoplet/WEB-INF/config/environment.rb:29)  
at  
Kernel.load(file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/jruby/rack/rails.rb:29)  
at  
JRuby::Rack::RailsServletHelper.load\_environment(file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/jruby/rack/rails.rb:152)  
at #Class:01xfe8c4.new(:3)  
at  
(unknown).(unknown)(file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/rack/builder.rb:22)  
at  
Kernel.instance\_eval(file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/rack/builder.rb:22)  
at  
Kernel.instance\_eval(file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/rack/builder.rb:22)  
at Rack::Builder.initialize(:3)  
at (unknown).(unknown)(:1)

---

<div class="post-metadata">

**Author:** ![bahaw](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/f19dbf/32.png) [@bahaw](https://www.ruby-forum.com/u/bahaw)\
**Post date:** [October 17, 2008, 4:58pm UTC](https://www.ruby-forum.com/t/problem-with-warbler/151056/7 "2008-10-17T16:58:20Z")

</div>

This is a known issue – for some reason the /rails/info/properties  
route is not getting set up from within the war environment.

/Nick

---

<div class="post-metadata">

**Author:** ![bahaw](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/f19dbf/32.png) [@bahaw](https://www.ruby-forum.com/u/bahaw)\
**Post date:** [October 17, 2008, 12:53pm UTC](https://www.ruby-forum.com/t/problem-with-warbler/151056/8 "2008-10-17T12:53:57Z")

</div>

Ok I think I was to sort it out after all. I tried freezing rails and  
it was included now in the war file. I was able to see the application  
running in Tomcat at last! However, I have encountered some issues when  
I clicked on About your environment link  
([http://localhost:8080/shoplet/rails/info/properties](http://localhost:8080/shoplet/rails/info/properties)). I got the ff:  
exception.

ActionController::RoutingError (No route matches  
“/rails/info/properties” with {:method=\>:get}):  
/vendor/rails/actionpack/lib/action\_controller/routing/recognition\_optimisation.rb:67:in  
`recognize_path' /vendor/rails/actionpack/lib/action_controller/routing/route_set.rb:384:in `recognize’  
/vendor/rails/actionpack/lib/action\_controller/dispatcher.rb:148:in  
`handle_request' /vendor/rails/actionpack/lib/action_controller/dispatcher.rb:107:in `dispatch’  
/vendor/rails/actionpack/lib/action\_controller/dispatcher.rb:104:in  
`dispatch' /vendor/rails/actionpack/lib/action_controller/dispatcher.rb:120:in `dispatch\_cgi’  
/vendor/rails/actionpack/lib/action\_controller/dispatcher.rb:35:in  
`dispatch' file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/rack/adapter/rails.rb:37:in `serve\_rails’  
file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/rack/adapter/rails.rb:44:in  
`call' file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/jruby/rack/rails.rb:145:in `call’  
file:/D:/tomcat/webapps/shoplet/WEB-INF/lib/jruby-rack-0.9.2.jar!/rack/handler/servlet.rb:17:in  
`call’  
:3
