I'm migrating a web application from Weblogic 12.1.3 to 12.2.1.3 but when I was testing the app in the new version of the Weblogic I found out that one specific JNDI lookup (java:comp/env/wm/default) was not working. I research and find the documentation of Commonj, which is the documentation of how to use WorkManager. In this doc says that
Automatic binding of the default CommonJ Work Manager to java:comp/env/wm/default has been removed in WebLogic Server 12.2.1.
And also says that is possible to add a resource-ref in order to make it possible to realize the JNDI lookup or maker the injection into the EJB using the @Resource.
I have tried to add the resource-ref to ejb-jar.xml like this :
<enterprise-beans>
<entity>
<display-name>WorkManagerProxy</display-name>
<ejb-ref>
<ejb-ref-name>wm/default</ejb-ref-name>
<ejb-ref-type>session</ejb-ref-type>
</ejb-ref>
</entity>
</enterprise-beans>
And in the weblogic-ejb-jar.xml
<weblogic-enterprise-bean>
<ejb-name>WorkManagerProxy</ejb-name>
<resource-description>
<res-ref-name>wm/default/WorkManager</res-ref-name>
<jndi-name>wm/default</jndi-name>
</resource-description>
<enable-call-by-reference>true</enable-call-by-reference>
</weblogic-enterprise-bean>
But in both cases, there's no success.
And here's my difficulty, how to make the biding to WorkManager so it will be able to make the lookup or injecting into EJB?