You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@activemq.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2018/10/31 17:56:00 UTC

[jira] [Commented] (ARTEMIS-2160) Cluster connection non-default configuration elements ignored

    [ https://issues.apache.org/jira/browse/ARTEMIS-2160?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16670464#comment-16670464 ] 

ASF GitHub Bot commented on ARTEMIS-2160:
-----------------------------------------

GitHub user RoddieKieley opened a pull request:

    https://github.com/apache/activemq-artemis/pull/2408

    ARTEMIS-2160: Addressed occurance where cluster configuration on serv…

    …er locator was hard coded. Covered with test.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/RoddieKieley/activemq-artemis ARTEMIS-2160

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/activemq-artemis/pull/2408.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #2408
    
----
commit 2198ab8c1130133f503273860b8a97cceb7a8084
Author: Roddie Kieley <rk...@...>
Date:   2018-10-31T17:34:07Z

    ARTEMIS-2160: Addressed occurance where cluster configuration on server locator was hard coded. Covered with test.

----


> Cluster connection non-default configuration elements ignored
> -------------------------------------------------------------
>
>                 Key: ARTEMIS-2160
>                 URL: https://issues.apache.org/jira/browse/ARTEMIS-2160
>             Project: ActiveMQ Artemis
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 2.6.3
>         Environment: RHEL 7.5
> OpenShift 3.9
> JDK 1.8
>  
>            Reporter: Roddie Kieley
>            Priority: Major
>
> In doing some testing that required non-default values for the cluster connection options for reconnectAttempts and retryInterval it was seen, when TRACE logging was on, that the setting provided were not adhere'd to and instead utilized what appeared to be default values:
> {code:java}
> 2018-10-12 02:19:20,290 FINE  [org.apache.commons.beanutils.BeanUtils] BeanUtils.populate(ClusterConnectionConfiguration{name='null', address='', connectorName='null', clientFailureCheckPeriod=30000, connectionTTL=60000, retryInterval=500, retryIntervalMultiplier=1.0, maxRetryInterval=2000, initialConnectAttempts=-1, reconnectAttempts=-1, callTimeout=30000, callFailoverTimeout=-1, duplicateDetection=true, messageLoadBalancingType=ON_DEMAND, compositeMembers=null, staticConnectors=[], discoveryGroupName='my-discovery-group', maxHops=1, confirmationWindowSize=10485760, allowDirectConnectionsOnly=false, minLargeMessageSize=102400, clusterNotificationInterval=1000, clusterNotificationAttempts=2}, {retryIntervalMultiplier=2, reconnectAttempts=10, maxHops=1, messageLoadBalancingType=ON_DEMAND, connectorName=artemis, retryInterval=500, useDuplicateDetection=true})
> .
> .
> .
> 2018-10-12 02:19:20,311 FINE  [org.apache.commons.beanutils.converters.LongConverter]     Converted to Long value '500'
> Adding cluster connection :: ClusterConnectionConfiguration{name='my-cluster', address='', connectorName='artemis', clientFailureCheckPeriod=30000, connectionTTL=60000, retryInterval=500, retryIntervalMultiplier=2.0, maxRetryInterval=2000, initialConnectAttempts=-1, reconnectAttempts=10, callTimeout=30000, callFailoverTimeout=-1, duplicateDetection=true, messageLoadBalancingType=ON_DEMAND, compositeMembers=null, staticConnectors=[], discoveryGroupName='my-discovery-group', maxHops=1, confirmationWindowSize=10485760, allowDirectConnectionsOnly=false, minLargeMessageSize=102400, clusterNotificationInterval=1000, clusterNotificationAttempts=2}
> .
> .
> .
> {code}
> and
> {code:java}
> 2018-10-12 02:21:26,464 TRACE [org.apache.activemq.artemis.core.client.impl.ClientSessionFactoryImpl] getConnectionWithRetry::-1 with retryInterval = 2000 multiplier = 1.0: java.lang.Exception: trace
> .
> .
> .
> 2018-10-12 02:21:26,508 DEBUG [org.apache.activemq.artemis.core.client.impl.ClientSessionFactoryImpl] Trying reconnection attempt 0/-1
> 2018-10-12 02:21:26,508 DEBUG [org.apache.activemq.artemis.core.client.impl.ClientSessionFactoryImpl] Trying to connect with connectorFactory = org.apache.activemq.artemis.core.remoting.impl.netty.NettyConnectorFactory@2dd61eef, connectorConfig=TransportConfiguration(name=artemis, factory=org-apache-activemq-artemis-core-remoting-impl-netty-NettyConnectorFactory) ?port=61616&host=application34-amq-1-amq34-amq-headless-amq72-clustered-53-svc-cluster-local
> 2018-10-12 02:21:26,508 DEBUG [org.apache.activemq.artemis.core.remoting.impl.netty.NettyConnector] Connector NettyConnector [host=application34-amq-1.amq34-amq-headless.amq72-clustered-53.svc.cluster.local, port=61616, httpEnabled=false, httpUpgradeEnabled=false, useServlet=false, servletPath=/messaging/ActiveMQServlet, sslEnabled=false, useNio=true] using native epoll
> .
> .
> .
> 2018-10-12 02:22:30,949 DEBUG [org.apache.activemq.artemis.core.client.impl.ClientSessionFactoryImpl] Trying reconnection attempt 32/-1
> 2018-10-12 02:22:30,949 DEBUG [org.apache.activemq.artemis.core.client.impl.ClientSessionFactoryImpl] Trying to connect with connectorFactory = org.apache.activemq.artemis.core.remoting.impl.netty.NettyConnectorFactory@2dd61eef, connectorConfig=TransportConfiguration(name=artemis, factory=org-apache-activemq-artemis-core-remoting-impl-netty-NettyConnectorFactory) ?port=61616&host=application34-amq-1-amq34-amq-headless-amq72-clustered-53-svc-cluster-local
> 2018-10-12 02:22:30,950 DEBUG [org.apache.activemq.artemis.core.remoting.impl.netty.NettyConnector] Connector NettyConnector [host=application34-amq-1.amq34-amq-headless.amq72-clustered-53.svc.cluster.local, port=61616, httpEnabled=false, httpUpgradeEnabled=false, useServlet=false, servletPath=/messaging/ActiveMQServlet, sslEnabled=false, useNio=true] using native epoll
> {code}
> Generated from a configuration of:
> {code:xml}
> <broadcast-groups>
>   <broadcast-group name="my-broadcast-group">
>     <jgroups-file>jgroups-ping.xml</jgroups-file>
>     <jgroups-channel>activemq_broadcast_channel</jgroups-channel>
>     <connector-ref>artemis</connector-ref>
>   </broadcast-group>
> </broadcast-groups>
> {code}
>  
> {code:xml}
> <discovery-groups>
>   <discovery-group name="my-discovery-group">
>     <jgroups-file>jgroups-ping.xml</jgroups-file>
>     <jgroups-channel>activemq_broadcast_channel</jgroups-channel>
>     <refresh-timeout>10000</refresh-timeout>
>   </discovery-group>
> </discovery-groups>
> {code}
>  
> {code:xml}
> <cluster-connections>
>   <cluster-connection-uri address="multicast://my-discoverygroup?messageLoadBalancingType=ON_DEMAND;retryInterval=500;retryIntervalMultiplier=2;reconnectAttempts=10;useDuplicateDetection=true;connectorName=artemis;maxHops=1" name="my-cluster"/>
> </cluster-connections>
> {code}
> also with the cluster-connections defined as
> {code:xml}
> <cluster-connections>
>   <cluster-connection name="my-cluster">
>     <connector-ref>artemis</connector-ref>
>     <retry-interval>1000</retry-interval>
>     <retry-interval-multiplier>2.0</retry-interval-multiplier>
>     <max-retry-interval>600000</max-retry-interval>
>     <initial-connect-attempts>20</initial-connect-attempts>
>     <reconnect-attempts>10</reconnect-attempts>
>     <use-duplicate-detection>true</use-duplicate-detection>
>     <message-load-balancing>ON_DEMAND</message-load-balancing>
>     <max-hops>1</max-hops>
>     <discovery-group-ref discovery-group-name="my-discovery-group"/>
>   </cluster-connection>
> </cluster-connections>
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)