4 Replies Latest reply on Nov 30, 2015 2:59 PM by Christian Hebert

    Problem runing MDB in eap6.1 alpha

    peter craddock Novice

      I have an application that runs fine in AS7.1.1

       

      I recently tried to deploy this to eap 6.1 alpha and found I got the following when trying to call a MDB from an EJB

       

      [0m [31m09:31:25,683 ERROR [org.jboss.as.ejb3.invocation] (Thread-1 (HornetQ-client-global-threads-6026341)) JBAS014134: EJB Invocation failed on component TaskDespatcherMEJB for method public abstract void javax.jms.MessageListener.onMessage(javax.jms.Message): javax.ejb.EJBAccessException: JBAS014502: Invocation on method: public abstract void javax.jms.MessageListener.onMessage(javax.jms.Message) of bean: TaskDespatcherMEJB is not allowed

          at org.jboss.as.ejb3.security.AuthorizationInterceptor.processInvocation(AuthorizationInterceptor.java:114) [jboss-as-ejb3-7.2.0.Alpha1-redhat-4.jar:7.2.0.Alpha1-redhat-4]

          at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]

          at org.jboss.as.ejb3.security.SecurityContextInterceptor.processInvocation(SecurityContextInterceptor.java:76) [jboss-as-ejb3-7.2.0.Alpha1-redhat-4.jar:7.2.0.Alpha1-redhat-4]

       

      [0m [31m09:31:25,697 ERROR [org.hornetq.ra] (Thread-1 (HornetQ-client-global-threads-6026341)) HQ154005: Failed to deliver message: javax.ejb.EJBAccessException: JBAS014502: Invocation on method: public abstract void javax.jms.MessageListener.onMessage(javax.jms.Message) of bean: TaskDespatcherMEJB is not allowed

          at org.jboss.as.ejb3.security.AuthorizationInterceptor.processInvocation(AuthorizationInterceptor.java:114) [jboss-as-ejb3-7.2.0.Alpha1-redhat-4.jar:7.2.0.Alpha1-redhat-4]

          at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]

          at org.jboss.as.ejb3.security.SecurityContextInterceptor.processInvocation(SecurityContextInterceptor.java:76) [jboss-as-ejb3-7.2.0.Alpha1-redhat-4.jar:7.2.0.Alpha1-redhat-4]

       

      I decided to try and remove the security domain element from jboss-app.xml this fixed the problem so I tried the following workaround and that seemed to work for me.

       

      I replaced my jboss-app.xml to how it was and added the following to my jboss-ejb3.xml file

          <s:security>
              <!-- Even wildcard * is supported -->
              <ejb-name>TaskReceiverMEJB</ejb-name>
              <!-- Name of the security domain which is configured in the EJB3 subsystem -->
              <!--<s:security-domain>AMRealmPass</s:security-domain>-->
              <s:missing-method-permissions-deny-access>false</s:missing-method-permissions-deny-access>
          </s:security>
          <s:security>
              <ejb-name>TaskDespatcherMEJB</ejb-name>
              <s:missing-method-permissions-deny-access>false</s:missing-method-permissions-deny-access>
          </s:security>
          <s:security>
              <ejb-name>TaskRunnerMEJB</ejb-name>
              <s:missing-method-permissions-deny-access>false</s:missing-method-permissions-deny-access>
          </s:security>

       

      This also resolved my problem.

       

      I have just kicked of a download of eap6 beta I will retry the application without these changes