You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@activemq.apache.org by dharmendra <dh...@gmail.com> on 2019/05/20 11:27:42 UTC

Message dropped from Queue

Hi Team , 

I am using Artemis 2.3.0 and using below broker.xml
<?xml version='1.0'?>

<configuration xmlns="urn:activemq"
               xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
               xsi:schemaLocation="urn:activemq
/schema/artemis-configuration.xsd">

   <core xmlns="urn:activemq:core"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="urn:activemq:core ">

      <name>0.0.0.0</name>

      <persistence-enabled>true</persistence-enabled>

      
      <journal-type>NIO</journal-type>

      <paging-directory>/data/activemq-artemis/paging</paging-directory>

     
<bindings-directory>/data/activemq-artemis/bindings</bindings-directory>

      <journal-directory>/data/activemq-artemis/journal</journal-directory>

     
<large-messages-directory>/data/activemq-artemis/large-messages</large-messages-directory>



      <journal-min-files>10</journal-min-files>


  <connectors>
        <connector
name="netty">tcp://${activemq.remoting.netty.host:jms.s1}:${activemq.remoting.netty.port:5445}?useEpoll=true</connector>
        <connector
name="netty-throughput">tcp://${activemq.remoting.netty.host:jms.s1}:${activemq.remoting.netty.port:5455}?useEpoll=true</connector>
  </connectors>

  <acceptors>
        <acceptor name="netty"
>tcp://${activemq.remoting.netty.host:jms.s1}:${activemq.remoting.netty.port:5445}?useEpoll=true</acceptor>
        <acceptor name="netty-throughput"
>tcp://${activemq.remoting.netty.host:jms.s1}:${activemq.remoting.netty.port:5455}?useEpoll=true</acceptor>
  </acceptors>
  <security-settings>
    <security-setting match="#">
      <permission type="createNonDurableQueue" roles="admin"/>
      <permission type="deleteNonDurableQueue" roles="admin"/>
      <permission type="createDurableQueue" roles="admin"/>
      <permission type="deleteDurableQueue" roles="admin"/>
      <permission type="createAddress" roles="admin"/>
      <permission type="deleteAddress" roles="admin"/>
      <permission type="consume" roles="admin"/>
      <permission type="browse" roles="admin"/>
      <permission type="send" roles="admin"/>
      <permission type="manage" roles="admin"/>
    </security-setting>
  </security-settings>
  <address-settings>
    <address-setting match="#">
      <dead-letter-address>jms.queue.DLQ</dead-letter-address>
      <expiry-address>jms.queue.ExpiryQueue</expiry-address>
      <redelivery-delay>0</redelivery-delay>
      <max-size-bytes>10737418240</max-size-bytes>
     
<message-counter-history-day-limit>10</message-counter-history-day-limit>
      <address-full-policy>PAGE</address-full-policy>
      <auto-create-queues>true</auto-create-queues>
      <auto-create-addresses>true</auto-create-addresses>
      <auto-create-jms-queues>false</auto-create-jms-queues>
      <auto-create-jms-topics>false</auto-create-jms-topics>
      <auto-delete-queues>false</auto-delete-queues>
          </address-setting>
  </address-settings>
  </core>
</configuration>

We are getting some load ( for example 10k msg)from client into the Queue
and approx 6k msg has been processed by consumer and but around 4 k msg is
automatically dropper from this Q and consumer didn't find anything.  I
checked logs and application logs but did n't find anything wiered but i am
surprised that why this 4k msg has been automatically flush out from this Q.
Please suggest me if any configuration missing in borker.xml or any other
possibility . We migrated it from HornetQ and at that time it worked , no
msg was dropped at that time. Please suggest any idea or configuration
missing for this broker.xml.



-----
DKumar
--
Sent from: http://activemq.2283324.n4.nabble.com/ActiveMQ-Dev-f2368404.html

Re: Message dropped from Queue

Posted by Justin Bertram <jb...@apache.org>.
Since you migrated from HornetQ I would suggest that you use
"anycastPrefix=jms.queue.;multicastPrefix=jms.topic." in your acceptors (as
noted in the default broker.xml), e.g.:

  <acceptors>
        <acceptor
name="netty">tcp://${activemq.remoting.netty.host:jms.s1}:${activemq.remoting.netty.port:5445}?useEpoll=true;anycastPrefix=jms.queue.;multicastPrefix=jms.topic.</acceptor>
        <acceptor
name="netty-throughput">tcp://${activemq.remoting.netty.host:jms.s1}:${activemq.remoting.netty.port:5455}?useEpoll=true;anycastPrefix=jms.queue.;multicastPrefix=jms.topic.</acceptor>
  </acceptors>

Setting these prefixes will allow you to avoid having to deal with them in
the rest of your configuration and management (e.g. via the web console).
Therefore, in your <address-settings> you can remove the "jms.queue"
prefixes for the <dead-letter-address> and <expiry-address>, e.g.:

   <dead-letter-address>DLQ</dead-letter-address>
   <expiry-address>ExpiryQueue</expiry-address>

Then you should actually define those addresses and queues so the messages
which are sent there are not dropped, e.g.:

   <addresses>
      <address name="DLQ">
         <anycast>
            <queue name="DLQ" />
         </anycast>
      </address>
      <address name="ExpiryQueue">
         <anycast>
            <queue name="ExpiryQueue" />
         </anycast>
      </address>
   </addresses>

Again, these are configured in the default broker.xml.

As Clebert already mentioned, you should figure out why message consumption
is being rolled back so many times to trigger sending to the
dead-letter-address. The default <max-delivery-attempts> is 10.

Lastly, you don't need to define any connectors since they aren't actually
being used by anything in your broker.xml. The whole <connectors> section
can be removed. And since both the "netty" and "netty-throughput" acceptors
are configured the exact same way you don't really need both. All clients
can simply use the same acceptor which will further simplify your
configuration.


Justin



On Mon, May 20, 2019 at 6:22 PM Clebert Suconic <cl...@gmail.com>
wrote:

> you have to create the jms.queue.DLQ... and need to avoid rollback so
> many times.
>
> On Mon, May 20, 2019 at 12:13 PM dharmendra <dh...@gmail.com>
> wrote:
> >
> > I am getting below waring as well.
> >
> > 04:35:59,074 WARN  [org.apache.activemq.artemis.core.server] AMQ222148:
> > Message
> >
> Reference[2384186268]:RELIABLE:CoreMessage[messageID=2384186268,durable=true,userID=1e691b00-7ab3-11e9-8404-5254101002a3,priority=4,
> > timestamp=Mon May 20 03:55:33 UTC 2019,expiration=0, durable=true,
> >
> address=WebServiceOutQ,properties=TypedProperties[__AMQ_CID=4c7de4d2-7787-11e9-8404-5254101002a3,_AMQ_ROUTING_TYPE=1,internalType=WSOut,ServiceDefinitionObjID=1099529435,partition=default,isFromConverter=true]]@1368268885
> > has exceeded max delivery attempts. No bindings for Dead Letter Address
> > jms.queue.DLQ so dropping it
> > What changes do i make it  to work
> >
> >
> >
> > -----
> > DKumar
> > --
> > Sent from:
> http://activemq.2283324.n4.nabble.com/ActiveMQ-Dev-f2368404.html
>
>
>
> --
> Clebert Suconic
>

Re: Message dropped from Queue

Posted by Clebert Suconic <cl...@gmail.com>.
you have to create the jms.queue.DLQ... and need to avoid rollback so
many times.

On Mon, May 20, 2019 at 12:13 PM dharmendra <dh...@gmail.com> wrote:
>
> I am getting below waring as well.
>
> 04:35:59,074 WARN  [org.apache.activemq.artemis.core.server] AMQ222148:
> Message
> Reference[2384186268]:RELIABLE:CoreMessage[messageID=2384186268,durable=true,userID=1e691b00-7ab3-11e9-8404-5254101002a3,priority=4,
> timestamp=Mon May 20 03:55:33 UTC 2019,expiration=0, durable=true,
> address=WebServiceOutQ,properties=TypedProperties[__AMQ_CID=4c7de4d2-7787-11e9-8404-5254101002a3,_AMQ_ROUTING_TYPE=1,internalType=WSOut,ServiceDefinitionObjID=1099529435,partition=default,isFromConverter=true]]@1368268885
> has exceeded max delivery attempts. No bindings for Dead Letter Address
> jms.queue.DLQ so dropping it
> What changes do i make it  to work
>
>
>
> -----
> DKumar
> --
> Sent from: http://activemq.2283324.n4.nabble.com/ActiveMQ-Dev-f2368404.html



-- 
Clebert Suconic

Re: Message dropped from Queue

Posted by dharmendra <dh...@gmail.com>.
I am getting below waring as well. 

04:35:59,074 WARN  [org.apache.activemq.artemis.core.server] AMQ222148:
Message
Reference[2384186268]:RELIABLE:CoreMessage[messageID=2384186268,durable=true,userID=1e691b00-7ab3-11e9-8404-5254101002a3,priority=4,
timestamp=Mon May 20 03:55:33 UTC 2019,expiration=0, durable=true,
address=WebServiceOutQ,properties=TypedProperties[__AMQ_CID=4c7de4d2-7787-11e9-8404-5254101002a3,_AMQ_ROUTING_TYPE=1,internalType=WSOut,ServiceDefinitionObjID=1099529435,partition=default,isFromConverter=true]]@1368268885
has exceeded max delivery attempts. No bindings for Dead Letter Address
jms.queue.DLQ so dropping it
What changes do i make it  to work



-----
DKumar
--
Sent from: http://activemq.2283324.n4.nabble.com/ActiveMQ-Dev-f2368404.html

Re: Message dropped from Queue

Posted by dharmendra <dh...@gmail.com>.
Thanks clebertsuconic!

I am creating Queues using code and i also checked DLQ which is always 0 not
sure why. Is there anything missing in broker.xml? If artmis is already
running in proruction and i try to explort msg using ./artemis data exp or
print then it does not allow me to run again and port bind exception. Could
you please suggest any other to export journal. Please suggest.



-----
DKumar
--
Sent from: http://activemq.2283324.n4.nabble.com/ActiveMQ-Dev-f2368404.html

Re: Message dropped from Queue

Posted by Clebert Suconic <cl...@gmail.com>.
How are you creating the queue?


I would check the ./artemis data print, or artemis export to see what
happened to your journal.


Queues are not dropped unless you configured it to do so.


Check also the DLQ.. but the data print will probably help you find
where these messages are.

On Mon, May 20, 2019 at 7:27 AM dharmendra <dh...@gmail.com> wrote:
>
> Hi Team ,
>
> I am using Artemis 2.3.0 and using below broker.xml
> <?xml version='1.0'?>
>
> <configuration xmlns="urn:activemq"
>                xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>                xsi:schemaLocation="urn:activemq
> /schema/artemis-configuration.xsd">
>
>    <core xmlns="urn:activemq:core"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>          xsi:schemaLocation="urn:activemq:core ">
>
>       <name>0.0.0.0</name>
>
>       <persistence-enabled>true</persistence-enabled>
>
>
>       <journal-type>NIO</journal-type>
>
>       <paging-directory>/data/activemq-artemis/paging</paging-directory>
>
>
> <bindings-directory>/data/activemq-artemis/bindings</bindings-directory>
>
>       <journal-directory>/data/activemq-artemis/journal</journal-directory>
>
>
> <large-messages-directory>/data/activemq-artemis/large-messages</large-messages-directory>
>
>
>
>       <journal-min-files>10</journal-min-files>
>
>
>   <connectors>
>         <connector
> name="netty">tcp://${activemq.remoting.netty.host:jms.s1}:${activemq.remoting.netty.port:5445}?useEpoll=true</connector>
>         <connector
> name="netty-throughput">tcp://${activemq.remoting.netty.host:jms.s1}:${activemq.remoting.netty.port:5455}?useEpoll=true</connector>
>   </connectors>
>
>   <acceptors>
>         <acceptor name="netty"
> >tcp://${activemq.remoting.netty.host:jms.s1}:${activemq.remoting.netty.port:5445}?useEpoll=true</acceptor>
>         <acceptor name="netty-throughput"
> >tcp://${activemq.remoting.netty.host:jms.s1}:${activemq.remoting.netty.port:5455}?useEpoll=true</acceptor>
>   </acceptors>
>   <security-settings>
>     <security-setting match="#">
>       <permission type="createNonDurableQueue" roles="admin"/>
>       <permission type="deleteNonDurableQueue" roles="admin"/>
>       <permission type="createDurableQueue" roles="admin"/>
>       <permission type="deleteDurableQueue" roles="admin"/>
>       <permission type="createAddress" roles="admin"/>
>       <permission type="deleteAddress" roles="admin"/>
>       <permission type="consume" roles="admin"/>
>       <permission type="browse" roles="admin"/>
>       <permission type="send" roles="admin"/>
>       <permission type="manage" roles="admin"/>
>     </security-setting>
>   </security-settings>
>   <address-settings>
>     <address-setting match="#">
>       <dead-letter-address>jms.queue.DLQ</dead-letter-address>
>       <expiry-address>jms.queue.ExpiryQueue</expiry-address>
>       <redelivery-delay>0</redelivery-delay>
>       <max-size-bytes>10737418240</max-size-bytes>
>
> <message-counter-history-day-limit>10</message-counter-history-day-limit>
>       <address-full-policy>PAGE</address-full-policy>
>       <auto-create-queues>true</auto-create-queues>
>       <auto-create-addresses>true</auto-create-addresses>
>       <auto-create-jms-queues>false</auto-create-jms-queues>
>       <auto-create-jms-topics>false</auto-create-jms-topics>
>       <auto-delete-queues>false</auto-delete-queues>
>           </address-setting>
>   </address-settings>
>   </core>
> </configuration>
>
> We are getting some load ( for example 10k msg)from client into the Queue
> and approx 6k msg has been processed by consumer and but around 4 k msg is
> automatically dropper from this Q and consumer didn't find anything.  I
> checked logs and application logs but did n't find anything wiered but i am
> surprised that why this 4k msg has been automatically flush out from this Q.
> Please suggest me if any configuration missing in borker.xml or any other
> possibility . We migrated it from HornetQ and at that time it worked , no
> msg was dropped at that time. Please suggest any idea or configuration
> missing for this broker.xml.
>
>
>
> -----
> DKumar
> --
> Sent from: http://activemq.2283324.n4.nabble.com/ActiveMQ-Dev-f2368404.html



-- 
Clebert Suconic