Uploaded image for project: 'JBoss Enterprise Application Platform'
  1. JBoss Enterprise Application Platform
  2. JBEAP-22752

[GSS](7.4.z) Configuring Messaging Clustering With Static Connectors (non-jgroups) Results in Many TIMED_WAIT Connections

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Not a Bug
    • Icon: Major Major
    • None
    • 7.4.0.GA, 7.4.1.CR1
    • A-MQ7, ActiveMQ, JMS
    • None
    • False
    • False
    • Hide

      jgroups tcpping seems to worl without issue.

      Show
      jgroups tcpping seems to worl without issue.
    • Hide

      Configure a live/backup pair with static connectors (non-jgroups):

              <subsystem xmlns="urn:jboss:domain:messaging-activemq:13.0">
                  <server name="active">
                      <statistics enabled="${wildfly.messaging-activemq.statistics-enabled:${wildfly.statistics-enabled:false}}"/>
                      <cluster password="admin" user="admin123"/>
                      <journal type="NIO" file-size="102400" min-files="2"/>
                      <shared-store-master failover-on-server-shutdown="true"/>
                      <bindings-directory path="/opt/nfs/apps/node1/bindings"/>
                      <journal-directory path="/opt/nfs/apps/node1/journal"/>
                      <paging-directory path="/opt/nfs/apps/node1/paging"/>
                      <large-messages-directory path="/opt/nfs/apps/node1/largemessages"/>
                      <security-setting name="#">
                          <role name="guest" send="true" consume="true" create-non-durable-queue="true" delete-non-durable-queue="true"/>
                      </security-setting>
                      <address-setting name="#" dead-letter-address="jms.queue.DLQ" expiry-address="jms.queue.ExpiryQueue" max-size-bytes="10485760" page-size-bytes="2097152" message-counter-history-day-limit="10"/>
                      <http-connector name="http-connector" socket-binding="http" endpoint="http-acceptor"/>
                      <http-connector name="http-connector-throughput" socket-binding="http" endpoint="http-acceptor-throughput">
                          <param name="batch-delay" value="50"/>
                      </http-connector>
                      <http-connector name="jms-remote-connector" socket-binding="remote-amq-node-2-socket-binding" endpoint="http-acceptor"/>
                      <in-vm-connector name="in-vm" server-id="0">
                          <param name="buffer-pooling" value="false"/>
                      </in-vm-connector>
                      <http-acceptor name="http-acceptor" http-listener="default"/>
                      <http-acceptor name="http-acceptor-throughput" http-listener="default">
                          <param name="batch-delay" value="50"/>
                          <param name="direct-deliver" value="false"/>
                      </http-acceptor>
                      <in-vm-acceptor name="in-vm" server-id="0">
                          <param name="buffer-pooling" value="false"/>
                      </in-vm-acceptor>
                      <cluster-connection name="my-cluster" address="#" connector-name="http-connector" message-load-balancing-type="STRICT" static-connectors="jms-remote-connector"/>
                      <jms-queue name="ExpiryQueue" entries="java:/jms/queue/ExpiryQueue"/>
                      <jms-queue name="DLQ" entries="java:/jms/queue/DLQ"/>
                      <jms-queue name="testQueue" entries="queue/test java:jboss/exported/jms/queue/test"/>
                      <jms-topic name="testTopic" entries="topic/test java:jboss/exported/jms/topic/test"/>
                      <connection-factory name="InVmConnectionFactory" entries="java:/ConnectionFactory" connectors="in-vm"/>
                      <connection-factory name="RemoteConnectionFactory" entries="java:jboss/exported/jms/RemoteConnectionFactory" connectors="http-connector"/>
                      <pooled-connection-factory name="activemq-ra" entries="java:/JmsXA java:jboss/DefaultJMSConnectionFactory" connectors="in-vm" transaction="xa"/>
                  </server>
              </subsystem>
      ...
              <outbound-socket-binding name="remote-amq-node-2-socket-binding">
                  <remote-destination host="node2.test.redhat.com" port="8080"/>
              </outbound-socket-binding>
      
              <subsystem xmlns="urn:jboss:domain:messaging-activemq:13.0">
                  <server name="standby">
                      <statistics enabled="${wildfly.messaging-activemq.statistics-enabled:${wildfly.statistics-enabled:false}}"/>
                      <cluster password="admin" user="admin123"/>
                      <journal type="NIO" file-size="102400" min-files="2"/>
                      <shared-store-slave allow-failback="true" failover-on-server-shutdown="true"/>
                      <bindings-directory path="/opt/nfs/apps/node1/bindings"/>
                      <journal-directory path="/opt/nfs/apps/node1/journal"/>
                      <paging-directory path="/opt/nfs/apps/node1/paging"/>
                      <large-messages-directory path="/opt/nfs/apps/node1/largemessages"/>
                      <security-setting name="#">
                          <role name="guest" send="true" consume="true" create-non-durable-queue="true" delete-non-durable-queue="true"/>
                      </security-setting>
                      <address-setting name="#" dead-letter-address="jms.queue.DLQ" expiry-address="jms.queue.ExpiryQueue" max-size-bytes="10485760" page-size-bytes="2097152" message-counter-history-day-limit="10"/>
                      <http-connector name="http-connector" socket-binding="http" endpoint="http-acceptor"/>
                      <http-connector name="http-connector-throughput" socket-binding="http" endpoint="http-acceptor-throughput">
                          <param name="batch-delay" value="50"/>
                      </http-connector>
                      <http-connector name="jms-remote-connector" socket-binding="remote-amq-node-1-socket-binding" endpoint="http-acceptor"/>
                      <in-vm-connector name="in-vm" server-id="0">
                          <param name="buffer-pooling" value="false"/>
                      </in-vm-connector>
                      <http-acceptor name="http-acceptor" http-listener="default"/>
                      <http-acceptor name="http-acceptor-throughput" http-listener="default">
                          <param name="batch-delay" value="50"/>
                          <param name="direct-deliver" value="false"/>
                      </http-acceptor>
                      <in-vm-acceptor name="in-vm" server-id="0">
                          <param name="buffer-pooling" value="false"/>
                      </in-vm-acceptor>
                      <cluster-connection name="my-cluster" address="#" connector-name="http-connector" message-load-balancing-type="STRICT" static-connectors="jms-remote-connector"/>
                      <jms-queue name="ExpiryQueue" entries="java:/jms/queue/ExpiryQueue"/>
                      <jms-queue name="DLQ" entries="java:/jms/queue/DLQ"/>
                      <jms-queue name="testQueue" entries="queue/test java:jboss/exported/jms/queue/test"/>
                      <jms-topic name="testTopic" entries="topic/test java:jboss/exported/jms/topic/test"/>
                      <connection-factory name="InVmConnectionFactory" entries="java:/ConnectionFactory" connectors="in-vm"/>
                      <connection-factory name="RemoteConnectionFactory" entries="java:jboss/exported/jms/RemoteConnectionFactory" connectors="http-connector"/>
                      <pooled-connection-factory name="activemq-ra" entries="java:/JmsXA java:jboss/DefaultJMSConnectionFactory" connectors="in-vm" transaction="xa"/>
                  </server>
              </subsystem>
      ...
              <outbound-socket-binding name="remote-amq-node-1-socket-binding">
                  <remote-destination host="node1.test.redhat.com" port="8080"/>
              </outbound-socket-binding>
      

      Start up the pair and observe that the backup broker does not announce. Check netstat -anp on the broker nodes and observe that there are numerous connections in TIMED-WAIT / closing states.

      Show
      Configure a live/backup pair with static connectors (non-jgroups): <subsystem xmlns= "urn:jboss:domain:messaging-activemq:13.0" > <server name= "active" > <statistics enabled= "${wildfly.messaging-activemq.statistics-enabled:${wildfly.statistics-enabled:false}}" /> <cluster password= "admin" user= "admin123" /> <journal type= "NIO" file-size= "102400" min-files= "2" /> <shared-store-master failover-on-server-shutdown= "true" /> <bindings-directory path= "/opt/nfs/apps/node1/bindings" /> <journal-directory path= "/opt/nfs/apps/node1/journal" /> <paging-directory path= "/opt/nfs/apps/node1/paging" /> <large-messages-directory path= "/opt/nfs/apps/node1/largemessages" /> <security-setting name= "#" > <role name= "guest" send= "true" consume= "true" create-non-durable-queue= "true" delete-non-durable-queue= "true" /> </security-setting> <address-setting name= "#" dead-letter-address= "jms.queue.DLQ" expiry-address= "jms.queue.ExpiryQueue" max-size-bytes= "10485760" page-size-bytes= "2097152" message-counter-history-day-limit= "10" /> <http-connector name= "http-connector" socket-binding= "http" endpoint= "http-acceptor" /> <http-connector name= "http-connector-throughput" socket-binding= "http" endpoint= "http-acceptor-throughput" > <param name= "batch-delay" value= "50" /> </http-connector> <http-connector name= "jms-remote-connector" socket-binding= "remote-amq-node-2-socket-binding" endpoint= "http-acceptor" /> <in-vm-connector name= "in-vm" server-id= "0" > <param name= "buffer-pooling" value= "false" /> </in-vm-connector> <http-acceptor name= "http-acceptor" http-listener= "default" /> <http-acceptor name= "http-acceptor-throughput" http-listener= "default" > <param name= "batch-delay" value= "50" /> <param name= "direct-deliver" value= "false" /> </http-acceptor> <in-vm-acceptor name= "in-vm" server-id= "0" > <param name= "buffer-pooling" value= "false" /> </in-vm-acceptor> <cluster-connection name= "my-cluster" address= "#" connector-name= "http-connector" message-load-balancing-type= "STRICT" static-connectors= "jms-remote-connector" /> <jms-queue name= "ExpiryQueue" entries= "java:/jms/queue/ExpiryQueue" /> <jms-queue name= "DLQ" entries= "java:/jms/queue/DLQ" /> <jms-queue name= "testQueue" entries= "queue/test java:jboss/exported/jms/queue/test" /> <jms-topic name= "testTopic" entries= "topic/test java:jboss/exported/jms/topic/test" /> <connection-factory name= "InVmConnectionFactory" entries= "java:/ConnectionFactory" connectors= "in-vm" /> <connection-factory name= "RemoteConnectionFactory" entries= "java:jboss/exported/jms/RemoteConnectionFactory" connectors= "http-connector" /> <pooled-connection-factory name= "activemq-ra" entries= "java:/JmsXA java:jboss/DefaultJMSConnectionFactory" connectors= "in-vm" transaction= "xa" /> </server> </subsystem> ... <outbound-socket-binding name= "remote-amq-node-2-socket-binding" > <remote-destination host= "node2.test.redhat.com" port= "8080" /> </outbound-socket-binding> <subsystem xmlns= "urn:jboss:domain:messaging-activemq:13.0" > <server name= "standby" > <statistics enabled= "${wildfly.messaging-activemq.statistics-enabled:${wildfly.statistics-enabled:false}}" /> <cluster password= "admin" user= "admin123" /> <journal type= "NIO" file-size= "102400" min-files= "2" /> <shared-store-slave allow-failback= "true" failover-on-server-shutdown= "true" /> <bindings-directory path= "/opt/nfs/apps/node1/bindings" /> <journal-directory path= "/opt/nfs/apps/node1/journal" /> <paging-directory path= "/opt/nfs/apps/node1/paging" /> <large-messages-directory path= "/opt/nfs/apps/node1/largemessages" /> <security-setting name= "#" > <role name= "guest" send= "true" consume= "true" create-non-durable-queue= "true" delete-non-durable-queue= "true" /> </security-setting> <address-setting name= "#" dead-letter-address= "jms.queue.DLQ" expiry-address= "jms.queue.ExpiryQueue" max-size-bytes= "10485760" page-size-bytes= "2097152" message-counter-history-day-limit= "10" /> <http-connector name= "http-connector" socket-binding= "http" endpoint= "http-acceptor" /> <http-connector name= "http-connector-throughput" socket-binding= "http" endpoint= "http-acceptor-throughput" > <param name= "batch-delay" value= "50" /> </http-connector> <http-connector name= "jms-remote-connector" socket-binding= "remote-amq-node-1-socket-binding" endpoint= "http-acceptor" /> <in-vm-connector name= "in-vm" server-id= "0" > <param name= "buffer-pooling" value= "false" /> </in-vm-connector> <http-acceptor name= "http-acceptor" http-listener= "default" /> <http-acceptor name= "http-acceptor-throughput" http-listener= "default" > <param name= "batch-delay" value= "50" /> <param name= "direct-deliver" value= "false" /> </http-acceptor> <in-vm-acceptor name= "in-vm" server-id= "0" > <param name= "buffer-pooling" value= "false" /> </in-vm-acceptor> <cluster-connection name= "my-cluster" address= "#" connector-name= "http-connector" message-load-balancing-type= "STRICT" static-connectors= "jms-remote-connector" /> <jms-queue name= "ExpiryQueue" entries= "java:/jms/queue/ExpiryQueue" /> <jms-queue name= "DLQ" entries= "java:/jms/queue/DLQ" /> <jms-queue name= "testQueue" entries= "queue/test java:jboss/exported/jms/queue/test" /> <jms-topic name= "testTopic" entries= "topic/test java:jboss/exported/jms/topic/test" /> <connection-factory name= "InVmConnectionFactory" entries= "java:/ConnectionFactory" connectors= "in-vm" /> <connection-factory name= "RemoteConnectionFactory" entries= "java:jboss/exported/jms/RemoteConnectionFactory" connectors= "http-connector" /> <pooled-connection-factory name= "activemq-ra" entries= "java:/JmsXA java:jboss/DefaultJMSConnectionFactory" connectors= "in-vm" transaction= "xa" /> </server> </subsystem> ... <outbound-socket-binding name= "remote-amq-node-1-socket-binding" > <remote-destination host= "node1.test.redhat.com" port= "8080" /> </outbound-socket-binding> Start up the pair and observe that the backup broker does not announce. Check netstat -anp on the broker nodes and observe that there are numerous connections in TIMED-WAIT / closing states.

      In an HA cluster (shared store master/slave), when the messaging component is configured with a static-connectors list on the cluster-connection element, the cluster-connection remains inactive on the backup node, with the result that the live broker repeatedly fails to contact the backup, leaving 100s of connections in a TIMED_WAIT state. The backup also fails to announce.

              thofman Tomas Hofman
              rhn-support-dhawkins Duane Hawkins
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: