Skip to content

Unable to java_import a class on jruby-9.0.0.0.rc1 #3062

@bigsur0

Description

@bigsur0

java_import 'org.apache.hadoop.hbase.protobuf.ProtobufUtil' works fine on jruby-1.7.19 but not on jruby-9.0.0.0.rc1, could this be due to new class loading behavior?

NameError: cannot initialize Java class org.apache.hadoop.hbase.protobuf.ProtobufUtil
              for_name at org/jruby/javasupport/JavaClass.java:204
       get_proxy_class at org/jruby/javasupport/JavaUtilities.java:34
  block in java_import at uri:classloader:/jruby/java/core_ext/object.rb:47
                   map at org/jruby/RubyArray.java:2309
           java_import at uri:classloader:/jruby/java/core_ext/object.rb:34
                 <top> at ~/Developer/work/bar/my_proj/lib/my_proj/foo/seqfile_utils.rb:14
               require at org/jruby/RubyKernel.java:940
                 <top> at ~/Developer/work/bar/my_proj/foo/src/spec/ruby/integration/my_proj/foo/my_spec.rb:1
                  load at org/jruby/RubyKernel.java:958
       block in (root) at ~/Developer/work/bar/my_proj/foo/src/spec/ruby/integration/my_proj/foo/my_spec.rb:7
                  each at org/jruby/RubyArray.java:1571
                (root) at ~/.rvm/gems/jruby-9.0.0.0.rc1@my_proj/gems/rspec-core-2.14.5/lib/rspec/core/configuration.rb:1
       load_spec_files at ~/.rvm/gems/jruby-9.0.0.0.rc1@my_proj/gems/rspec-core-2.14.5/lib/rspec/core/configuration.rb:896
       load_spec_files at ~/.rvm/gems/jruby-9.0.0.0.rc1@my_proj/gems/rspec-core-2.14.5/lib/rspec/core/configuration.rb:896
          block in run at ~/.rvm/gems/jruby-9.0.0.0.rc1@my_proj/gems/rspec-core-2.14.5/lib/rspec/core/command_line.rb:22

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions