[GitHub] activemq-artemis issue #2478: ARTEMIS-2210 Fix PagingStore creation synchron...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2478 @franz1981 Title changed. Thanks mate! ---
[GitHub] activemq-artemis pull request #2478: ARTEMIS-2210 PagingStore creation is no...
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/2478#discussion_r243866712 --- Diff: artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/impl/PagingManagerImpl.java --- @@ -335,19 +335,25 @@ public void deletePageStore(final SimpleString storeName) throws Exception { } /** -* stores is a ConcurrentHashMap, so we don't need to synchronize this method +* This method creates a new store if not exist. */ @Override public PagingStore getPageStore(final SimpleString storeName) throws Exception { if (managementAddress != null && storeName.startsWith(managementAddress)) { return null; } - PagingStore store = stores.get(storeName); - if (store != null) { - return store; + try { --- End diff -- ok got it. I've updated the branch. Please take a look again. thx. ---
[GitHub] activemq-artemis issue #2478: ARTEMIS-2210 PagingStore creation is not prope...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2478 @franz1981 I've update the branch, can you take a look? thx. ---
[GitHub] activemq-artemis issue #2478: ARTEMIS-2210 PagingStore creation is not prope...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2478 @franz1981 ok, make sense. I'll change it. thx. ---
[GitHub] activemq-artemis issue #2478: ARTEMIS-2210 PagingStore creation is not prope...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2478 @franz1981 Isn't that equivalent to a synchronize block? If so I think the sysnchronized block is simpler, do you think? ---
[GitHub] activemq-artemis issue #2478: ARTEMIS-2210 PagingStore creation is not prope...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2478 The fix is so obvious that I decide not to provide a test. :) ---
[GitHub] activemq-artemis pull request #2478: ARTEMIS-2210 PagingStore creation is no...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2478 ARTEMIS-2210 PagingStore creation is not properly synchronized In PagingManagerImpl#getPageStore() the operations on the map 'stores' are not synchronzed and it's possible that more than one paging store is created for one address. You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis a_2210 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2478.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 #2478 commit dfa70680fed37d25aa3a6d0d6a0795e580495b6a Author: Howard Gao Date: 2018-12-24T02:42:18Z ARTEMIS-2210 PagingStore creation is not properly synchronized In PagingManagerImpl#getPageStore() the operations on the map 'stores' are not synchronzed and it's possible that more than one paging store is created for one address. ---
[GitHub] activemq-artemis pull request #2473: ARTEMIS-1058 Jars in web tmp dir locked...
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/2473#discussion_r243139995 --- Diff: artemis-web/src/main/java/org/apache/activemq/artemis/component/WebServerComponent.java --- @@ -237,28 +236,39 @@ public void start() throws Exception { public void internalStop() throws Exception { server.stop(); if (webContexts != null) { + File tmpdir = null; + StringBuilder strBuilder = new StringBuilder(); + boolean found = false; for (WebAppContext context : webContexts) { tmpdir = context.getTempDirectory(); -if (tmpdir != null && !context.isPersistTempDirectory()) { +if (tmpdir != null && tmpdir.exists() && !context.isPersistTempDirectory()) { //tmpdir will be removed by deleteOnExit() - //somehow when broker is stopped and restarted quickly - //this tmpdir won't get deleted sometimes - boolean fileDeleted = TimeUtils.waitOnBoolean(false, 5000, tmpdir::exists); - - if (!fileDeleted) { - //because the execution order of shutdown hooks are - //not determined, so it's possible that the deleteOnExit - //is executed after this hook, in that case we force a delete. - FileUtil.deleteDirectory(tmpdir); - logger.debug("Force to delete temporary file on shutdown: " + tmpdir.getAbsolutePath()); - if (tmpdir.exists()) { - ActiveMQWebLogger.LOGGER.tmpFileNotDeleted(tmpdir); - } + //However because the URLClassLoader never release/close its opened + //jars the jar file won't be able to get deleted on Windows platform + //until after the process fully terminated. To fix this here arranges + //a separate process to try clean up the temp dir + FileUtil.deleteDirectory(tmpdir); + if (tmpdir.exists()) { + ActiveMQWebLogger.LOGGER.tmpFileNotDeleted(tmpdir); + strBuilder.append(tmpdir); + strBuilder.append(","); + found = true; } } } + + if (found) { +String artemisHome = System.getProperty("artemis.home"); --- End diff -- This "artemis.home" property is not defined in configured in broker.xml file. It's only defined in artemis.profile and set to system property in artemis.cmd script (-Dartemis.home="$ARTEMIS_HOME") I can't get it from the other configurations. ---
[GitHub] activemq-artemis issue #2473: ARTEMIS-1058 Jars in web tmp dir locked on Win...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2473 Yes there is a issue opened. https://github.com/eclipse/jetty.project/issues/1425 that doesn't get fixed (PR didn't merged because the hacking into URLClassLoader brings concerns) So that's why i came up with this work around. (The issue still there with jetty latest releases). ---
[GitHub] activemq-artemis issue #2473: ARTEMIS-1058 Jars in web tmp dir locked on Win...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2473 manually tested on Windows 7 64bit and Windows 10 64bit. ---
[GitHub] activemq-artemis pull request #2473: ARTEMIS-1058 Jars in web tmp dir locked...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2473 ARTEMIS-1058 Jars in web tmp dir locked on Windows Because Sun's URLClassLoader never closes it's jar file handles Jetty doesn't cleanup is temp web dir after Artemis broker shut down normally on Windows. To work around this a new process is forked before broker VM exits to clean up the tmp dir if they are not deleted. The new process out lives the main VM so that those jar's handles are released and the temp dir can be cleaned up. You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis b_522 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2473.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 #2473 commit af27cc96555390ec63d35e9c157aa658bde60797 Author: Howard Gao Date: 2018-12-19T14:54:59Z ARTEMIS-1058 Jars in web tmp dir locked on Windows Because Sun's URLClassLoader never closes it's jar file handles Jetty doesn't cleanup is temp web dir after Artemis broker shut down normally on Windows. To work around this a new process is forked before broker VM exits to clean up the tmp dir if they are not deleted. The new process out lives the main VM so that those jar's handles are released and the temp dir can be cleaned up. ---
[GitHub] activemq-artemis pull request #2462: ARTEMIS-2197 Page deleted before transa...
Github user gaohoward closed the pull request at: https://github.com/apache/activemq-artemis/pull/2462 ---
[GitHub] activemq-artemis issue #2462: ARTEMIS-2197 Page deleted before transaction f...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2462 @clebertsuconic It's done. ---
[GitHub] activemq-artemis issue #2305: NO-JIRA - Page.write() should throw exception ...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2305 @jbertram Done. thx. ---
[GitHub] activemq-artemis issue #2462: ARTEMIS-2197 Page deleted before transaction f...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2462 ok, I'll make it separate commits. thx ---
[GitHub] activemq-artemis issue #2462: ARTEMIS-2197 Page deleted before transaction f...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2462 @clebertsuconic I've update the PR including the regression fix. ---
[GitHub] activemq-artemis issue #2463: ARTEMIS-2197 Page deleted before transaction f...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2463 @clebertsuconic Can you take a look? thx. ---
[GitHub] activemq-artemis pull request #2463: ARTEMIS-2197 Page deleted before transa...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2463 ARTEMIS-2197 Page deleted before transaction finishes Fixed regression caused by previous commit b36dc37c152cabe3a0d9af178db043f842bfcdc0 You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis a_e2011_regress Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2463.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 #2463 commit 2bd8fa7c5dcfb2c29a5c5f61ff433bf161b1b86e Author: Howard Gao Date: 2018-12-13T12:17:14Z ARTEMIS-2197 Page deleted before transaction finishes Fixed regression caused by previous commit b36dc37c152cabe3a0d9af178db043f842bfcdc0 ---
[GitHub] activemq-artemis pull request #2462: ARTEMIS-2197 Page deleted before transa...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2462 ARTEMIS-2197 Page deleted before transaction finishes When a receiving transaction is committed in a paging situation, if a page happens to be completed and it will be deleted in a transaction operation (PageCursorTx). The other tx operation RefsOperation needs to access the page (in PageCache) to finish its job. There is a chance that the PageCursorTx removes the page before RefsOperation and it will cause the RefsOperation failed to find a message in a page. (cherry picked from b36dc37c152cabe3a0d9af178db043f842bfcdc0) You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis a_26x_2100 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2462.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 #2462 commit 44a0487f8fdb503a8b1ed849b1d0c2e039c133b8 Author: Howard Gao Date: 2018-12-10T05:35:04Z ARTEMIS-2197 Page deleted before transaction finishes When a receiving transaction is committed in a paging situation, if a page happens to be completed and it will be deleted in a transaction operation (PageCursorTx). The other tx operation RefsOperation needs to access the page (in PageCache) to finish its job. There is a chance that the PageCursorTx removes the page before RefsOperation and it will cause the RefsOperation failed to find a message in a page. (cherry picked from b36dc37c152cabe3a0d9af178db043f842bfcdc0) ---
[GitHub] activemq-artemis issue #2455: ARTEMIS-2197 Page deleted before transaction f...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2455 @clebertsuconic Can you review this? thx. ---
[GitHub] activemq-artemis pull request #2455: ARTEMIS-2197 Page deleted before transa...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2455 ARTEMIS-2197 Page deleted before transaction finishes When a receiving transaction is committed in a paging situation, if a page happens to be completed and it will be deleted in a transaction operation (PageCursorTx). The other tx operation RefsOperation needs to access the page (in PageCache) to finish its job. There is a chance that the PageCursorTx removes the page before RefsOperation and it will cause the RefsOperation failed to find a message in a page. You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis a_e2011_2 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2455.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 #2455 commit 3ebd2e49e5945f305dc68e1be83218bbde3c7085 Author: Howard Gao Date: 2018-12-10T03:19:15Z ARTEMIS-2197 Page deleted before transaction finishes When a receiving transaction is committed in a paging situation, if a page happens to be completed and it will be deleted in a transaction operation (PageCursorTx). The other tx operation RefsOperation needs to access the page (in PageCache) to finish its job. There is a chance that the PageCursorTx removes the page before RefsOperation and it will cause the RefsOperation failed to find a message in a page. ---
[GitHub] activemq-artemis pull request #2430: ARTEMIS-2174 Broker reconnect cause OOM...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2430 ARTEMIS-2174 Broker reconnect cause OOM with scale down When a node tries to reconnects to another node in a scale down cluster, the reconnect request gets denied by the other node and keeps retrying, which causes tasks in the ordered executor accumulate and eventually OOM. The fix is to change the ActiveMQPacketHandler#handleCheckForFailover to allow reconnect if the scale down node is the node itself. You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis e_2174 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2430.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 #2430 commit 2a108ac8817cb6c2ca3b29092108a3e35e7f5690 Author: Howard Gao Date: 2018-11-14T11:21:48Z ARTEMIS-2174 Broker reconnect cause OOM with scale down When a node tries to reconnects to another node in a scale down cluster, the reconnect request gets denied by the other node and keeps retrying, which causes tasks in the ordered executor accumulate and eventually OOM. The fix is to change the ActiveMQPacketHandler#handleCheckForFailover to allow reconnect if the scale down node is the node itself. ---
[GitHub] activemq-artemis issue #2041: ARTEMIS-1825 Live-backup topology not correctl...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2041 np at all. ---
[GitHub] activemq-artemis issue #2041: ARTEMIS-1825 Live-backup topology not correctl...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2041 @michaelandrepearce Yes that's the idea. ---
[GitHub] activemq-artemis issue #2074: ARTEMIS-1850 QueueControl.listDeliveringMessag...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2074 @clebertsuconic Can you merge it? thx ---
[GitHub] activemq-artemis issue #2385: ARTEMIS-1929 race in STOMP identical durable s...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2385 I think it's good. ---
[GitHub] activemq-artemis pull request #2386: ARTEMIS-2135 Test multiple core consume...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2386 ARTEMIS-2135 Test multiple core consumers receiving amqp messages This test can verify an issue fixed by the commit: 48e0fc8f42346d96bc809593a150e05a586787ee (ARTEMIS-2135) (note the upstream fix is ARTEMIS-2096) You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis d_26x_2034fix2 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2386.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 #2386 commit 07355b1fa6f1d20a50f130df48dd8fe006932e54 Author: Howard Gao Date: 2018-10-19T13:40:33Z ARTEMIS-2135 Test multiple core consumers receiving amqp messages This test can verify an issue fixed by the commit: 48e0fc8f42346d96bc809593a150e05a586787ee (ARTEMIS-2135) (note the upstream fix is ARTEMIS-2096) ---
[GitHub] activemq-artemis issue #2383: ARTEMIS-2096 Adding a test
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2383 @clebertsuconic I'll send a PR to 2.6.x but not cherry-pick from this. Because on 2.6.x the fix is by a different commit not the one I mentioned here. ---
[GitHub] activemq-artemis issue #2383: ARTEMIS-2096 Adding a test
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2383 ok will do. ---
[GitHub] activemq-artemis issue #2383: NO-JIRA Adding a test for ARTEMIS-2096
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2383 agreed I'll remove the NO-JIRA. thx. ---
[GitHub] activemq-artemis pull request #2383: NO-JIRA Adding a test for ARTEMIS-2096
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2383 NO-JIRA Adding a test for ARTEMIS-2096 This test can verify an issue fixed by the commit: 7a463f038ae324f2c5c908321b2ebf03b5a8e303 (ARTEMIS-2096) The issue was reported in: https://issues.jboss.org/browse/ENTMQBR-2034 but not reported in Artemis. You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis c_2034 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2383.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 #2383 commit 89ef072d80d6d034be73244af05617b2bf3baf36 Author: Howard Gao Date: 2018-10-19T13:40:33Z NO-JIRA Adding a test for ARTEMIS-2096 This test can verify an issue fixed by the commit: 7a463f038ae324f2c5c908321b2ebf03b5a8e303 (ARTEMIS-2096) The issue was reported in: https://issues.jboss.org/browse/ENTMQBR-2034 but not reported in Artemis. ---
[GitHub] activemq-artemis pull request #2377: ARTEMIS-2133 Artemis tab not showing on...
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/2377#discussion_r226144345 --- Diff: artemis-hawtio/artemis-plugin/src/main/webapp/plugin/js/artemisPlugin.js --- @@ -362,7 +362,7 @@ var ARTEMIS = (function(ARTEMIS) { workspace.subLevelTabs = subLevelTabs; - preLogoutTasks.addTask("clearArtemisCredentials", () => { --- End diff -- surprisingly yes. :) ---
[GitHub] activemq-artemis pull request #2377: ARTEMIS-2133 Artemis tab not showing on...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2377 ARTEMIS-2133 Artemis tab not showing on IE browser The web console on IE doesn't have 'Artemis' showed up because it doesn't support javascripts => function. You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis a_web_ie Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2377.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 #2377 commit 7206326c64c7f74da8ae8b2921e784cdfe8b2a4a Author: Howard Gao Date: 2018-10-17T12:15:17Z ARTEMIS-2133 Artemis tab not showing on IE browser The web console on IE doesn't have 'Artemis' showed up because it doesn't support javascripts => function. ---
[GitHub] activemq-artemis pull request #2371: ARTEMIS-2097 Pause and Block Producers
Github user gaohoward closed the pull request at: https://github.com/apache/activemq-artemis/pull/2371 ---
[GitHub] activemq-artemis issue #2371: ARTEMIS-2097 Pause and Block Producers
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2371 closing it for now, it needs more discussion. ---
[GitHub] activemq-artemis pull request #2371: ARTEMIS-2097 Pause and Block Producers
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/2371#discussion_r225383942 --- Diff: artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerSessionImpl.java --- @@ -1789,6 +1790,11 @@ public synchronized RoutingStatus doSend(final Transaction tx, AddressInfo art = getAddressAndRoutingType(new AddressInfo(msg.getAddressSimpleString(), routingType)); + if (postOffice.isAddressBlocked(msg.getAddressSimpleString())) { --- End diff -- You mean a formal discussion? I'll send an email for that purpose. I think it not too late. :) ---
[GitHub] activemq-artemis pull request #2371: ARTEMIS-2097 Pause and Block Producers
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/2371#discussion_r225353248 --- Diff: artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerSessionImpl.java --- @@ -1789,6 +1790,11 @@ public synchronized RoutingStatus doSend(final Transaction tx, AddressInfo art = getAddressAndRoutingType(new AddressInfo(msg.getAddressSimpleString(), routingType)); + if (postOffice.isAddressBlocked(msg.getAddressSimpleString())) { --- End diff -- btw my test missed stomp and mqtt, I'll add them. ---
[GitHub] activemq-artemis pull request #2371: ARTEMIS-2097 Pause and Block Producers
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/2371#discussion_r225353155 --- Diff: artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerSessionImpl.java --- @@ -1789,6 +1790,11 @@ public synchronized RoutingStatus doSend(final Transaction tx, AddressInfo art = getAddressAndRoutingType(new AddressInfo(msg.getAddressSimpleString(), routingType)); + if (postOffice.isAddressBlocked(msg.getAddressSimpleString())) { --- End diff -- @clebertsuconic reply here. I can think of 2 difficulties using credits: 1. Some clients (like mqtt, stomp) are not supporting flow control so they can't be blocked using credits. 2. producers are not necessarily bound to one address, they can send messages to different addresses (for example one producer can send one message to address1, and the next one to address2. It it's blocked on address1, the next message also be blocked) If we simply block the sending threads, it will holding up broker threads (like you said OME). Besides the producer may have call-timeout exception. By throwing a proper exception we can let client to handle their producer properly without blocking any thing. ---
[GitHub] activemq-artemis pull request #2371: ARTEMIS-2097 Pause and Block Producers
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/2371#discussion_r225143852 --- Diff: artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQAddressBlockedException.java --- @@ -0,0 +1,24 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.activemq.artemis.api.core; + +public class ActiveMQAddressBlockedException extends ActiveMQException { + + public ActiveMQAddressBlockedException(String address) { --- End diff -- Yes that makes sense. We don't need the stacktrace here. I'll add that. thx. ---
[GitHub] activemq-artemis pull request #2371: ARTEMIS-2097 Pause and Block Producers
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2371 ARTEMIS-2097 Pause and Block Producers Added new methods to AddressControl and ServerControl to allow users to block sending on addresses. Once blocked, any messages sending to the blocked addresses will get rejected with an exception. The senders can catch the corresponding exception and handle properly. For example, keep resending or send messages to some alternative addresses. You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis a_2097 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2371.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 #2371 commit 056e09b036ffe4eb0022328a837cfa8ec7c28203 Author: Howard Gao Date: 2018-10-15T08:10:31Z ARTEMIS-2097 Pause and Block Producers Added new methods to AddressControl and ServerControl to allow users to block sending on addresses. Once blocked, any messages sending to the blocked addresses will get rejected with an exception. The senders can catch the corresponding exception and handle properly. For example, keep resending or send messages to some alternative addresses. ---
[GitHub] activemq-artemis issue #2305: NO-JIRA - Page.write() should throw exception ...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2305 https://issues.apache.org/jira/browse/ARTEMIS-2088 ---
[GitHub] activemq-artemis issue #2305: NO-JIRA - Page.write() should throw exception ...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2305 @clebertsuconic I've added more details to the commit comment. ---
[GitHub] activemq-artemis pull request #2305: NO-JIRA - Page.write() should throw exc...
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/2305#discussion_r217584046 --- Diff: artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/impl/Page.java --- @@ -223,7 +224,7 @@ private int read(StorageManager storage, ActiveMQBuffer fileBuffer, List
[GitHub] activemq-artemis pull request #2305: NO-JIRA - Page.write() should throw exc...
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/2305#discussion_r217426008 --- Diff: artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/impl/Page.java --- @@ -223,7 +223,7 @@ private int read(StorageManager storage, ActiveMQBuffer fileBuffer, List
[GitHub] activemq-artemis pull request #2305: NO-JIRA - Page.write() should throw exc...
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/2305#discussion_r217242750 --- Diff: artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/impl/Page.java --- @@ -223,7 +223,7 @@ private int read(StorageManager storage, ActiveMQBuffer fileBuffer, Listhttps://github.com/hornetq/hornetq/pull/2122 (long forgotten by me. But as the pr noted that this causes random failure in PagingTest#testExpireLargeMessageOnPaging()). ---
[GitHub] activemq-artemis pull request #2305: NO-JIRA - Page.write() should throw exc...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2305 NO-JIRA - Page.write() should throw exception if file is closed In Page.write(final PagedMessage message) if the page file is closed it returns silently. The caller has no way to know that if the message is paged to file or not. It should throw an exception so that the caller can handle it correctly. You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis a_page_write Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2305.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 #2305 commit 2bf2a3918a89c24f68de00a2dcc4630bf9b03409 Author: Howard Gao Date: 2018-09-12T03:11:02Z NO-JIRA - Page.write() should throw exception if file is closed In Page.write(final PagedMessage message) if the page file is closed it returns silently. The caller has no way to know that if the message is paged to file or not. It should throw an exception so that the caller can handle it correctly. ---
[GitHub] activemq-artemis pull request #2219: ARTEMIS-2013 Can't create durable subsc...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2219 ARTEMIS-2013 Can't create durable subscriber to a composite topic An OpenWire client can use a compound destination name of the form "a,b,c..." and consume from, or subscribe to, multiple destinations. Such a compound destination only works for topics when the subscriber is non-durable. Attempting to create a durable subscription on a compound address will end up with an error. The cause is when creating durable subs to multiple topics/addresses the broker uses the same name to create internal queues, which causes duplicate name conflict. You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis b_ent1823 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2219.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 #2219 commit e7cfa99bd8d924b9f4bbb251ca8287a4b2067248 Author: Howard Gao Date: 2018-08-07T08:56:43Z ARTEMIS-2013 Can't create durable subscriber to a composite topic An OpenWire client can use a compound destination name of the form "a,b,c..." and consume from, or subscribe to, multiple destinations. Such a compound destination only works for topics when the subscriber is non-durable. Attempting to create a durable subscription on a compound address will end up with an error. The cause is when creating durable subs to multiple topics/addresses the broker uses the same name to create internal queues, which causes duplicate name conflict. ---
[GitHub] activemq-artemis issue #2205: ARTEMIS-1995 Client fail over fails when live ...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2205 ah sorry about that. I'm closing it. ---
[GitHub] activemq-artemis pull request #2205: ARTEMIS-1995 Client fail over fails whe...
Github user gaohoward closed the pull request at: https://github.com/apache/activemq-artemis/pull/2205 ---
[GitHub] activemq-artemis issue #1950: ARTEMIS-1732 AMQP anonymous producer not block...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/1950 I think it's ok. ---
[GitHub] activemq-artemis issue #2205: ARTEMIS-1995 Client fail over fails when live ...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2205 I think the ci build test failures relates to environment. All passes on my local machine. ---
[GitHub] activemq-artemis pull request #2205: ARTEMIS-1995 Client fail over fails whe...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2205 ARTEMIS-1995 Client fail over fails when live shut down too soon In a live-backup scenario, if the live is restarted and shutdown too soon, the client have a chance to fail on failover because it's internal topology is inconsistent with the final status. The client keeps connecting to live already shut down, never trying to connect to the backup. It's a porting from HORNETQ-1572. (Cherry-picked from master) You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis c_2.6.x_1995 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2205.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 #2205 commit 2bb35e5dac05aeee3196b4457fbdd1214a214dd1 Author: Howard Gao Date: 2018-07-30T06:48:09Z ARTEMIS-1995 Client fail over fails when live shut down too soon In a live-backup scenario, if the live is restarted and shutdown too soon, the client have a chance to fail on failover because it's internal topology is inconsistent with the final status. The client keeps connecting to live already shut down, never trying to connect to the backup. It's a porting from HORNETQ-1572. (Cherry-picked from master) ---
[GitHub] activemq-artemis pull request #2197: ARTEMIS-1995 Client fail over fails whe...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2197 ARTEMIS-1995 Client fail over fails when live shut down too soon In a live-backup scenario, if the live is restarted and shutdown too soon, the client have a chance to fail on failover because it's internal topology is inconsistent with the final status. The client keeps connecting to live already shut down, never trying to connect to the backup. It's a porting from HORNETQ-1572 You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis b_fix_ge_1 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2197.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 #2197 commit ed6f6eedbce3d84180c086392bf35d675b22446b Author: Howard Gao Date: 2018-07-30T06:48:09Z ARTEMIS-1995 Client fail over fails when live shut down too soon In a live-backup scenario, if the live is restarted and shutdown too soon, the client have a chance to fail on failover because it's internal topology is inconsistent with the final status. The client keeps connecting to live already shut down, never trying to connect to the backup. It's a porting from HORNETQ-1572 ---
[GitHub] activemq-artemis issue #2128: ARTEMIS-1916 Remove Jmx ArtemisRMIServerSocket...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2128 Closing this PR as it's a non issue. ---
[GitHub] activemq-artemis pull request #2128: ARTEMIS-1916 Remove Jmx ArtemisRMIServe...
Github user gaohoward closed the pull request at: https://github.com/apache/activemq-artemis/pull/2128 ---
[GitHub] activemq-artemis issue #2122: ARTEMIS-1904 Jmx Management Security Tests
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2122 @mtaylor I've added some ssl test. ---
[GitHub] activemq-artemis issue #2122: ARTEMIS-1904 Jmx Management Security Tests
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2122 @mtaylor worked with Andy and figured out ARTEMIS-1916 is not valid (PR will be discarded). I've fixed the test and it should be ready for review now. ---
[GitHub] activemq-artemis issue #2128: ARTEMIS-1916 Remove Jmx ArtemisRMIServerSocket...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2128 @clebertsuconic I split it because Martyn suggested that this doesn't belong to a test PR. (see Martyn's comment) ---
[GitHub] activemq-artemis issue #2122: ARTEMIS-1904 Jmx Management Security Tests
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2122 @mtaylor I've created another jira (ARTEMIS-1916) and the PR https://github.com/apache/activemq-artemis/pull/2128 I also updated this PR. This PR should be merged after ARTEMIS-1916 (otherwise the test is failing). ---
[GitHub] activemq-artemis pull request #2128: ARTEMIS-1916 Remove Jmx ArtemisRMIServe...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2128 ARTEMIS-1916 Remove Jmx ArtemisRMIServerSocketFactory The ArtemisRMIServerSocketFactory doesn't do anything special, instead the existence of this impl class causes jmx client failed to connect (for reason not known, probably not fully implemented the functionality). It turns out just fine to use JDK's impl. This class is not necessary. You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis b_artemis1916 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2128.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 #2128 commit 7d7c6ae193dcfd91bb5a4bd3e0de8542010554fd Author: Howard Gao Date: 2018-06-07T15:29:29Z ARTEMIS-1916 Remove Jmx ArtemisRMIServerSocketFactory The ArtemisRMIServerSocketFactory doesn't do anything special, instead the existence of this impl class causes jmx client failed to connect (for reason not known, probably not fully implemented the functionality). It turns out just fine to use JDK's impl. This class is not necessary. ---
[GitHub] activemq-artemis issue #2122: ARTEMIS-1904 Jmx Management Security Tests
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2122 @mtaylor ok, will do another jira. The code change is to remove the RMIServerSocketFactory because it does nothing special and it causes jmx client fail to connect (don't know why, perhaps we didn't implement it right). ---
[GitHub] activemq-artemis pull request #2122: ARTEMIS-1904 Jmx Management Security Te...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2122 ARTEMIS-1904 Jmx Management Security Tests * Added tests for jmx security * Removed ArtemisRMIServerSocketFactory as it does nothing special (instead use default factory from jdk) You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis a_jmx Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2122.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 #2122 commit 95ecb071f08dcb8b406c2600d3c635047e415b20 Author: Howard Gao Date: 2018-06-05T06:13:30Z ARTEMIS-1904 Jmx Management Security Tests * Added tests for jmx security * Removed ArtemisRMIServerSocketFactory as it does nothing special (instead use default factory from jdk) ---
[GitHub] activemq-artemis pull request #2101: ARTEMIS-1853 Adding Netty OpenSSL provi...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2101 ARTEMIS-1853 Adding Netty OpenSSL provider test Added an example to demonstrate how to configure and use openssl Moved/Added netty-tcnative dependency to artemis-distribution Changed artemis-jms-client-all pom to exclude io.netty from relocation so that the native openssl can be loaded You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis d_openssl_example Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2101.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 #2101 ---
[GitHub] activemq-artemis pull request #2092: ARTEMIS-1853 Adding Netty OpenSSL provi...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2092 ARTEMIS-1853 Adding Netty OpenSSL provider test Added some netty openssl tests Fix a NPE issue You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis g_openssl2 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2092.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 #2092 commit 246e32d0a1854ce40cabb8e2b3b38344ab532ad6 Author: Howard Gao Date: 2018-05-17T22:50:37Z ARTEMIS-1853 Adding Netty OpenSSL provider test Added some netty openssl tests Fix a NPE issue ---
[GitHub] activemq-artemis pull request #2090: ARTEMIS-1868 Openwire doesn't add deliv...
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/2090#discussion_r188604772 --- Diff: artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/amq/AMQSession.java --- @@ -308,6 +312,8 @@ public int sendMessage(MessageReference reference, ServerConsumer consumer, int deliveryCount) { AMQConsumer theConsumer = (AMQConsumer) consumer.getProtocolData(); + //clear up possible rolledback ids. + rollbackedIds.remove(message.getMessageID()); --- End diff -- Yes I know this adds some costs. But so far I couldn't have a better solution. ---
[GitHub] activemq-artemis pull request #2090: ARTEMIS-1868 Openwire doesn't add deliv...
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/2090#discussion_r188604794 --- Diff: artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/amq/AMQSession.java --- @@ -95,6 +97,8 @@ private final SimpleString clientId; + private final Set rollbackedIds = new ConcurrentHashSet<>(); --- End diff -- This I can do. Thanks! ---
[GitHub] activemq-artemis pull request #2090: ARTEMIS-1868 Openwire doesn't add deliv...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2090 ARTEMIS-1868 Openwire doesn't add delivery count in client ack mode If a client ack mode consumer receives a message and closes without acking it, the redelivery of the message won't set the redelivery flag (JMSRedelivered) because it doesn't increment the delivery count when message is cancelled back to queue. You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis b_ent1497 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2090.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 #2090 commit e0af1e56d9dd8051bcd6b3f1316b00f201afe5e9 Author: Howard Gao Date: 2018-05-16T03:14:48Z ARTEMIS-1868 Openwire doesn't add delivery count in client ack mode If a client ack mode consumer receives a message and closes without acking it, the redelivery of the message won't set the redelivery flag (JMSRedelivered) because it doesn't increment the delivery count when message is cancelled back to queue. ---
[GitHub] activemq-artemis issue #2074: ARTEMIS-1850 QueueControl.listDeliveringMessag...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2074 ok. btw I ran it within intellij it passes. ---
[GitHub] activemq-artemis pull request #2074: ARTEMIS-1850 QueueControl.listDeliverin...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2074 ARTEMIS-1850 QueueControl.listDeliveringMessages returns empty result With AMQP protocol when some messages are received in a transaction, calling JMX QueueControl.listDeliveringMessages() returns empty list before the transaction is committed. You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis i_1850 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2074.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 #2074 commit 4d804a1d7cb3bb25b6ab160a2a5cd7f636f1c4b3 Author: Howard Gao Date: 2018-05-07T06:33:16Z ARTEMIS-1850 QueueControl.listDeliveringMessages returns empty result With AMQP protocol when some messages are received in a transaction, calling JMX QueueControl.listDeliveringMessages() returns empty list before the transaction is committed. ---
[GitHub] activemq-artemis pull request #2049: NO-JIRA: Added a AMQP JMS LargeMessage ...
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/2049#discussion_r184700517 --- Diff: tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/amqp/JMSDurableConsumerTest.java --- @@ -221,4 +224,66 @@ public void testDurableConsumerUnsubscribeWhileActive() throws Exception { connection.close(); } } + + @Test(timeout = 3) + public void testDurableConsumerLarge() throws Exception { + String durableClientId = getTopicName() + "-ClientId"; + + Connection connection = createConnection(durableClientId); + try { + Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE); + Topic topic = session.createTopic(getTopicName()); + final MessageConsumer consumer1 = session.createDurableSubscriber(topic, "DurbaleSub1"); + final MessageConsumer consumer2 = session.createDurableSubscriber(topic, "DurbaleSub2"); + MessageProducer producer = session.createProducer(topic); + producer.setDeliveryMode(DeliveryMode.PERSISTENT); + connection.start(); + + ObjectMessage objMessage = session.createObjectMessage(); + BigObject bigObject = new BigObject(ActiveMQClient.DEFAULT_MIN_LARGE_MESSAGE_SIZE); + objMessage.setObject(bigObject); + producer.send(objMessage); + + final AtomicReference msg1 = new AtomicReference<>(); + final AtomicReference msg2 = new AtomicReference<>(); + + assertTrue(Wait.waitFor(new Wait.Condition() { + +@Override +public boolean isSatisfied() throws Exception { + msg1.set(consumer1.receiveNoWait()); + return msg1.get() != null; +} + }, TimeUnit.SECONDS.toMillis(25), TimeUnit.MILLISECONDS.toMillis(200))); --- End diff -- Thanks, I just copy/modify from other test and didn't think much of it. :) ---
[GitHub] activemq-artemis pull request #2049: NO-JIRA: Added a AMQP JMS LargeMessage ...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2049 NO-JIRA: Added a AMQP JMS LargeMessage test You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis f_1461 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2049.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 #2049 commit 7ba4f75feeaf6c01e8a2ae7db63553741ab36960 Author: Howard Gao Date: 2018-04-27T12:22:28Z NO-JIRA: Added a AMQP JMS LargeMessage test ---
[GitHub] activemq-artemis issue #2041: ARTEMIS-1825 Live-backup topology not correctl...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2041 @clebertsuconic removed the debug logs. ---
[GitHub] activemq-artemis issue #2041: ARTEMIS-1825 Live-backup topology not correctl...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2041 @clebertsuconic done. ---
[GitHub] activemq-artemis pull request #2041: ARTEMIS-1825 Live-backup topology not c...
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/2041#discussion_r184259404 --- Diff: artemis-hawtio/artemis-plugin/src/main/webapp/plugin/js/brokerDiagram.js --- @@ -455,16 +457,27 @@ var ARTEMIS = (function(ARTEMIS) { addLinkIds("broker:" + broker.brokerId, "broker:" + "\"" + remoteBroker.live + "\"", "network"); var backup = remoteBroker.backup; + ARTEMIS.log.info("isbackup? " + backup); if (backup) { getOrAddBroker(false, "\"" + backup + "\"", remoteBroker.nodeID, "remote", null, properties); addLinkIds("broker:" + "\"" + remoteBroker.live + "\"", "broker:" + "\"" + backup + "\"", "network"); } } else { - var backup = remoteBroker.backup; - if (backup) { - getOrAddBroker(false, "\"" + remoteBroker.backup + "\"", remoteBroker.nodeID, "remote", null, properties); - addLinkIds("broker:" + broker.brokerId, "broker:" + "\"" + remoteBroker.backup + "\"", "network"); + var newBackReq = ARTEMISService.artemisConsole.isBackup(jolokia, mBean); + var newBackup = newBackReq.value; + if (!newBackup) { + ARTEMIS.log.info("yes I'm master right now"); + if (remoteBroker.backup) { +getOrAddBroker(false, "\"" + remoteBroker.backup + "\"", remoteBroker.nodeID, "remote", null, properties); +addLinkIds("broker:" + broker.brokerId, "broker:" + "\"" + remoteBroker.backup + "\"", "network"); + } + } + else { + ARTEMIS.log.info("ok I'm backup!"); --- End diff -- Yes should be debug. I'll change that. Thx. ---
[GitHub] activemq-artemis pull request #2041: ARTEMIS-1825 Live-backup topology not c...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2041 ARTEMIS-1825 Live-backup topology not correctly displayed on console You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis h1825 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2041.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 #2041 commit 82241555d48ece29a76b6b48da8921225e747d87 Author: Howard Gao Date: 2018-04-24T04:08:33Z ARTEMIS-1825 Live-backup topology not correctly displayed on console ---
[GitHub] activemq-artemis issue #2013: ARTEMIS-1805 fix for broker operations in hawt...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2013 @stanlyDoge you got to remove @Override annotations from ActiveMQServerControlImpl also. ---
[GitHub] activemq-artemis issue #2020: ARTEMIS-1812 fix for missing (core) messages a...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2020 @stanlyDoge I think that may be fixed somewhere else probably? can you provide your test? ---
[GitHub] activemq-artemis issue #1988: ARTEMIS-1782 fix for displaying hawtio console...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/1988 @stanlyDoge @clebertsuconic I think for the moment we can stay with the current version of hawtio. I'll bring your fix in. ---
[GitHub] activemq-artemis issue #2004: ARTEMIS-1793 fix 'destination-type' STOMP head...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2004 +1. The failed tests seems not relevant. Maybe a forced re-run would solve this problem? ---
[GitHub] activemq-artemis issue #2013: ARTEMIS-1805 fix for broker operations in hawt...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2013 @stanlyDoge I didn't see that the two methods (sendQueueInfo.. and updateDuplicate...) in ActiveMQServerControl are used anywhere. Could simple deleting them from the interface solve the hawtio error? ---
[GitHub] activemq-artemis issue #2023: ARTEMIS-857 Add JMX endpoints to view and rese...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2023 @michaelandrepearce The code is fine I think. It'll be nice you add some unittests (e.g. in QueueControlTest) to verify it works. Also I find that the "Group" in method names a bit confusing. Would be using MessageGoup instead more clear? I'm not sure about that as I'm not a native speaker, just a personal opinion. ---
[GitHub] activemq-artemis pull request #2021: NO-JIRA: Fix test regression
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2021 NO-JIRA: Fix test regression QuorumFailOverTest.testQuorumVotingLiveNotDead fails because the quorum vote takes longer time to finish than the test expects to. (The test used to pass until commit ARTEMIS-1763) You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis h_fix_regress Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2021.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 #2021 commit 64f974ff52470553de8520ec7b374a78494d861e Author: Howard Gao Date: 2018-04-16T14:02:32Z NO-JIRA: Fix test regression QuorumFailOverTest.testQuorumVotingLiveNotDead fails because the quorum vote takes longer time to finish than the test expects to. (The test used to pass until commit ARTEMIS-1763) ---
[GitHub] activemq-artemis issue #2015: ARTEMIS-1807 File-based Large Message encoding...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/2015 I think using mapped file will get better performance over the NIO channel read. It would be better to have a unit test with it. @clebertsuconic wdyt? ---
[GitHub] activemq-artemis issue #1999: ARTEMIS-1790 Improve Topology Member Finding
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/1999 @clebertsuconic @stanlyDoge done. ---
[GitHub] activemq-artemis issue #1999: ARTEMIS-1790 Improve Topology Member Finding
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/1999 ok I'll take care of them. ---
[GitHub] activemq-artemis pull request #1999: ARTEMIS-1790 Improve Topology Member Fi...
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/1999#discussion_r180614044 --- Diff: artemis-core-client/src/main/java/org/apache/activemq/artemis/core/remoting/impl/netty/NettyConnection.java --- @@ -511,6 +511,45 @@ public final boolean isUsingProtocolHandling() { return true; } + @Override + public boolean isSameTarget(TransportConfiguration... configs) { + boolean yes = false; --- End diff -- alright. :) ---
[GitHub] activemq-artemis pull request #2005: ARTEMIS-1797 Auto-create-address flag s...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2005 ARTEMIS-1797 Auto-create-address flag shouldn't block temp destination creation When creating a temp destination and auto-create-address set to false, the broker throws an error and refuse to create it. This doesn't conform to normal use-case (like amqp dynamic flag) where the temp destination should be allowed even if the auto-create-address is false. You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis g_1158 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2005.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 #2005 commit 39a4e04aa11f22e672f4fe6f8ce87c436f9ddc8f Author: Howard Gao Date: 2018-04-10T07:26:27Z ARTEMIS-1797 Auto-create-address flag shouldn't block temp destination creation When creating a temp destination and auto-create-address set to false, the broker throws an error and refuse to create it. This doesn't conform to normal use-case (like amqp dynamic flag) where the temp destination should be allowed even if the auto-create-address is false. ---
[GitHub] activemq-artemis pull request #1999: ARTEMIS-1790 Improve Topology Member Fi...
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/1999#discussion_r180281379 --- Diff: artemis-core-client/src/main/java/org/apache/activemq/artemis/core/client/impl/TopologyMemberImpl.java --- @@ -105,12 +105,16 @@ public void setUniqueEventID(final long uniqueEventID) { return connector; } + /** +* We only need to check if the connection point to the same node, +* don't need to compare the whole params map. +* @param connection The connection to the target node +* @return true if the connection point to the same node +* as this member represents. +*/ @Override public boolean isMember(RemotingConnection connection) { - TransportConfiguration connectorConfig = connection.getTransportConnection() != null ? connection.getTransportConnection().getConnectorConfig() : null; - - return isMember(connectorConfig); - + return connection.isSameTarget(getConnector().getA(), getConnector().getB()); --- End diff -- @clebertsuconic Thanks! ---
[GitHub] activemq-artemis pull request #1999: ARTEMIS-1790 Improve Topology Member Fi...
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/1999#discussion_r180279022 --- Diff: artemis-core-client/src/main/java/org/apache/activemq/artemis/core/client/impl/TopologyMemberImpl.java --- @@ -105,12 +105,16 @@ public void setUniqueEventID(final long uniqueEventID) { return connector; } + /** +* We only need to check if the connection point to the same node, +* don't need to compare the whole params map. +* @param connection The connection to the target node +* @return true if the connection point to the same node +* as this member represents. +*/ @Override public boolean isMember(RemotingConnection connection) { - TransportConfiguration connectorConfig = connection.getTransportConnection() != null ? connection.getTransportConnection().getConnectorConfig() : null; - - return isMember(connectorConfig); - + return connection.isSameTarget(getConnector().getA(), getConnector().getB()); --- End diff -- ok, I'll fix the isMember() and put some context. ---
[GitHub] activemq-artemis pull request #1999: ARTEMIS-1790 Improve Topology Member Fi...
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/1999#discussion_r180155663 --- Diff: artemis-core-client/src/main/java/org/apache/activemq/artemis/core/client/impl/TopologyMemberImpl.java --- @@ -105,12 +105,16 @@ public void setUniqueEventID(final long uniqueEventID) { return connector; } + /** +* We only need to check if the connection point to the same node, +* don't need to compare the whole params map. +* @param connection The connection to the target node +* @return true if the connection point to the same node +* as this member represents. +*/ @Override public boolean isMember(RemotingConnection connection) { - TransportConfiguration connectorConfig = connection.getTransportConnection() != null ? connection.getTransportConnection().getConnectorConfig() : null; - - return isMember(connectorConfig); - + return connection.isSameTarget(getConnector().getA(), getConnector().getB()); --- End diff -- The issue here: https://issues.jboss.org/browse/JBEAP-14165 the issue is that the broker thinks 127.0.0.1 and localhost are different hosts when checking isMemeber(), where it just compare the configuration parameter map. ---
[GitHub] activemq-artemis pull request #2000: ARTEMIS-1791 Large message files are no...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/2000 ARTEMIS-1791 Large message files are not removed after redistribution across a cluster You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis f_lm_leak Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/2000.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 #2000 commit 1c8e2c4ff303abbdd855343409f0649901f9aee7 Author: Howard Gao Date: 2018-04-09T03:07:49Z ARTEMIS-1791 Large message files are not removed after redistribution across a cluster commit 27ca56a159072803903b79d37dc945313decb4c5 Author: Ingo Weiss Date: 2018-04-09T06:46:15Z [ARTEMIS-1791] Large message files are not removed after redistribution across a cluster Issue: https://issues.apache.org/jira/browse/ARTEMIS-1791 Adding test ---
[GitHub] activemq-artemis pull request #1999: ARTEMIS-1790 Improve Topology Member Fi...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/1999 ARTEMIS-1790 Improve Topology Member Finding When finding out if a connector belong to a target node it compares the whole parameter map which is not necessary. Also in understanding the connector the best place is to delegate it to the corresponding remoting connection who understands it. (e.g. INVMConnection knows whether the connector belongs to a target node by checking it's serverID only. The netty ones only need to match host and port, and understanding that localhost and 127.0.0.1 are same thing). You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis h_a1790 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/1999.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 #1999 commit f68d994f3124f5b533df53d70aa7495a83085b41 Author: Howard Gao Date: 2018-03-27T04:38:08Z ARTEMIS-1790 Improve Topology Member Finding When finding out if a connector belong to a target node it compares the whole parameter map which is not necessary. Also in understanding the connector the best place is to delegate it to the corresponding remoting connection who understands it. (e.g. INVMConnection knows whether the connector belongs to a target node by checking it's serverID only. The netty ones only need to match host and port, and understanding that localhost and 127.0.0.1 are same thing). ---
[GitHub] activemq-artemis pull request #1984: ARTEMIS-1779 ClusterConnectionBridge ma...
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/1984#discussion_r178819137 --- Diff: artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/impl/ClusterConnectionBridge.java --- @@ -127,9 +126,6 @@ public ClusterConnectionBridge(final ClusterConnection clusterConnection, this.managementNotificationAddress = managementNotificationAddress; this.flowRecord = flowRecord; - // we need to disable DLQ check on the clustered bridges - queue.setInternalQueue(true); --- End diff -- Thanks! ---
[GitHub] activemq-artemis pull request #1984: ARTEMIS-1779 ClusterConnectionBridge ma...
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/1984#discussion_r178696366 --- Diff: artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/impl/ClusterConnectionBridge.java --- @@ -127,9 +126,6 @@ public ClusterConnectionBridge(final ClusterConnection clusterConnection, this.managementNotificationAddress = managementNotificationAddress; this.flowRecord = flowRecord; - // we need to disable DLQ check on the clustered bridges - queue.setInternalQueue(true); --- End diff -- @clebertsuconic no it doesn't. But it's redundant because this has already been set during the creation of cluster connection bridge. See org.apache.activemq.artemis.core.server.cluster.impl.ClusterConnectionImpl#nodeUP() ---
[GitHub] activemq-artemis pull request #1984: ARTEMIS-1779 ClusterConnectionBridge ma...
GitHub user gaohoward opened a pull request: https://github.com/apache/activemq-artemis/pull/1984 ARTEMIS-1779 ClusterConnectionBridge may connect to other nodes than its target The cluster connection bridge has a TopologyListener and connects to a new node each time it receives a nodeUp() event. It needs to put a check here to make sure that the cluster bridge only connects to its target node and it's backups. This issue shows up when you run LiveToLiveFailoverTest.testConsumerTransacted test. Also in this commit improvement of BackupSyncJournalTest so that it runs more stable. You can merge this pull request into a Git repository by running: $ git pull https://github.com/gaohoward/activemq-artemis f_a1779 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/1984.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 #1984 commit 5ea8eba8ed7445f010e996ea528d5f7f66e2fd0d Author: Howard Gao Date: 2018-04-02T11:16:30Z ARTEMIS-1779 ClusterConnectionBridge may connect to other nodes than its target The cluster connection bridge has a TopologyListener and connects to a new node each time it receives a nodeUp() event. It needs to put a check here to make sure that the cluster bridge only connects to its target node and it's backups. This issue shows up when you run LiveToLiveFailoverTest.testConsumerTransacted test. Also in this commit improvement of BackupSyncJournalTest so that it runs more stable. ---
[GitHub] activemq-artemis issue #1960: ARTEMIS-406 STOMP acknowledgements should supp...
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/1960 @clebertsuconic sorry I forgot it. ---
[GitHub] activemq-artemis pull request #1960: ARTEMIS-406 STOMP acknowledgements shou...
Github user gaohoward closed the pull request at: https://github.com/apache/activemq-artemis/pull/1960 ---
[GitHub] activemq-artemis pull request #1965: NO-JIRA Fixing Stomp large message test...
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/1965#discussion_r176415286 --- Diff: artemis-protocols/artemis-stomp-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/stomp/StompSession.java --- @@ -154,12 +154,16 @@ public int sendMessage(MessageReference ref, encoder.encode(buffer, bodySize); encoder.close(); } else { -buffer = coreMessage.getReadOnlyBodyBuffer(); +if (Boolean.TRUE.equals(serverMessage.getBooleanProperty(Message.HDR_LARGE_COMPRESSED))) { + buffer = coreMessage.getBodyBuffer(); --- End diff -- @clebertsuconic Thanks! ---
[GitHub] activemq-artemis pull request #1965: NO-JIRA Fixing Stomp large message test...
Github user gaohoward commented on a diff in the pull request: https://github.com/apache/activemq-artemis/pull/1965#discussion_r176306425 --- Diff: artemis-protocols/artemis-stomp-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/stomp/StompSession.java --- @@ -154,12 +154,16 @@ public int sendMessage(MessageReference ref, encoder.encode(buffer, bodySize); encoder.close(); } else { -buffer = coreMessage.getReadOnlyBodyBuffer(); +if (Boolean.TRUE.equals(serverMessage.getBooleanProperty(Message.HDR_LARGE_COMPRESSED))) { + buffer = coreMessage.getBodyBuffer(); --- End diff -- @clebertsuconic Here I use body buffer instead of readonly bodybuffer, as I need to decompress the buffer and write into the message before delivering (like in large message case). Don't know how to do it a better way? ---
[GitHub] activemq-artemis issue #1965: NO-JIRA Fixing Stomp large message tests
Github user gaohoward commented on the issue: https://github.com/apache/activemq-artemis/pull/1965 please do not merge. We need discussion. ---