Installing Rails on a JRuby workspace gives OutOfMemoryError

I checked out/built the JRuby workspace and installing Rails is
giving the following error:

C:\workspaces\jruby-trunk>bin\jruby -S gem install rails
–include-dependencies --no-ri --no-rdoc
Bulk updating Gem source index for:
Exception in thread “main” java.lang.OutOfMemoryError: Java heap space
at org.jruby.util.ByteList.grow(
at org.jruby.util.ByteList.append(
at org.jruby.util.ByteList.append(
at org.jvyamlb.ScannerImpl.update(
at org.jvyamlb.ScannerImpl.ensure(
at org.jvyamlb.ScannerImpl.scanLineBreak(
at org.jvyamlb.ScannerImpl.peekToken(

I fixed it by specifying the switch “-J-Xmx384M”. So the command that
works is:

bin\jruby -J-Xmx512M -S gem install rails --include-dependencies --no-ri


Web Technologies and Standards
Sun Microsystems, Inc.

To unsubscribe from this list please visit:

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs