Kunu
Kunu

Reputation: 35

WFLYEJB0405: No EJB found with interface of type .... my ejb class name

My project is a webapplication which is running on jboss EAP 7 and developed in struts and spring which calling a ejb class which is present in a jar file and that jar file is there in the build path (lib folder of my main project) and i mentioned the class name in web.xml. When i am building my project its showing below error please help where need to configure and what i need to do. my project is on Jboss EAP 7

Note:- My ejb class is not annotation based.

Caused by: org.jboss.as.server.deployment.DeploymentUnitProcessingException: WFLYEJB0405: No EJB found with interface of type 'common.ejb.service.BusinessServiceLocalHome' and name 'BusinessService.jar#BusinessService' for binding java:module/env/local/loan/BusinessService

web.xml:-

<ejb-local-ref id="EJBLocalRef_1179231224570">
        <ejb-ref-name>local/Loan/BusinessService</ejb-ref-name>
        <ejb-ref-type>Session</ejb-ref-type>
        <local-home>common.ejb.service.BusinessServiceLocalHome</local-home>
        <local>common.ejb.service.BusinessServiceLocal</local>
        <ejb-link>BusinessService.jar#BusinessService</ejb-link>
</ejb-local-ref>

Upvotes: 1

Views: 3024

Answers (1)

Steve C
Steve C

Reputation: 19435

Because you're only building a WAR file, you can remove:

 <ejb-link>BusinessService.jar#BusinessService</ejb-link>

This mechanism is only required in a multi-module EAR file. All jars in a WAR file are considered to be part of the same web module.

Upvotes: 1

Related Questions