Skip to main content

This content has been archived and is no longer being updated. Links may not function; however, this content may be relevant to outdated versions of the product.

Support Article

MDB Listener setup fails migrating from PRPC 6.2 to Pega 7.1.7

SA-7228

Summary



After upgrading from PRPC 6.2 to Pega 7.1.7, the user tried to migrate the PRPC 6.2 Message-Driven Bean (MDB) Listener to Pega 7.1.7 (WebLogic application server). The user tried two approaches:
  • Generate a new MDB Listener for Pega 7.1.7. 
  • Copy the PRPC 6.2 MDB Listener Configuration to Pega 7.1.7. 
Neither approach worked.
Following the procedure in this article did not help: https://community.pega.com/knowledgebase/articles/how-deploy-jms-listener-message-drived-bean-mdb


Error Messages



 . . .  <AdminServer> <[ACTIVE] ExecuteThread: '1' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogicadmin> <> <> <1425314509868> <BEA-2156200> <Unable to load descriptor zip:<server directory>/tmp/.appmergegen_1425314509478_prpc_wls_jee4.ear/prbeans.jar!/META-INF/weblogic-ejb-jar.xml of module prbeans.jar. The error is weblogic.descriptor.DescriptorException: VALIDATION PROBLEMS WERE FOUND
<271:5> problem: cvc-complex-type.2.4a: Expected elements 'transaction-descriptor@http://xmlns.oracle.com/weblogic/weblogic-ejb-jar iiop-security-descriptor@http://xmlns.oracle.com/weblogic/weblogic-ejb-jar resource-


Steps to Reproduce


Unknown

Root Cause



An error or omission in product documentation: https://community.pega.com/knowledgebase/articles/how-deploy-jms-listener-message-drived-bean-mdb
Note that this article, which the user also referred to, is qualified for PRPC 5.4 SP2, not for Pega 7.1.7 on the WebLogic application server.

Resolution



To configure MDB for Pega 7.1.7 on WebLogic, complete the following steps related to the prpc ear file changes:

1. In ejb-jar.xml, add the following element under <enterprise-beans> element:

      <message-driven id="name of the MDB">
            <description>Message Driven Bean for JMS Listener name of the JMS Listener</description>
            <ejb-name>ejb name</ejb-name>
            <ejb-class>com.pega.pegarules.internal.etier.mdb.PRJMSListenerBoot</ejb-class>
            <transaction-type>Container</transaction-type>
            <activation-config>
              <activation-config-property>
              <activation-config-property-name>destinationType</activation-config-property-name>
              <activation-config-property-value>javax.jms.Queue</activation-config-property-value>
              </activation-config-property>
            </activation-config>
            <env-entry>
                <env-entry-name>PRListener</env-entry-name>
                <env-entry-type>java.lang.String</env-entry-type>
                <env-entry-value>name of the JMS Listener</env-entry-value>
            </env-entry>
            <env-entry>
                <env-entry-name>UseCMT</env-entry-name>
                <env-entry-type>java.lang.String</env-entry-type>
                <env-entry-value>false</env-entry-value>
            </env-entry>
            <ejb-local-ref id="EJBLocalRef_JMSMDB_Ref_EngineBMTLocal">
                <description/>
                <ejb-ref-name>ejb/EngineBMTLocal</ejb-ref-name>
                <ejb-ref-type>Session</ejb-ref-type>
                <local-home>com.pega.pegarules.internal.etier.interfaces.EngineLocalHome</local-home>
                <local>com.pega.pegarules.internal.etier.interfaces.EngineLocal</local>
                <ejb-link>EngineBMT</ejb-link>
            </ejb-local-ref>
            <ejb-local-ref id="EJBLocalRef_JMSMDB_Ref_EngineCMTLocal">
                <description/>
                <ejb-ref-name>ejb/EngineCMTLocal</ejb-ref-name>
                <ejb-ref-type>Session</ejb-ref-type>
                <local-home>com.pega.pegarules.internal.etier.interfaces.EngineLocalHome</local-home>
                <local>com.pega.pegarules.internal.etier.interfaces.EngineLocal</local>
                <ejb-link>EngineCMT</ejb-link>
            </ejb-local-ref>
        </message-driven>


Next add the following element under <assembly-descriptor> element:

      <container-transaction>
            <method>
                <ejb-name>JMSMDB_CPRS</ejb-name>
                <method-name>onMessage</method-name>
                <method-params>
                    <method-param>javax.jms.Message</method-param>
                </method-params>
            </method>
            <trans-attribute>NotSupported</trans-attribute>
        </container-transaction>


2. In weblogic-ejb-jar.xml, add the following element under <weblogic-ejb-jar>:

    <weblogic-enterprise-bean>
        <ejb-name>name of the ejb - shoud match the name in step 1</ejb-name>
        <message-driven-descriptor>
        <destination-jndi-name>queue jndi name</destination-jndi-name>
        <provider-url>message provider url</provider-url>
        <connection-factory-jndi-name>connection factory jndi name</connection-factory-jndi-name>
        </message-driven-descriptor>
        <ejb-reference-description>
            <ejb-ref-name>ejb/EngineBMTLocal</ejb-ref-name>
            <jndi-name>ejb/PREngineBMTLocal</jndi-name>
        </ejb-reference-description>
        <ejb-reference-description>
            <ejb-ref-name>ejb/EngineCMTLocal</ejb-ref-name>
            <jndi-name>ejb/PREngineCMTLocal</jndi-name>
        </ejb-reference-description>
        <enable-call-by-reference>true</enable-call-by-reference>
        <jndi-name>JMSMDB_CPRS</jndi-name>
    </weblogic-enterprise-bean>

3. Update prbeans.jar file with the modified ejb-jar.xml and weblogic-ejb-jar.xml and then update
    the ear file with the new prbeans.jar file (named: prpc_wls_jee4.ear under archives/prpc/weblogic/app directory).
4. Deploy the new .ear file following the installation guide.

See also the Pega 7.1.7 Help topics:
https://community.pega.com/sites/default/files/help_v717/procomhelpmain.htm#data-/data-admin-/data-admin-connect-/data-admin-connect-jmsmdblistener/main.htm

https://community.pega.com/sites/default/files/help_v717/procomhelpmain.htm#data-/data-admin-/data-admin-connect-/data-admin-connect-jmsmdblistener/listenerproperties.htm

https://community.pega.com/sites/default/files/help_v717/procomhelpmain.htm#data-/data-admin-/data-admin-connect-/data-admin-connect-jmsmdblistener/related.htm
 

Published July 28, 2018 - Updated October 8, 2020

Was this useful?

100% found this useful

Have a question? Get answers now.

Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

We'd prefer it if you saw us at our best.

Pega Community has detected you are using a browser which may prevent you from experiencing the site as intended. To improve your experience, please update your browser.

Close Deprecation Notice