1 Reply Latest reply on Aug 19, 2013 10:18 PM by Chris Bitmead

    JBoss 7, EJB2, JBAS014543: No EJB found with interface of type

    Chris Bitmead Newbie

      I'm converting a legacy application from JBoss 4.2 to the latest JBoss, and I'm frustrated by the following error I can't figure out:

       

      16:20:39,324 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-6) MSC000001: Failed to start service jboss.deployment.subunit."npc.ear"."npc-server.jar".INSTALL: org.jboss.msc.service.StartException in service jboss.deployment.subunit."npc.ear"."npc-server.jar".INSTALL: JBAS018733: Failed to process phase INSTALL of subdeployment "npc-server.jar" of deployment "npc.ear"

                at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:127) [jboss-as-server-7.2.0.Final-redhat-8.jar:7.2.0.Final-redhat-8]

                at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811) [jboss-msc-1.0.4.GA-redhat-1.jar:1.0.4.GA-redhat-1]

                at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746) [jboss-msc-1.0.4.GA-redhat-1.jar:1.0.4.GA-redhat-1]

                at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) [rt.jar:1.7.0_11]

                at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) [rt.jar:1.7.0_11]

                at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0_11]

      Caused by: org.jboss.as.server.deployment.DeploymentUnitProcessingException: JBAS011058: Failed to install component VerifyDb

                at org.jboss.as.ee.component.deployers.ComponentInstallProcessor.deploy(ComponentInstallProcessor.java:102)

                at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:120) [jboss-as-server-7.2.0.Final-redhat-8.jar:7.2.0.Final-redhat-8]

                ... 5 more

      Caused by: org.jboss.as.server.deployment.DeploymentUnitProcessingException: JBAS014543: No EJB found with interface of type 'au.gov.ag.npc.interfaces.ServiceProviderHome' and name 'ServiceProvider' for binding java:comp/env/ejb/ServiceProvider

                at org.jboss.as.ejb3.deployment.processors.EjbInjectionSource.getResourceValue(EjbInjectionSource.java:97)

                at org.jboss.as.ee.component.deployers.ComponentInstallProcessor.processBindings(ComponentInstallProcessor.java:252)

                at org.jboss.as.ee.component.deployers.ComponentInstallProcessor.deployComponent(ComponentInstallProcessor.java:195)

                at org.jboss.as.ee.component.deployers.ComponentInstallProcessor.deploy(ComponentInstallProcessor.java:95)

                ... 6 more

       

      I've tracked it down that it is somehow related to this snippet from my ejb-jar.xml:

       

       

          <session>

            <ejb-name>VerifyDb</ejb-name>

            <home>au.gov.ag.npc.interfaces.VerifyDbHome</home>

            <remote>au.gov.ag.npc.interfaces.VerifyDb</remote>

            <ejb-class>au.gov.ag.npc.upload.VerifyDbBean</ejb-class>

            <session-type>Stateful</session-type>

            <transaction-type>Bean</transaction-type>

            <ejb-ref>

              <ejb-ref-name>ejb/ServiceProvider</ejb-ref-name>

              <ejb-ref-type>Entity</ejb-ref-type>

              <home>au.gov.ag.npc.interfaces.ServiceProviderHome</home>

              <remote>au.gov.ag.npc.interfaces.ServiceProvider</remote>

              <ejb-link>ServiceProvider</ejb-link>

            </ejb-ref>

            <resource-ref>

              <description/>

              <res-ref-name>jdbc/DefaultDS</res-ref-name>

              <res-type>javax.sql.DataSource</res-type>

              <res-auth>Container</res-auth>

            </resource-ref>

          </session>

       

      That in turn seems to reference this:

       

       

          <entity>

            <display-name>Service Provider Bean</display-name>     

            <ejb-name>ServiceProvider</ejb-name>

            <home>au.gov.ag.npc.interfaces.ServiceProviderHome</home>

            <remote>au.gov.ag.npc.interfaces.ServiceProvider</remote>

            <ejb-class>au.gov.ag.npc.financials.ServiceProviderBeanCMP</ejb-class>

            <persistence-type>Container</persistence-type>

            <prim-key-class>java.math.BigDecimal</prim-key-class>

            <reentrant>False</reentrant>

            <abstract-schema-name>ServiceProvider</abstract-schema-name>

            <cmp-field>

              <field-name>serviceProviderId</field-name>

            </cmp-field>

            <cmp-field>

              <field-name>programManagerId</field-name>

            </cmp-field>

            <cmp-field>

              <field-name>spName</field-name>

            </cmp-field>

            <cmp-field>

              <field-name>spmSpId</field-name>

            </cmp-field>

            <cmp-field>

              <field-name>streetAddress</field-name>

            </cmp-field>

            <cmp-field>

              <field-name>locality</field-name>

            </cmp-field>

            <cmp-field>

              <field-name>postcode</field-name>

            </cmp-field>

            <cmp-field>

              <field-name>state</field-name>

            </cmp-field>

            <cmp-field>

              <field-name>sla</field-name>

            </cmp-field>

            <cmp-field>

              <field-name>emailAddress</field-name>

            </cmp-field>

            <cmp-field>

              <field-name>postalStreetAddress</field-name>

            </cmp-field>

            <cmp-field>

              <field-name>postalLocality</field-name>

            </cmp-field>

            <cmp-field>

              <field-name>postalPostcode</field-name>

            </cmp-field>

            <cmp-field>

              <field-name>postalState</field-name>

            </cmp-field>

            <cmp-field>

              <field-name>notes</field-name>

            </cmp-field>

            <cmp-field>

              <field-name>npcPassword</field-name>

            </cmp-field>

            <cmp-field>

              <field-name>softwareVersion</field-name>

            </cmp-field>

            <primkey-field>serviceProviderId</primkey-field>

            <resource-ref>

              <res-ref-name>jdbc/DefaultDS</res-ref-name>

              <res-type>javax.sql.DataSource</res-type>

              <res-auth>Container</res-auth>

            </resource-ref>

                        <query>

                            <query-method>

                          <method-name>findByStateProgramManager</method-name>

                          <method-params>

                                    <method-param>java.math.BigDecimal</method-param>

                          </method-params>

                      </query-method>

                      <ejb-ql><![CDATA[ SELECT OBJECT(o) FROM ServiceProvider o WHERE o.programManagerId = ?1]]></ejb-ql>

                  </query>

          </entity>

       

      What should I be looking at? I've read the JBoss documents about converting apps. I've tried various things related to JNDI and ear and module deployment.