How to access default scoped method of one jar from another jar in EAP 6?

Solution Verified - Updated -

Issue

  • There are 2 EJB module in an EAR. In one module, there is a class ejb.one.TestPojo.java with a method void helloWorld(String str){} and in the second module, there is a class ejb.one.Pojo.java, which will invoke a TestPojo.helloWorld(String) and the <ear-subdeployments-isolated> attribute of the EAR is already set to false. But still JBoss is throwing the following ERROR from the class ejb.one.Pojo.java while accessing the method helloWorld(String) of class ejb.one.TestPojo.java:
Caused by: java.lang.IllegalAccessError: tried to access method ejb.one.TestPojo.helloWorld(Ljava/lang/String;)Ljava/lang/String; from class ejb.one.Pojo

Environment

  • Red Hat JBoss Enterprise Application Platform (EAP)
    • 6.x

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content