Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 01718200B65 for ; Wed, 17 Aug 2016 13:16:29 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id F4210160A86; Wed, 17 Aug 2016 11:16:29 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 484FC160A8C for ; Wed, 17 Aug 2016 13:16:28 +0200 (CEST) Received: (qmail 65913 invoked by uid 500); 17 Aug 2016 11:16:22 -0000 Mailing-List: contact issues-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@activemq.apache.org Delivered-To: mailing list issues@activemq.apache.org Received: (qmail 65658 invoked by uid 99); 17 Aug 2016 11:16:22 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 17 Aug 2016 11:16:22 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 0949E2C02AC for ; Wed, 17 Aug 2016 11:16:22 +0000 (UTC) Date: Wed, 17 Aug 2016 11:16:22 +0000 (UTC) From: "ASF GitHub Bot (JIRA)" To: issues@activemq.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (ARTEMIS-684) Client connection are not balanced across cluster with any load balancing policy MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Wed, 17 Aug 2016 11:16:29 -0000 [ https://issues.apache.org/jira/browse/ARTEMIS-684?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15424309#comment-15424309 ] ASF GitHub Bot commented on ARTEMIS-684: ---------------------------------------- GitHub user bayern39 opened a pull request: https://github.com/apache/activemq-artemis/pull/724 [ARTEMIS-684] Client connection are not balanced across cluster with any load balancing policy https://issues.apache.org/jira/browse/ARTEMIS-684 You can merge this pull request into a Git repository by running: $ git pull https://github.com/bayern39/activemq-artemis Artemis-load-balancing Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/724.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 #724 ---- commit c292c494d87e0ccda8842ced0097f18b7f4933e8 Author: bayern39 Date: 2016-08-17T10:44:37Z [ARTEMIS-684] Client connection are not balanced across cluster with any load balancing policy commit 129c02ee5742f2d9bd075e10027d5739cc99ba1e Author: bayern39 Date: 2016-08-17T11:06:27Z fixing typos ---- > Client connection are not balanced across cluster with any load balancing policy > -------------------------------------------------------------------------------- > > Key: ARTEMIS-684 > URL: https://issues.apache.org/jira/browse/ARTEMIS-684 > Project: ActiveMQ Artemis > Issue Type: Bug > Affects Versions: 1.4.0 > Reporter: Chen Maoqian > Priority: Critical > > * Start two EAP instances with configuration attached to this JIRA as a {{standalone-full-ha.xml}} file. > * Unzip simple reproducer attached as a {{connection-balancing-reproducer.zip}}. It is simple maven project, only slightly adjusted helloword jms quickstart. There are 100 producers, each send 1000 messages to queue with 5 second delay between sends. > * Run reproducer and open CLI for both servers > * In CLI switch to {{/subsystem=messaging-activemq/server=default}} and invoke {{:list-connection-ids}} on both servers > *Scenario* > There two nodes in cluster. Nodes in cluster are connected and both nodes have same jms destinations and connection factory defined like the following one > {noformat} > > {noformat} > There are clients connecting to cluster. With _RandomConnectionLoadBalancingPolicy_, I would expect that connections are randomly distributed among the nodes in cluster. However, when I list connections on both nodes (/subsystem=messaging-activemq/server=default:list-connection-ids), all connections are on one server. > Method {{private TransportConfiguration selectConnector()}} in class {{ServerLocatorImpl}} checks whether the {{topologyArray}} is null and makes decision between choosing connector to other node in topology or initial connector of connection factory. In method {{private TransportConfiguration selectConnector()}} {{topologyArray}} is still null, so clients make connection using initial connector. It seems like {{topologyArray}} is only updated during {{notifyNodeUp/Down}} methods. > Could you please explain how is this client connection balancing supposed to work? -- This message was sent by Atlassian JIRA (v6.3.4#6332)