Hello, I developed a very simple hello world jruby application using rails 3.2, jruby 1.6.7, and warbler 1.3.2. When I deploy the application to my local Weblogic Server, everything works great; however, when I then try to deploy to our development weblogic server, which is running on Solaris 10, I get the following error. I’ve also tried using rails 3.0.10 and also a tomcat server, with the same results. To me, it looks like it can’t find the core rails libraries. Has anyone come across this issue before? Any help would be greatly appreciated. I’m very much stuck at this point: no such file to load -- rails/railtie --- System jruby 1.6.7 (ruby-1.8.7-p357) (2012-02-22 3e82bc8) (Java HotSpot(TM) Server VM 1.6.0_29) [SunOS-sparc-java] Time: Fri Mar 09 11:08:35 -0500 2012 Server: WebLogic Server 10.3.2.0 Tue Oct 20 12:16:15 PDT 2009 1267925 Oracle WebLogic Server Module Dependencies 10.3 Tue Oct 20 13: 57:01 EDT 2009 jruby.home: classpath:/META-INF/jruby.home --- Context Init Parameters: public.root = / rails.env = production --- Backtrace LoadError: no such file to load -- rails/railtie require at org/jruby/RubyKernel.java:1033 require at classpath:/META-INF/jruby.home/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36 (root) at classpath:/jruby/rack/rails/railtie.rb:8 require at org/jruby/RubyKernel.java:1033 require at classpath:/jruby/rack/rails/railtie.rb:36 load_environment at classpath:/jruby/rack/rails.rb:176 load_environment at classpath:/jruby/rack/rails.rb:191 (root) at <script>:1 --- RubyGems Gem.dir: Path to weblogic staging dir/hello3/hello3/WEB-INF/gems Gem.path: Path to weblogic staging dir/hello3/hello3/WEB-INF/gems Activated gems: --- Bundler undefined method `bundle_path' for Bundler:Module --- JRuby-Rack Config compat_version = filter_adds_html = true filter_verifies_resource = false ignore_environment = false initial_runtimes = jms_connection_factory = jms_jndi_properties = logger = org.jruby.rack.logging.ServletContextLogger@109ba1a logger_class_name = servlet_context logger_name = jruby.rack maximum_runtimes = num_initializer_threads = rackup = rackup_path = rewindable = true runtime_arguments = runtime_timeout_seconds = serial_initialization = false servlet_context = ServletContext@30015551[app:hello3 module:hello3 path:/hello3 spec-version:null] --- $LOAD_PATH: classpath:/META-INF/jruby.home/lib/ruby/site_ruby/1.8 classpath:/META-INF/jruby.home/lib/ruby/site_ruby/shared classpath:/META-INF/jruby.home/lib/ruby/1.8 . > <Mar 9, 2012 11:08:35 AM EST> <Error> <ServletContext-/hello3> <BEA-000000> <Application Error org.jruby.rack.RackInitializationException: no such file to load -- rails/railtie from classpath:/META-INF/jruby.home/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36:in `require' from classpath:/jruby/rack/rails/railtie.rb:8:in `(root)' from org/jruby/RubyKernel.java:1033:in `require' from classpath:/jruby/rack/rails/railtie.rb:36:in `require' from classpath:/jruby/rack/rails.rb:176:in `load_environment' from classpath:/jruby/rack/rails.rb:191:in `load_environment' from <script>:1:in `(root)' at org.jruby.rack.DefaultRackApplicationFactory$4.init(DefaultRackApplicationFactory.java:209) at org.jruby.rack.DefaultRackApplicationFactory.getApplication(DefaultRackApplicationFactory.java:56) at org.jruby.rack.PoolingRackApplicationFactory.getApplication(PoolingRackApplicationFactory.java:101) at org.jruby.rack.DefaultRackDispatcher.getApplication(DefaultRackDispatcher.java:27) at org.jruby.rack.AbstractRackDispatcher.process(AbstractRackDispatcher.java:29) at org.jruby.rack.AbstractFilter.doFilter(AbstractFilter.java:41) at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56) at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3592) at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321) at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121) at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2202) at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2108) at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1432) at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201) at weblogic.work.ExecuteThread.run(ExecuteThread.java:173) Caused By: org.jruby.exceptions.RaiseException: (LoadError) no such file to load -- rails/railtie at org.jruby.RubyKernel.require(org/jruby/RubyKernel.java:1033) at Kernel.require(classpath:/META-INF/jruby.home/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36) at (Anonymous).(root)(classpath:/jruby/rack/rails/railtie.rb:8) at org.jruby.RubyKernel.require(org/jruby/RubyKernel.java:1033) at Kernel.require(classpath:/jruby/rack/rails/railtie.rb:36) at Rails3Environment.load_environment(classpath:/jruby/rack/rails.rb:176) at (Anonymous).load_environment(classpath:/jruby/rack/rails.rb:191) at (Anonymous).(root)(<script>:1) >
on 2012-03-14 15:09
on 2012-03-14 16:35
I assume where you have "Path to weblogic staging dir/hello3/hello3/WEB-INF/gems", you've substituted "Path to weblogic staging dir" for the actual path of the exploded war? Have you taken a look in that directory? what do you see? When you run `jar tvf hello3.war` (or whatever) do you see all your gems in the WEB-INF/gems/gems dir? Can you gist your warbler.conf?
on 2012-03-14 17:41
Yes, I substituted the actual path. Sorry - probably should have mentioned that... Initially, the app was not deployed as an exploded war, so the path only contained the war file. I then deployed it as an exploded war and verified the gem.path and gem.dir paths were correct and the gems were located in these directories. Unfortunately, it did not fix the issue. The war file also contained the gems in the correct directory (WEB-INF/gems/gems). My warbler.rb file contains two entries: config.dirs = %w(app config lib log vendor tmp) config.webinf_files += FileList["config/weblogic.xml") It’s strange that the app runs without issue from my local weblogic server but not when I deploy it to weblogic or tomcat running on Solaris. Could this be a java.home issue? Do I need to explicity set this variable? Thanks for the help!!
on 2012-03-15 14:39
Here's the gist link to the warble.rb config file: https://gist.github.com/fe382de2f915388323b8
on 2012-03-16 14:42
Is anyone running weblogic 10.3.x or tomcat 7 on solaris 10 that could test a simple hello world app? If it works for you, then it must be something in my environment.
on 2012-07-17 23:02
Jeff, were you able to solve this? I'm running into the same "no such file to load -- rails/railtie" problem deploying to Apache Tomcat on Solaris with Rails 3.1.3, jRuby 1.6.6 & Warbler 1.3.2
on 2012-07-18 00:05
on 2012-07-18 03:19
Also, make sure that you have the correct jruby-jars gem loaded. It should be 1.6.5, not 1.6.7 or higher.