Note that there are some explanatory texts on larger screens.

plurals
  1. POActiveRecord is not missing constant Base! error deploying rails 3.2.9 jruby 1.7.2 to weblogic 10.3
    text
    copied!<p>Running into this issue while deploying Rails 3.2 project to Weblogic 10.3 and was looking for an easy answer.</p> <pre><code>org.jruby.exceptions.RaiseException: (NameError) ActiveRecord is not missing constant Base! at RUBY.load_missing_constant(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/gems/gems/activesupport-3.2.9/lib/active_support/dependencies.rb:494) at RUBY.const_missing(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/gems/gems/activesupport-3.2.9/lib/active_support/dependencies.rb:192) at org.jruby.RubyArray.each(org/jruby/RubyArray.java:1613) at RUBY.const_missing(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/gems/gems/activesupport-3.2.9/lib/active_support/dependencies.rb:190) at RUBY.(root)(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/gems/gems/meta_search-1.1.3/lib/meta_search.rb:55) at org.jruby.RubyKernel.require(org/jruby/RubyKernel.java:1027) at ActiveSupport::Dependencies::Loadable.require(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/gems/gems/activesupport-3.2.9/lib/active_support/dependencies.rb:251) at ActiveSupport::Dependencies::Loadable.load_dependency(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/gems/gems/activesupport-3.2.9/lib/active_support/dependencies.rb:236) at ActiveSupport::Dependencies::Loadable.require(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/gems/gems/activesupport-3.2.9/lib/active_support/dependencies.rb:251) at RUBY.(root)(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/gems/gems/activeadmin-0.5.0/lib/active_admin.rb:1) at org.jruby.RubyKernel.require(org/jruby/RubyKernel.java:1027) at ActiveSupport::Dependencies::Loadable.require(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/gems/gems/activesupport-3.2.9/lib/active_support/dependencies.rb:251) at ActiveSupport::Dependencies::Loadable.load_dependency(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/gems/gems/activesupport-3.2.9/lib/active_support/dependencies.rb:236) at ActiveSupport::Dependencies::Loadable.require(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/gems/gems/activesupport-3.2.9/lib/active_support/dependencies.rb:251) at RUBY.(root)(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/gems/gems/activeadmin-0.5.0/lib/active_admin.rb:1) at org.jruby.RubyKernel.require(org/jruby/RubyKernel.java:1027) at RUBY.(root)(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/gems/gems/activeadmin-0.5.0/lib/activeadmin.rb:1) at org.jruby.RubyArray.each(org/jruby/RubyArray.java:1613) at RUBY.(root)(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/gems/gems/activeadmin-0.5.0/lib/activeadmin.rb:1) at org.jruby.RubyArray.each(org/jruby/RubyArray.java:1613) at RUBY.(root)(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/gems/gems/bundler-1.2.3/lib/bundler/runtime.rb:1) at RUBY.require(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/gems/gems/bundler-1.2.3/lib/bundler/runtime.rb:68) at RUBY.require(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/gems/gems/bundler-1.2.3/lib/bundler/runtime.rb:66) at org.jruby.RubyKernel.require(org/jruby/RubyKernel.java:1027) at RUBY.require(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/gems/gems/bundler-1.2.3/lib/bundler/runtime.rb:55) at org.jruby.RubyKernel.require(org/jruby/RubyKernel.java:1027) at RUBY.require(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/gems/gems/bundler-1.2.3/lib/bundler.rb:128) at RUBY.(root)(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/config/application.rb:13) at RUBY.(root)(&lt;app_deploy_dir&gt;/&lt;app_name&gt;/mfey8c/war/WEB-INF/config/environment.rb:1) </code></pre> <p>Environment looks like this: JRuby 1.7.2, JRockit 1.6, Rails 3.2.9, Warbler</p> <p>I deploy the basic 2 model plus devise user project and this error occurs when I browse to it in a browser. Has anyone seen this before? This is my first stint with JRuby.</p> <p>Editing:</p> <p>Adding my latest failed attempt. note, I've tried jruby, jruby-jars for 1.6.8, 1.7.0, 1.7.2 and have had no success. here is my Gem File and Warbler configuration:</p> <pre><code>#source 'https://rubygems.org' source "http://bundler-api.herokuapp.com" gem 'rails', '&lt;3.3' # Bundle edge Rails instead: # gem 'rails', :git =&gt; 'git://github.com/rails/rails.git' gem 'savon' #gem 'jruby-openssl' gem 'json' #gem 'ffi', '~&gt;1.0.9' #gem 'sqlite3' gem 'rake', "=10.0.2" gem 'activerecord-oracle_enhanced-adapter', "~&gt; 1.4.0" # Gems used only for assets and not required # in production environments by default. group :assets do gem 'sass-rails', '&lt;3.3' gem 'coffee-rails', '&lt;3.3' # See https://github.com/sstephenson/execjs#readme for more supported runtimes #gem 'therubyrhino' #gem 'therubyracer' #gem 'libv8' gem 'uglifier', '&gt;= 1.0.3' end platforms :jruby do group :assets do gem 'therubyrhino' end group :development, :test do gem 'ruby-debug' gem 'activerecord-jdbcsqlite3-adapter', "~&gt; 1.2.5" gem 'warbler' end gem 'jruby-jars', "1.7.0" gem 'jruby-openssl', :require =&gt; false end platforms :ruby do group :assets do gem 'therubyracer' gem 'libv8' end group :development, :test do gem 'debugger' gem 'sqlite3' end gem 'ruby-oci8', '~&gt; 2.1.0' # requires oracle client end gem 'jquery-rails' gem 'devise' gem 'activeadmin' gem 'rb-readline' gem 'validates_timeliness', '~&gt; 3.0' gem 'wash_out'#, :path =&gt; "~/Desktop/code/wash_out" # To use ActiveModel has_secure_password # gem 'bcrypt-ruby', '~&gt; 3.0.0' # To use Jbuilder templates for JSON # gem 'jbuilder' # Use unicorn as the app server # gem 'unicorn':path # Deploy with Capistrano # gem 'capistrano' # To use debugger # gem 'uby-debug' group :development do end group :test do gem 'cucumber-rails', :require =&gt; false #gem 'cucumber', :require =&gt; false gem 'shoulda-matchers' gem 'json_spec' gem 'vcr' gem 'fakeweb' gem 'database_cleaner' gem 'launchy' gem 'webrat' gem 'json_spec' #gem 'capybara' #gem 'mocha' end group :development, :test do #gem 'activerecord-sqlite3-adapter', :platform =&gt; :ruby #gem 'activerecord-jdbc-sqlite3-adapter', :platform =&gt; :jruby gem 'rspec-rails' gem 'factory_girl_rails', "~&gt; 4.0" end </code></pre> <p>And Warbler Config (Using Warble War):</p> <pre><code> class Warbler::Jar def replace_compiled_ruby_files(config, compiled_ruby_files) config.excludes += compiled_ruby_files compiled_ruby_files.each do |ruby_source| files[apply_pathmaps(config, ruby_source, :application)] = StringIO.new("load __FILE__.sub(/\.rb$/, '.class')") end end end Warbler::Config.new do |config| config.dirs = %w(app config lib log vendor tmp) config.webxml.jruby.compat.version = "1.9" end </code></pre>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload