activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "" <>
Subject master / backup cluster-connection options not working?
Date Thu, 11 Jul 2019 17:36:53 GMT
Artemis 2.9.0. (as well as 2.6.3 where I first was testing).

I've got a working master / backup cluster, using static connectors.  My
server broker.xml has these components:




      <cluster-connection name="${bc.core.deploy.env}-cluster">
        <static-connectors allow-direct-connections-only="true">

I want to adjust the behaviour when (for example) master starts up and the
backup server isn't present.  With the above, the master console just shows
exception after exception like this:

 2019-07-11 15:38:45,750 ERROR [org.apache.activemq.artemis.core.client]
AMQ214016: Failed to create netty connection:
activemqmaster_1     |  at [rt.jar:1.8.0_212]

every half second.  (Well - twice every half second for some reason - there
seem to be two threads or something trying to connect to the backup server).

When I try to add options into the <cluster-connection>, some of them work,
some of them don't seem to work, and some cause compile errors when Artemis
starts up.  For example, adding: 


setting works - the retries go from every half second to every 2 seconds
(although there seem to be two threads trying to connect).


doesn't seem to make any difference - the exceptions still come every 2

Adding a 


to try to limit the initial number of connection attempts yields an error 

activemqmaster_1     | Caused by: org.xml.sax.SAXParseException;
cvc-complex-type.2.4.a: Invalid content was found starting with element
'initial-connect-attempts'. One of
"urn:activemq:core":message-load-balancing, "urn:activemq:core":max-hops,
"urn:activemq:core":discovery-group-ref}' is expected.
activemqmaster_1     |  at

when I look at the artemis-configuration.xsd, the "cluster-connectionType"
has "initial-connect-attempts" defined.
         <xsd:element name="initial-connect-attempts" type="xsd:int"
default="-1" maxOccurs="1" minOccurs="0">
                  How many attempts should be made to connect initially

What I'm trying to get to is something like this:

      <cluster-connection name="${bc.core.deploy.env}-cluster">
        <static-connectors allow-direct-connections-only="true">

Does anyone have any ideas on what I might be doing wrong?


Sent from:

View raw message