javawildfly-8ejb-3.2jboss-modules

How to deploy EJB module as a module under MODULES folder in wildfly AS


I have a jar containing EJBs say EJBTest.jar and have deployed it as a module under modules folder along with module.xmlin wildfly application server.

In the WAR which is the consumer of EJBs, I have added a reference to the EJB module <module name="com.test.ejb" /> under <dependencies> in jboss-deployment-structure.xml.

I am getting javax.naming.NameNotFoundException: from which I am obviously getting that the EJB module jar EJBTest.jar is not installed properly under modules folder of wildfly application server.

I have a doubt that whether EJB module can installed as a module in wildfly. I have a bean interface and bean implementation annotated with @remote and @stateless respectively. Am I missing anything ? Or Is is not possible to deploy or install EJB module as a module in wildfly ? Please help. Many thanks.


Solution

  • I don't believe that you can deploy EJBs as modules in any version of WildFly.

    You can however install ejb jar files as regular deployments. ie. You can deploy an ejb-jar file in the same way that you deploy WAR or EAR files.

    Is there any reason that you cannot do this?