Login  Register

Re: AsciidoctorJ error when using in a OSGi bundle

Posted by ch007m on Jul 15, 2014; 10:14am
URL: https://discuss.asciidoctor.org/AsciidoctorJ-error-when-using-in-a-OSGi-bundle-tp1910p1914.html

Hi,

This issue is not related at all to Asciidoctor or jruby. As the class sun/misc/Unsafe is part of the JDK, it should be loaded by the Apache Felix (= OSGI container) classloader and available to the classloader of jruby bundle.
Can you add a breakpoint here (http://grepcode.com/file/repo1.maven.org/maven2/org.jruby/jruby-complete/1.7.12/org/jruby/util/unsafe/UnsafeHolder.java#47) and check if jruby is able to load the class please ?

Remark : As asciidoctor project does not generate the OSGI manifest file containing the packages list to be imported by the bundle classloader, you should take care about that

Regards,

Charles

Charles Moulliard
Apache Committer / Technologist Evangelist / Blogger / MiddleWare Specialist
Twitter : @cmoulliard