You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by cl...@apache.org on 2017/07/11 18:55:32 UTC
[1/2] activemq-artemis git commit: ARTEMIS-1280 Avoiding leak on
Queue futures
Repository: activemq-artemis
Updated Branches:
refs/heads/1.x 311072b28 -> e9b7b94de
ARTEMIS-1280 Avoiding leak on Queue futures
Project: http://git-wip-us.apache.org/repos/asf/activemq-artemis/repo
Commit: http://git-wip-us.apache.org/repos/asf/activemq-artemis/commit/8326a24f
Tree: http://git-wip-us.apache.org/repos/asf/activemq-artemis/tree/8326a24f
Diff: http://git-wip-us.apache.org/repos/asf/activemq-artemis/diff/8326a24f
Branch: refs/heads/1.x
Commit: 8326a24fd87bdb8491db7b048b064aa01f9d7d33
Parents: 311072b
Author: Clebert Suconic <cl...@apache.org>
Authored: Tue Jul 11 14:51:03 2017 -0400
Committer: Clebert Suconic <cl...@apache.org>
Committed: Tue Jul 11 14:51:03 2017 -0400
----------------------------------------------------------------------
.../artemis/core/server/impl/QueueImpl.java | 17 -----------------
1 file changed, 17 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/8326a24f/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/QueueImpl.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/QueueImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/QueueImpl.java
index 040a996..897fde3 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/QueueImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/QueueImpl.java
@@ -83,7 +83,6 @@ import org.apache.activemq.artemis.core.transaction.TransactionPropertyIndexes;
import org.apache.activemq.artemis.core.transaction.impl.BindingsTransactionImpl;
import org.apache.activemq.artemis.core.transaction.impl.TransactionImpl;
import org.apache.activemq.artemis.spi.core.protocol.RemotingConnection;
-import org.apache.activemq.artemis.utils.ConcurrentHashSet;
import org.apache.activemq.artemis.utils.FutureLatch;
import org.apache.activemq.artemis.utils.LinkedListIterator;
import org.apache.activemq.artemis.utils.PriorityLinkedList;
@@ -200,12 +199,8 @@ public class QueueImpl implements Queue {
private Redistributor redistributor;
- private final Set<ScheduledFuture<?>> futures = new ConcurrentHashSet<>();
-
private ScheduledFuture<?> redistributorFuture;
- private ScheduledFuture<?> checkQueueSizeFuture;
-
// We cache the consumers here since we don't want to include the redistributor
private final AtomicInteger consumersCount = new AtomicInteger();
@@ -642,10 +637,6 @@ public class QueueImpl implements Queue {
@Override
public void close() throws Exception {
- if (checkQueueSizeFuture != null) {
- checkQueueSizeFuture.cancel(false);
- }
-
getExecutor().execute(new Runnable() {
@Override
public void run() {
@@ -793,8 +784,6 @@ public class QueueImpl implements Queue {
DelayedAddRedistributor dar = new DelayedAddRedistributor(executor);
redistributorFuture = scheduledExecutor.schedule(dar, delay, TimeUnit.MILLISECONDS);
-
- futures.add(redistributorFuture);
}
} else {
internalAddRedistributor(executor);
@@ -806,8 +795,6 @@ public class QueueImpl implements Queue {
redistributorFuture = null;
if (future != null) {
future.cancel(false);
-
- futures.remove(future);
}
}
@@ -826,10 +813,6 @@ public class QueueImpl implements Queue {
@Override
protected void finalize() throws Throwable {
- if (checkQueueSizeFuture != null) {
- checkQueueSizeFuture.cancel(false);
- }
-
cancelRedistributor();
super.finalize();
[2/2] activemq-artemis git commit: ARTEMIS-1269 fixing checkstyle
Posted by cl...@apache.org.
ARTEMIS-1269 fixing checkstyle
Project: http://git-wip-us.apache.org/repos/asf/activemq-artemis/repo
Commit: http://git-wip-us.apache.org/repos/asf/activemq-artemis/commit/e9b7b94d
Tree: http://git-wip-us.apache.org/repos/asf/activemq-artemis/tree/e9b7b94d
Diff: http://git-wip-us.apache.org/repos/asf/activemq-artemis/diff/e9b7b94d
Branch: refs/heads/1.x
Commit: e9b7b94de73313ca61db096ee8f8516f1dec91ed
Parents: 8326a24
Author: Clebert Suconic <cl...@apache.org>
Authored: Tue Jul 11 14:53:21 2017 -0400
Committer: Clebert Suconic <cl...@apache.org>
Committed: Tue Jul 11 14:53:21 2017 -0400
----------------------------------------------------------------------
.../activemq/artemis/core/journal/impl/FileWrapperJournal.java | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/e9b7b94d/artemis-journal/src/main/java/org/apache/activemq/artemis/core/journal/impl/FileWrapperJournal.java
----------------------------------------------------------------------
diff --git a/artemis-journal/src/main/java/org/apache/activemq/artemis/core/journal/impl/FileWrapperJournal.java b/artemis-journal/src/main/java/org/apache/activemq/artemis/core/journal/impl/FileWrapperJournal.java
index 3cc1454..e6788c1 100644
--- a/artemis-journal/src/main/java/org/apache/activemq/artemis/core/journal/impl/FileWrapperJournal.java
+++ b/artemis-journal/src/main/java/org/apache/activemq/artemis/core/journal/impl/FileWrapperJournal.java
@@ -173,7 +173,7 @@ public final class FileWrapperJournal extends JournalBase {
EncodingSupport record) throws Exception {
JournalInternalRecord addRecord = new JournalAddRecordTX(true, txID, id, recordType, record);
writeRecord(addRecord, false, txID, false, null);
- }
+ }
@Override
public void appendUpdateRecord(long id,
@@ -190,7 +190,7 @@ public final class FileWrapperJournal extends JournalBase {
long id,
byte recordType,
EncodingSupport record) throws Exception {
- JournalInternalRecord updateRecordTX = new JournalAddRecordTX(false, txID, id, recordType, record);
+ JournalInternalRecord updateRecordTX = new JournalAddRecordTX(false, txID, id, recordType, record);
writeRecord(updateRecordTX, false, txID, false, null);
}