3 Replies Latest reply on Jun 28, 2012 10:29 AM by burgosjc

    MessageDriver error

    burgosjc

      I have the following situation:

      I require to deploy a. RAR on the server
      7.1.1 and invoke this from @ MessageDriven like this below:


      @MessageDriven(messageListenerInterface = SocketMessageEndpoint.class,
          activationConfig={
              @ActivationConfigProperty(propertyName = "ipAddress", propertyValue="10.0.1.10"),
              @ActivationConfigProperty(propertyName = "port", propertyValue="45001"),
              @ActivationConfigProperty(propertyName = "encoding", propertyValue="UTF-8"),
              @ActivationConfigProperty(propertyName = "maximumConnections", propertyValue="10"),
              @ActivationConfigProperty(propertyName = "connectionTimeoutMilliseconds", propertyValue="3000")
      })
      @Resource(name="socket.rar")
      public class SocketMessageDrivenBean implements SocketMessageEndpoint {
      
      

       

       

       

      The rar is deployed correctly, but when building the MessageDriver generates the following error:

       


      Caused by: java.lang.IllegalStateException: JBAS014521: No message listener of type  socket.api.SocketMessageEndpoint found in resource adapter hornetq-ra
      
      

       

       

      I've tried using the annotation @ ResourceAdapter and also fails to recognize. Any ideas

       

       

       


        • 1. Re: MessageDriver error
          burgosjc

          To rule it issues. Rar, change in the standalone.xml,  the resource-adapter-ref default to hornetq -ra for me socket.rar, start the server and everything works fine.

           

          Before

          <subsystem xmlns="urn:jboss:domain:ejb3:1.2">

             <mdb>

                 <resource-adapter-ref resource-adapter-name="hornetq-ra"/>

                 <bean-instance-pool-ref pool-name="mdb-strict-max-pool"/>

             </mdb>

           

           

          After

          <subsystem xmlns="urn:jboss:domain:ejb3:1.2">

            <mdb>

                 <resource-adapter-ref resource-adapter-name="socket.rar"/>

                 <bean-instance-pool-ref pool-name="mdb-strict-max-pool"/>

             </mdb>

           

          My concern is when you need to implement queues in my application .. will be presented again the error

          • 2. Re: MessageDriver error
            jaikiran

            @Resource(name="socket.rar")

             

            This is incorrect. It should be:

             

            @org.jboss.ejb3.annotation.ResourceAdapter(value = "socket.rar")
            
            • 3. Re: MessageDriver error
              burgosjc

              Jaikiran thank you very much, I is loading correctly