Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 5843023
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T12:05:47+00:00 2026-05-22T12:05:47+00:00

I recently start using JRuby in my Rails 2.3 webapp. Since then, I have

  • 0

I recently start using JRuby in my Rails 2.3 webapp. Since then, I have been experiencing slowness in my rspec tests… the test are taking too long to run since I switched to JRuby.

While using MRI, I never bothered to use spork in order to run my tests faster, but now I need to speed up the execution of my test.

First, I tried spork, but I did’t worked out because:

  1. spork 0.9 RC supports jruby, but does not support rails 2.3
    (it only supports rails 3)
  2. spork 0.8 supports rails 2.3, but does not support jruby I think it uses fork(), the spork-0.8 gem won’t event
    install on jruby).

I tried to run my tests on jruby, rails 2.3 and spork 0.9 rc, but it didn’t worked, in fact there was a warning message saying that spork 0.9 rc only supports rails >= 3.0

Then I tried nailgun, I installed the nailgun gem in my jruby environment (gem install nailgun) and started the nailgun server (ruby –ng-server at the root of my app).
Then I run one of my specs (ruby –ng -S spec spec/lib/importacao_atividades_spec.rb). The first time I executed the spec, it went just fine, but after that it kept raising RuntimeError: invalid runtime

Check the trace:

RuntimeError: invalid runtime
       require at org/jruby/RubyKernel.java:1038
       require at /Users/razenha/.rvm/gems/jruby-1.6.1/gems/activesupport-2.3.10/lib/active_support/dependencies.rb:184
        (root) at /Users/razenha/.rvm/gems/jruby-1.6.1/gems/mysql-2.8.1/lib/mysql.rb:3
       require at org/jruby/RubyKernel.java:1038
       require at /Users/razenha/.rvm/gems/jruby-1.6.1/gems/mysql-2.8.1/lib/mysql.rb:68
          each at org/jruby/RubyArray.java:1602
       require at /Users/razenha/.rvm/gems/jruby-1.6.1/gems/bundler-1.0.12/lib/bundler/runtime.rb:66
          each at org/jruby/RubyArray.java:1602
       require at /Users/razenha/.rvm/gems/jruby-1.6.1/gems/bundler-1.0.12/lib/bundler/runtime.rb:55
       require at /Users/razenha/.rvm/gems/jruby-1.6.1/gems/bundler-1.0.12/lib/bundler.rb:120
     load_gems at /Users/razenha/Projects/Pro/portaltrademarketing/config/boot.rb:116
       process at /Users/razenha/.rvm/gems/jruby-1.6.1/gems/rails-2.3.10/lib/initializer.rb:164
          send at org/jruby/RubyKernel.java:2052
           run at /Users/razenha/.rvm/gems/jruby-1.6.1/gems/rails-2.3.10/lib/initializer.rb:113
        (root) at /Users/razenha/Projects/Pro/portaltrademarketing/config/environment.rb:12
       require at org/jruby/RubyKernel.java:1038
       require at /Users/razenha/.rvm/rubies/jruby-1.6.1/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:29
        (root) at /Users/razenha/Projects/Pro/portaltrademarketing/config/environment.rb:47
       require at org/jruby/RubyKernel.java:1038
       require at /Users/razenha/.rvm/rubies/jruby-1.6.1/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:29
        (root) at /Users/razenha/Projects/Pro/portaltrademarketing/spec/spec_helper.rb:1
          load at org/jruby/RubyKernel.java:1063
    load_files at ./spec/lib/importacao_atividades_spec.rb:15
          each at org/jruby/RubyArray.java:1602
    load_files at /Users/razenha/.rvm/gems/jruby-1.6.1/gems/rspec-1.2.9/lib/spec/runner/example_group_runner.rb:14
  run_examples at /Users/razenha/.rvm/gems/jruby-1.6.1/gems/rspec-1.2.9/lib/spec/runner/options.rb:132
           run at /Users/razenha/.rvm/gems/jruby-1.6.1/gems/rspec-1.2.9/lib/spec/runner/command_line.rb:9
        (root) at /Users/razenha/.rvm/gems/jruby-1.6.1/gems/rspec-1.2.9/bin/spec:5
          load at org/jruby/RubyKernel.java:1063
        (root) at /Users/razenha/.rvm/gems/jruby-1.6.1/bin/spec:19

So I am really stuck here. Anyone know how can I fix the nailgun issue? If not, is there an alternative? Is it possible to use spork in jruby and rails 2.3?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-22T12:05:47+00:00Added an answer on May 22, 2026 at 12:05 pm

    Oh… Looks like jruby does not like an older version of the Redis gem. Updated my Resque/Redis gem version and it worked.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Recently thanks to rails' popularity, many people start using activerecord as model. however, before
I've been looking at some workflows for Mercurial recently, as we start using it
Recently, I have been getting familiar with PostgreSQL(using 8.2) and found the date_trunc function
We recently started using Eclipse to develop our java application and have been running
I am a big fan of textmate, and have recently had to start using
I learned about Lazy class in .Net recently and have been probably over-using it.
I have recently noticed that a lot of JavaScript files on the Web start
Recently I have been investigating the possibilities of caching in ASP.NET. I rolled my
i am novice to the Linux shell and had to recently start using it
I recently began to start using functions to make casting easier on my fingers

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.