Forums | Admin

Discussion Forums: help

Start New Thread Start New Thread

 

By: Alex Boisvert
RE: NoClassDefFoundError with rjb 1.2.8 [ reply ]  
2010-09-21 18:51
Thanks! 1.2.9 is working for me now.

By: arton Tajima
RE: NoClassDefFoundError with rjb 1.2.8 [ reply ]  
2010-09-21 18:15
Hi,

I've fixed it and released Rjb-1.2.9.

Thank you.

By: arton Tajima
RE: NoClassDefFoundError with rjb 1.2.8 [ reply ]  
2010-09-21 09:45
Alex, thanks your report.

I've reproduced the problem. It's clearly Rjb's bug.
Please wait few days to detect the cause.

Regards.

By: Alex Boisvert
RE: NoClassDefFoundError with rjb 1.2.8 [ reply ]  
2010-09-20 19:21
The classpaths are different in the post above although there were the same when I actually ran it. It's just a cut & paste mistake. In other words, the classpaths are valid.

alex

By: Alex Boisvert
NoClassDefFoundError with rjb 1.2.8 [ reply ]  
2010-09-20 18:39
Hi,

Looks like there's a regression in RJB 1.2.8 where it can't load java classes,

boisvert@smudge:~$ irb
irb(main):001:0> require 'rubygems'
=> true
irb(main):002:0> gem 'rjb', '=1.2.8'
=> true
irb(main):003:0> require 'rjb'
=> true
irb(main):004:0> Rjb::load(classpath = "commons-lang-2.5.jar", jvmargs=['-verbose'])
=> nil
irb(main):005:0> array_utils = Rjb::import('org.apache.commons.lang.ArrayUtils')
NoClassDefFoundError: org/apache/commons/lang/ArrayUtils
from (irb):5:in `import'
from (irb):5
from (null):0

If I do the same with rjb 1.2.5, it works as expected:


boisvert@smudge:~$ irb
irb(main):001:0> require 'rubygems'
=> true
irb(main):002:0> gem 'rjb', '=1.2.5'
=> true
irb(main):003:0> require 'rjb'
=> true
irb(main):004:0> Rjb::load(classpath = "/home/boisvert/.m2/repository/commons-lang/commons-lang/2.5/commons-lang-2.5.jar", jvmargs=['-verbose'])
[Loaded java.lang.Object from shared objects file]
[Loaded java.io.Serializable from shared objects file]
[Loaded java.lang.Comparable from shared objects file]
[Loaded java.lang.CharSequence from shared objects file]
[Loaded java.lang.String from shared objects file]
... [lots of classes omitted] ...
[Loaded org.apache.commons.lang.ArrayUtils from file:/home/boisvert/.m2/repository/commons-lang/commons-lang/2.5/commons-lang-2.5.jar]
[Loaded java.lang.IndexOutOfBoundsException from shared objects file]
=> #<Rjb::Org_apache_commons_lang_ArrayUtils:0xb7571608>

Any idea how I can debug this further?

thanks,
alex