5 Replies Latest reply on Nov 15, 2001 3:05 PM by joever

    Newbie: (MDB) DeploymentException: expected one home tag

    macknox

      I'm having a lot of fun, as witnessed by my newest bald patches. I have successfully deployed a message driven bean to JBoss, and a worker bean in the pattern of the HelloListener example, or pretty close to it.

      When I deploy the .ear containing the .war, though, I get the above mentioned error. [DeploymentException: expected one home tag]. I don't know how to interpret this error. The obvious conclusion is that the deployer wants to see a interface tag in the ejb-jar.xml, but an MDB doesn't have one that I am aware of. (Happy to be educated about this as well, though)

      If I ignore the error, everything functions exactly as I wish it to.

      What should I do?

      Thanks,

      Kevin

        • 1. Re: Newbie: (MDB) DeploymentException: expected one home tag

          Is it now your worker bean it is comlaining about?

          //Peter

          • 2. Re: Newbie: (MDB) DeploymentException: expected one home tag
            macknox

            The complaint is unchanged by the addition or subtraction of the worker bean. I installed the MDB first all by itself, and received this error. I then stuck in some dummy interface statements, and that didn't help. I took them out. I then installed the worker bean stuff and got it working. In all circumstances, the error has been exactly the same.

            It seems to be a problem in the descriptor of the MDB, but one that I cannot begin to guess. Thanks for your reply,

            Kevin

            Here is my current ejb-jar.xml, lightly obfuscated and modified for readability:
            <?xml version="1.0"?>
            <!DOCTYPE ejb-jar>
            <ejb-jar>
            <enterprise-beans>
            <message-driven>
            <ejb-name>
            PIASUserInterfaceRequestReceiver
            </ejb-name>
            <ejb-class>
            com.x.jms.bean.PIASUserInterfaceRequestReceiver
            </ejb-class>
            <message-selector></message-selector>
            <transaction-type>Container</transaction-type>
            <ejb-ref>
            XML to Email home
            <ejb-ref-name>
            ejb/XformXMLToEmailBean
            </ejb-ref-name>
            <ejb-ref-type>Session</ejb-ref-type>
            <ejb-link>XformXMLToEmailBean</ejb-link>

            com.x.jms.interfaces.XformXMLToEmailHome


            com.x.jms.interfaces.XformXMLToEmail

            </ejb-ref>
            <message-driven-destination>
            <destination-type>
            javax.jms.Queue
            </destination-type>
            <subscription-durability>
            NonDurable
            </subscription-durability>
            </message-driven-destination>
            </message-driven>


            Xformer XML to Email
            <display-name>Xform XML To Email</display-name>
            <ejb-name>XformXMLToEmailBean</ejb-name>

            com.x.jms.interfaces.XformXMLToEmailHome


            com.x.jms.interfaces.XformXMLToEmail

            <ejb-class>
            com.x.jms.bean.XformXMLToEmailBean
            </ejb-class>
            <session-type>Stateless</session-type>
            <transaction-type>Container</transaction-type>


            </enterprise-beans>

            <assembly-descriptor>
            <container-transaction>

            <ejb-name>
            PIASUserInterfaceRequestReceiver
            </ejb-name>
            <method-name>*</method-name>

            <trans-attribute>Required</trans-attribute>
            </container-transaction>

            <container-transaction>

            <ejb-name>XformXMLToEmailBean</ejb-name>
            <method-intf>Remote</method-intf>
            <method-name>*</method-name>

            <trans-attribute>Required</trans-attribute>
            </container-transaction>
            </assembly-descriptor>
            </ejb-jar>

            jboss.xml:
            <?xml version="1.0"?>

            <enterprise-beans>

            <message-driven>
            <ejb-name>PIASUserInterfaceRequestReceiver</ejb-name>
            <configuration-name>Standard Message Driven Bean</configuration-name>
            <destination-jndi-name>queue/PIASUserInterfaceRequest</destination-jndi-name>
            </message-driven>



            <ejb-name>XformXMLToEmailBean</ejb-name>
            <jndi-name>XformXMLToEmailBean</jndi-name>
            <configuration-name>Standard Stateless SessionBean</configuration-name>


            false
            </enterprise-beans>

            • 3. Re: Newbie: (MDB) DeploymentException: expected one home tag

              Its probably the ejb-ref home stuff it barks on. But why I really do not know.

              //Peter

              • 4. Re: Newbie: (MDB) DeploymentException: expected one home tag
                macknox

                Thanks for looking at it. Unfortunately, the DeploymentException existed before the PIAS... bean ever needed to reference the Xform... bean.

                I don't know what the problem is, but stack trace or no, the product is working.

                Thanks,

                Kevin

                • 5. Re: Newbie: (MDB) DeploymentException: expected one home tag
                  joever

                  I'm also a newbie having a similar problem, why is is it complaining about a home or remote interface for a mdb? Is your's complaining but working? "but stack trace or no, the product is working", mine wont deploy the ear file. ejb-jar.xml extract:

                  <container-transaction>

                  <ejb-name>OrderMessageBean</ejb-name>
                  <method-intf>Bean</method-intf>
                  <method-name>onMessage</method-name>
                  <method-params>
                  <method-param>javax.jms.Message</method-param>
                  </method-params>

                  <trans-attribute>Required</trans-attribute>
                  </container-transaction>