activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From clebertsuco...@apache.org
Subject [3/6] activemq-artemis git commit: ARTEMIS-127 Use L as suffix for long constants
Date Fri, 12 Jun 2015 14:41:02 GMT
ARTEMIS-127 Use L as suffix for long constants


Project: http://git-wip-us.apache.org/repos/asf/activemq-artemis/repo
Commit: http://git-wip-us.apache.org/repos/asf/activemq-artemis/commit/64ecb956
Tree: http://git-wip-us.apache.org/repos/asf/activemq-artemis/tree/64ecb956
Diff: http://git-wip-us.apache.org/repos/asf/activemq-artemis/diff/64ecb956

Branch: refs/heads/master
Commit: 64ecb9565dea42c7381e9a70a08339cafff7c960
Parents: aab34e5
Author: Thiago Kronig <thiagokronig@gmail.com>
Authored: Wed Jun 10 13:24:37 2015 -0300
Committer: Thiago Kronig <thiagokronig@gmail.com>
Committed: Thu Jun 11 23:58:14 2015 -0300

----------------------------------------------------------------------
 .../DbRestartJDBCQueueMasterSlaveLeaseTest.java |  2 +-
 .../activemq/broker/region/QueuePurgeTest.java  |  2 +-
 .../cursors/StoreQueueCursorOrderTest.java      | 46 ++++++++++----------
 .../broker/scheduler/JmsSchedulerTest.java      |  8 ++--
 .../org/apache/activemq/bugs/AMQ2314Test.java   |  2 +-
 .../activemq/bugs/AMQ4485LowLimitTest.java      |  8 ++--
 ...XBrokersWithNDestsFanoutTransactionTest.java |  4 +-
 .../org/apache/activemq/bugs/AMQ4636Test.java   |  4 +-
 .../activemq/bugs/AMQ5266SingleDestTest.java    |  2 +-
 .../bugs/TrapMessageInJDBCStoreTest.java        |  4 +-
 .../command/ActiveMQStreamMessageTest.java      |  2 +-
 .../store/jdbc/JDBCIOExceptionHandlerTest.java  | 12 ++---
 .../store/jdbc/JDBCMessagePriorityTest.java     |  2 +-
 .../store/jdbc/LeaseDatabaseLockerTest.java     |  2 +-
 .../store/kahadb/KahaDBFastEnqueueTest.java     |  2 +-
 .../usecases/BacklogNetworkCrossTalkTest.java   |  2 +-
 .../BrokerQueueNetworkWithDisconnectTest.java   |  2 +-
 .../ConcurrentProducerDurableConsumerTest.java  |  2 +-
 .../ConcurrentProducerQueueConsumerTest.java    |  2 +-
 .../usecases/JdbcDurableSubDupTest.java         |  2 +-
 .../MessageGroupReconnectDistributionTest.java  |  4 +-
 ...erTempDestDemandSubscriptionCleanupTest.java |  2 +-
 22 files changed, 59 insertions(+), 59 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/ft/DbRestartJDBCQueueMasterSlaveLeaseTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/ft/DbRestartJDBCQueueMasterSlaveLeaseTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/ft/DbRestartJDBCQueueMasterSlaveLeaseTest.java
index cf4929a..422b5ff 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/ft/DbRestartJDBCQueueMasterSlaveLeaseTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/ft/DbRestartJDBCQueueMasterSlaveLeaseTest.java
@@ -43,7 +43,7 @@ public class DbRestartJDBCQueueMasterSlaveLeaseTest extends DbRestartJDBCQueueMa
         LeaseLockerIOExceptionHandler ioExceptionHandler = new LeaseLockerIOExceptionHandler();
         ioExceptionHandler.setIgnoreSQLExceptions(false);
         ioExceptionHandler.setStopStartConnectors(false);
-        ioExceptionHandler.setResumeCheckSleepPeriod(500l);
+        ioExceptionHandler.setResumeCheckSleepPeriod(500L);
         brokerService.setIoExceptionHandler(ioExceptionHandler);
     }
 

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/region/QueuePurgeTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/region/QueuePurgeTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/region/QueuePurgeTest.java
index 9120937..d02085a 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/region/QueuePurgeTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/region/QueuePurgeTest.java
@@ -67,7 +67,7 @@ public class QueuePurgeTest extends CombinationTestSupport {
         broker.setDataDirectoryFile(testDataDir);
         broker.setUseJmx(true);
         broker.setDeleteAllMessagesOnStartup(true);
-        broker.getSystemUsage().getMemoryUsage().setLimit(1024l*1024*64);
+        broker.getSystemUsage().getMemoryUsage().setLimit(1024L*1024*64);
         KahaDBPersistenceAdapter persistenceAdapter = new KahaDBPersistenceAdapter();
         persistenceAdapter.setDirectory(new File(testDataDir, "kahadb"));
         broker.setPersistenceAdapter(persistenceAdapter);

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/region/cursors/StoreQueueCursorOrderTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/region/cursors/StoreQueueCursorOrderTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/region/cursors/StoreQueueCursorOrderTest.java
index f8fab10..e5431c0 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/region/cursors/StoreQueueCursorOrderTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/region/cursors/StoreQueueCursorOrderTest.java
@@ -106,7 +106,7 @@ public class StoreQueueCursorOrderTest {
             @Override
             public void run() {
             }
-        }, 2l) {};
+        }, 2L) {};
         msg.getMessageId().setFutureOrSequenceLong(future);
         underTest.addMessageLast(msg);
 
@@ -116,12 +116,12 @@ public class StoreQueueCursorOrderTest {
         msg = getMessage(1);
         messages[0] = msg;
         msg.setMemoryUsage(systemUsage.getMemoryUsage());
-        msg.getMessageId().setFutureOrSequenceLong(1l);
+        msg.getMessageId().setFutureOrSequenceLong(1L);
         underTest.addMessageLast(msg);
 
 
         assertTrue("cache is disabled as limit reached", !underTest.isCacheEnabled());
-        assertEquals("setBatch unset", 0l, queueMessageStore.batch.get());
+        assertEquals("setBatch unset", 0L, queueMessageStore.batch.get());
 
         int dequeueCount = 0;
 
@@ -171,9 +171,9 @@ public class StoreQueueCursorOrderTest {
         FutureTask<Long> future = new FutureTask<Long>(new Runnable() {
             @Override
             public void run() {
-                msgRef.getMessageId().setFutureOrSequenceLong(1l);
+                msgRef.getMessageId().setFutureOrSequenceLong(1L);
             }
-        }, 1l) {};
+        }, 1L) {};
         msg.getMessageId().setFutureOrSequenceLong(future);
         Executors.newSingleThreadExecutor().submit(future);
         underTest.addMessageLast(msg);
@@ -184,12 +184,12 @@ public class StoreQueueCursorOrderTest {
         msg = getMessage(1);
         messages[0] = msg;
         msg.setMemoryUsage(systemUsage.getMemoryUsage());
-        msg.getMessageId().setFutureOrSequenceLong(1l);
+        msg.getMessageId().setFutureOrSequenceLong(1L);
         underTest.addMessageLast(msg);
 
 
         assertTrue("cache is disabled as limit reached", !underTest.isCacheEnabled());
-        assertEquals("setBatch unset", 0l, queueMessageStore.batch.get());
+        assertEquals("setBatch unset", 0L, queueMessageStore.batch.get());
 
         int dequeueCount = 0;
 
@@ -239,9 +239,9 @@ public class StoreQueueCursorOrderTest {
         FutureTask<Long> future = new FutureTask<Long>(new Runnable() {
             @Override
             public void run() {
-                msgRef.getMessageId().setFutureOrSequenceLong(0l);
+                msgRef.getMessageId().setFutureOrSequenceLong(0L);
             }
-        }, 0l) {};
+        }, 0L) {};
         msg.getMessageId().setFutureOrSequenceLong(future);
         Executors.newSingleThreadExecutor().submit(future);
         underTest.addMessageLast(msg);
@@ -257,16 +257,16 @@ public class StoreQueueCursorOrderTest {
         FutureTask<Long> future2 = new FutureTask<Long>(new Runnable() {
             @Override
             public void run() {
-                msgRe2f.getMessageId().setFutureOrSequenceLong(1l);
+                msgRe2f.getMessageId().setFutureOrSequenceLong(1L);
             }
-        }, 1l) {};
+        }, 1L) {};
         msg.getMessageId().setFutureOrSequenceLong(future2);
         Executors.newSingleThreadExecutor().submit(future2);
         underTest.addMessageLast(msg);
 
 
         assertTrue("cache is disabled as limit reached", !underTest.isCacheEnabled());
-        assertEquals("setBatch set", 1l, queueMessageStore.batch.get());
+        assertEquals("setBatch set", 1L, queueMessageStore.batch.get());
 
         int dequeueCount = 0;
 
@@ -316,9 +316,9 @@ public class StoreQueueCursorOrderTest {
         FutureTask<Long> future0 = new FutureTask<Long>(new Runnable() {
             @Override
             public void run() {
-                msgRef.getMessageId().setFutureOrSequenceLong(0l);
+                msgRef.getMessageId().setFutureOrSequenceLong(0L);
             }
-        }, 0l) {};
+        }, 0L) {};
         msg.getMessageId().setFutureOrSequenceLong(future0);
         underTest.addMessageLast(msg);
         Executors.newSingleThreadExecutor().submit(future0);
@@ -332,9 +332,9 @@ public class StoreQueueCursorOrderTest {
         FutureTask<Long> future1 = new FutureTask<Long>(new Runnable() {
             @Override
             public void run() {
-                msgRef1.getMessageId().setFutureOrSequenceLong(3l);
+                msgRef1.getMessageId().setFutureOrSequenceLong(3L);
             }
-        }, 3l) {};
+        }, 3L) {};
         msg.getMessageId().setFutureOrSequenceLong(future1);
         underTest.addMessageLast(msg);
 
@@ -342,7 +342,7 @@ public class StoreQueueCursorOrderTest {
         msg = getMessage(2);
         messages[1] = msg;
         msg.setMemoryUsage(systemUsage.getMemoryUsage());
-        msg.getMessageId().setFutureOrSequenceLong(1l);
+        msg.getMessageId().setFutureOrSequenceLong(1L);
         underTest.addMessageLast(msg);
 
         assertTrue("cache enabled", underTest.isUseCache() && underTest.isCacheEnabled());
@@ -354,12 +354,12 @@ public class StoreQueueCursorOrderTest {
         msg = getMessage(3);
         messages[2] = msg;
         msg.setMemoryUsage(systemUsage.getMemoryUsage());
-        msg.getMessageId().setFutureOrSequenceLong(3l);
+        msg.getMessageId().setFutureOrSequenceLong(3L);
         underTest.addMessageLast(msg);
 
 
         assertTrue("cache is disabled as limit reached", !underTest.isCacheEnabled());
-        assertEquals("setBatch set", 2l, queueMessageStore.batch.get());
+        assertEquals("setBatch set", 2L, queueMessageStore.batch.get());
 
         int dequeueCount = 0;
 
@@ -405,13 +405,13 @@ public class StoreQueueCursorOrderTest {
         ActiveMQTextMessage msg = getMessage(0);
         messages[0] = msg;
         msg.setMemoryUsage(systemUsage.getMemoryUsage());
-        msg.getMessageId().setFutureOrSequenceLong(0l);
+        msg.getMessageId().setFutureOrSequenceLong(0L);
         underTest.addMessageLast(msg);
 
         msg = getMessage(1);
         messages[1] = msg;
         msg.setMemoryUsage(systemUsage.getMemoryUsage());
-        msg.getMessageId().setFutureOrSequenceLong(1l);
+        msg.getMessageId().setFutureOrSequenceLong(1L);
         underTest.addMessageLast(msg);
 
         assertTrue("cache enabled", underTest.isUseCache() && underTest.isCacheEnabled());
@@ -419,12 +419,12 @@ public class StoreQueueCursorOrderTest {
         msg = getMessage(2);
         messages[2] = msg;
         msg.setMemoryUsage(systemUsage.getMemoryUsage());
-        msg.getMessageId().setFutureOrSequenceLong(2l);
+        msg.getMessageId().setFutureOrSequenceLong(2L);
         underTest.addMessageLast(msg);
 
 
         assertTrue("cache is disabled as limit reached", !underTest.isCacheEnabled());
-        assertEquals("setBatch set", 2l, queueMessageStore.batch.get());
+        assertEquals("setBatch set", 2L, queueMessageStore.batch.get());
 
         int dequeueCount = 0;
 

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/scheduler/JmsSchedulerTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/scheduler/JmsSchedulerTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/scheduler/JmsSchedulerTest.java
index 0ce584d..41b0f0d 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/scheduler/JmsSchedulerTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/broker/scheduler/JmsSchedulerTest.java
@@ -260,7 +260,7 @@ public class JmsSchedulerTest extends JobSchedulerTestSupport {
         // wait for the producer to block, which should happen immediately, and also wait
long
         // enough for the delay to elapse.  We should see no deliveries as the send should
block
         // on the first message.
-        Thread.sleep(10000l);
+        Thread.sleep(10000L);
 
         assertEquals(100, latch.getCount());
 
@@ -268,7 +268,7 @@ public class JmsSchedulerTest extends JobSchedulerTestSupport {
         broker.getSystemUsage().getJobSchedulerUsage().setLimit(1024 * 1024 * 33);
 
         // Wait long enough that the messages are enqueued and the delivery delay has elapsed.
-        Thread.sleep(10000l);
+        Thread.sleep(10000L);
 
         // Make sure we sent all the messages we expected to send
         Wait.waitFor(new Wait.Condition() {
@@ -276,12 +276,12 @@ public class JmsSchedulerTest extends JobSchedulerTestSupport {
             public boolean isSatisified() throws Exception {
                 return producer.getSentCount() == producer.getMessageCount();
             }
-        }, 20000l);
+        }, 20000L);
 
         assertEquals("Producer didn't send all messages", producer.getMessageCount(), producer.getSentCount());
 
         // Make sure we got all the messages we expected to get
-        latch.await(20000l, TimeUnit.MILLISECONDS);
+        latch.await(20000L, TimeUnit.MILLISECONDS);
 
         assertEquals("Consumer did not receive all messages.", 0, latch.getCount());
     }

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ2314Test.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ2314Test.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ2314Test.java
index 369385c..08be5db 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ2314Test.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ2314Test.java
@@ -157,7 +157,7 @@ public class AMQ2314Test extends CombinationTestSupport {
         broker.setUseJmx(true);
         broker.setAdvisorySupport(false);
         broker.setDeleteAllMessagesOnStartup(true);
-        broker.getSystemUsage().getMemoryUsage().setLimit(1024l*1024*64);
+        broker.getSystemUsage().getMemoryUsage().setLimit(1024L*1024*64);
 
         broker.addConnector("tcp://localhost:0").setName("Default");
         broker.start();

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ4485LowLimitTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ4485LowLimitTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ4485LowLimitTest.java
index 21c389f..7c549b4 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ4485LowLimitTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ4485LowLimitTest.java
@@ -101,14 +101,14 @@ public class AMQ4485LowLimitTest extends JmsMultipleBrokersTestSupport
{
             addNetworkConnector(broker);
         }
         broker.setSchedulePeriodForDestinationPurge(0);
-        broker.getSystemUsage().getMemoryUsage().setLimit(256 * 1024 * 1024l);
+        broker.getSystemUsage().getMemoryUsage().setLimit(256 * 1024 * 1024L);
 
 
         PolicyMap policyMap = new PolicyMap();
         PolicyEntry policyEntry = new PolicyEntry();
         policyEntry.setExpireMessagesPeriod(0);
         policyEntry.setQueuePrefetch(1000);
-        policyEntry.setMemoryLimit(2 * 1024 * 1024l);
+        policyEntry.setMemoryLimit(2 * 1024 * 1024L);
         policyEntry.setProducerFlowControl(false);
         policyEntry.setEnableAudit(true);
         policyEntry.setUseCache(true);
@@ -117,7 +117,7 @@ public class AMQ4485LowLimitTest extends JmsMultipleBrokersTestSupport
{
         PolicyEntry inPolicyEntry = new PolicyEntry();
         inPolicyEntry.setExpireMessagesPeriod(0);
         inPolicyEntry.setQueuePrefetch(1000);
-        inPolicyEntry.setMemoryLimit(5 * 1024 * 1024l);
+        inPolicyEntry.setMemoryLimit(5 * 1024 * 1024L);
         inPolicyEntry.setProducerFlowControl(true);
         inPolicyEntry.setEnableAudit(true);
         inPolicyEntry.setUseCache(true);
@@ -252,7 +252,7 @@ public class AMQ4485LowLimitTest extends JmsMultipleBrokersTestSupport
{
                 }
                 return true;
             }
-        }, 1000 * 60 * 1000l, 20*1000));
+        }, 1000 * 60 * 1000L, 20*1000));
 
         assertTrue("No exceptions:" + exceptions, exceptions.isEmpty());
 

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ4485NetworkOfXBrokersWithNDestsFanoutTransactionTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ4485NetworkOfXBrokersWithNDestsFanoutTransactionTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ4485NetworkOfXBrokersWithNDestsFanoutTransactionTest.java
index c2cf53a..8e4e4b7 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ4485NetworkOfXBrokersWithNDestsFanoutTransactionTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ4485NetworkOfXBrokersWithNDestsFanoutTransactionTest.java
@@ -98,7 +98,7 @@ public class AMQ4485NetworkOfXBrokersWithNDestsFanoutTransactionTest extends
Jms
         PolicyEntry policyEntry = new PolicyEntry();
         policyEntry.setExpireMessagesPeriod(0);
         policyEntry.setQueuePrefetch(1000);
-        policyEntry.setMemoryLimit(1024 * 1024l);
+        policyEntry.setMemoryLimit(1024 * 1024L);
         policyEntry.setOptimizedDispatch(false);
         policyEntry.setProducerFlowControl(false);
         policyEntry.setEnableAudit(true);
@@ -171,7 +171,7 @@ public class AMQ4485NetworkOfXBrokersWithNDestsFanoutTransactionTest extends
Jms
                 }
                 return true;
             }
-        }, 1000 * 60 * 1000l));
+        }, 1000 * 60 * 1000L));
 
         assertTrue("No exceptions:" + exceptions, exceptions.isEmpty());
 

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ4636Test.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ4636Test.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ4636Test.java
index b9246fb..1e0ccb9 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ4636Test.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ4636Test.java
@@ -101,9 +101,9 @@ public class AMQ4636Test {
         JDBCPersistenceAdapter jdbc = new TestJDBCPersistenceAdapter();
         jdbc.setDataSource(embeddedDataSource);
 
-        jdbc.setLockKeepAlivePeriod(1000l);
+        jdbc.setLockKeepAlivePeriod(1000L);
         LeaseDatabaseLocker leaseDatabaseLocker = new LeaseDatabaseLocker();
-        leaseDatabaseLocker.setLockAcquireSleepInterval(2000l);
+        leaseDatabaseLocker.setLockAcquireSleepInterval(2000L);
         jdbc.setLocker(leaseDatabaseLocker);
 
         broker = new BrokerService();

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ5266SingleDestTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ5266SingleDestTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ5266SingleDestTest.java
index 0d7f44b..ba7ee4d 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ5266SingleDestTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ5266SingleDestTest.java
@@ -227,7 +227,7 @@ public class AMQ5266SingleDestTest {
         }
 
         // verify empty dlq
-        assertEquals("No pending messages", 0l, ((RegionBroker) brokerService.getRegionBroker()).getDestinationStatistics().getMessages().getCount());
+        assertEquals("No pending messages", 0L, ((RegionBroker) brokerService.getRegionBroker()).getDestinationStatistics().getMessages().getCount());
     }
 
     public class ExportQueuePublisher {

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/TrapMessageInJDBCStoreTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/TrapMessageInJDBCStoreTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/TrapMessageInJDBCStoreTest.java
index 688d066..ad6df7f 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/TrapMessageInJDBCStoreTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/TrapMessageInJDBCStoreTest.java
@@ -82,9 +82,9 @@ public class TrapMessageInJDBCStoreTest extends TestCase {
         jdbc.setCleanupPeriod(0);
         testTransactionContext = new TestTransactionContext(jdbc);
 
-        jdbc.setLockKeepAlivePeriod(1000l);
+        jdbc.setLockKeepAlivePeriod(1000L);
         LeaseDatabaseLocker leaseDatabaseLocker = new LeaseDatabaseLocker();
-        leaseDatabaseLocker.setLockAcquireSleepInterval(2000l);
+        leaseDatabaseLocker.setLockAcquireSleepInterval(2000L);
         jdbc.setLocker(leaseDatabaseLocker);
 
         broker.setPersistenceAdapter(jdbc);

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/command/ActiveMQStreamMessageTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/command/ActiveMQStreamMessageTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/command/ActiveMQStreamMessageTest.java
index 9e0f468..e042217 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/command/ActiveMQStreamMessageTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/command/ActiveMQStreamMessageTest.java
@@ -979,7 +979,7 @@ public class ActiveMQStreamMessageTest extends TestCase {
             message.writeObject(new Byte((byte) 2));
             message.writeObject(new Short((short) 2));
             message.writeObject(new Integer(2));
-            message.writeObject(new Long(2l));
+            message.writeObject(new Long(2L));
             message.writeObject(new Float(2.0f));
             message.writeObject(new Double(2.0d));
         }catch(Exception e) {

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/jdbc/JDBCIOExceptionHandlerTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/jdbc/JDBCIOExceptionHandlerTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/jdbc/JDBCIOExceptionHandlerTest.java
index df10d73..2502110 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/jdbc/JDBCIOExceptionHandlerTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/jdbc/JDBCIOExceptionHandlerTest.java
@@ -71,17 +71,17 @@ public class JDBCIOExceptionHandlerTest extends TestCase {
         JDBCPersistenceAdapter jdbc = new JDBCPersistenceAdapter();
         jdbc.setDataSource(dataSource);
 
-        jdbc.setLockKeepAlivePeriod(1000l);
+        jdbc.setLockKeepAlivePeriod(1000L);
         if (leaseLocker) {
             LeaseDatabaseLocker leaseDatabaseLocker = new LeaseDatabaseLocker();
             leaseDatabaseLocker.setHandleStartException(true);
-            leaseDatabaseLocker.setLockAcquireSleepInterval(2000l);
+            leaseDatabaseLocker.setLockAcquireSleepInterval(2000L);
             jdbc.setLocker(leaseDatabaseLocker);
         }
 
         broker.setPersistenceAdapter(jdbc);
         LeaseLockerIOExceptionHandler ioExceptionHandler = new LeaseLockerIOExceptionHandler();
-        ioExceptionHandler.setResumeCheckSleepPeriod(1000l);
+        ioExceptionHandler.setResumeCheckSleepPeriod(1000L);
         ioExceptionHandler.setStopStartConnectors(startStopConnectors);
         broker.setIoExceptionHandler(ioExceptionHandler);
         String connectionUri = broker.addConnector(TRANSPORT_URL).getPublishableConnectString();
@@ -129,18 +129,18 @@ public class JDBCIOExceptionHandlerTest extends TestCase {
                     JDBCPersistenceAdapter jdbc = new JDBCPersistenceAdapter();
                     jdbc.setDataSource(dataSource);
 
-                    jdbc.setLockKeepAlivePeriod(1000l);
+                    jdbc.setLockKeepAlivePeriod(1000L);
 
                     if (lease) {
                         LeaseDatabaseLocker leaseDatabaseLocker = new LeaseDatabaseLocker();
                         leaseDatabaseLocker.setHandleStartException(true);
-                        leaseDatabaseLocker.setLockAcquireSleepInterval(2000l);
+                        leaseDatabaseLocker.setLockAcquireSleepInterval(2000L);
                         jdbc.setLocker(leaseDatabaseLocker);
                     }
 
                     broker.setPersistenceAdapter(jdbc);
                     LeaseLockerIOExceptionHandler ioExceptionHandler = new LeaseLockerIOExceptionHandler();
-                    ioExceptionHandler.setResumeCheckSleepPeriod(1000l);
+                    ioExceptionHandler.setResumeCheckSleepPeriod(1000L);
                     ioExceptionHandler.setStopStartConnectors(false);
                     broker.setIoExceptionHandler(ioExceptionHandler);
                     slave.set(broker);

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/jdbc/JDBCMessagePriorityTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/jdbc/JDBCMessagePriorityTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/jdbc/JDBCMessagePriorityTest.java
index 34796a4..2399738 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/jdbc/JDBCMessagePriorityTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/jdbc/JDBCMessagePriorityTest.java
@@ -150,7 +150,7 @@ public class JDBCMessagePriorityTest extends MessagePriorityTest {
         for (int priority = 0; priority < maxPriority; priority++) {
             producers.add(new ProducerThread(topic, MSG_NUM, priority));
             messageCounts[priority] = new AtomicInteger(0);
-            messageIds[priority] = 1l;
+            messageIds[priority] = 1L;
         }
 
         for (ProducerThread producer : producers) {

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/jdbc/LeaseDatabaseLockerTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/jdbc/LeaseDatabaseLockerTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/jdbc/LeaseDatabaseLockerTest.java
index 774d172..6042ae6 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/jdbc/LeaseDatabaseLockerTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/jdbc/LeaseDatabaseLockerTest.java
@@ -188,7 +188,7 @@ public class LeaseDatabaseLockerTest {
 
         statement = connection.prepareStatement(jdbc.getStatements().getLeaseUpdateStatement());
         statement.setString(1, null);
-        statement.setLong(2, 0l);
+        statement.setLong(2, 0L);
         statement.setString(3, fakeId);
         assertEquals("we released " + fakeId, 1, statement.executeUpdate());
         LOG.info("released " + fakeId);

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/kahadb/KahaDBFastEnqueueTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/kahadb/KahaDBFastEnqueueTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/kahadb/KahaDBFastEnqueueTest.java
index 15abe3d..57530da 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/kahadb/KahaDBFastEnqueueTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/store/kahadb/KahaDBFastEnqueueTest.java
@@ -189,7 +189,7 @@ public class KahaDBFastEnqueueTest {
 
         MessageProducer producer = session.createProducer(destination);
         Long start = System.currentTimeMillis();
-        long i = 0l;
+        long i = 0L;
         while ( (i=count.getAndDecrement()) > 0) {
             Message message = null;
             if (useBytesMessage) {

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/BacklogNetworkCrossTalkTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/BacklogNetworkCrossTalkTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/BacklogNetworkCrossTalkTest.java
index 3e9b913..b56c5b0 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/BacklogNetworkCrossTalkTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/BacklogNetworkCrossTalkTest.java
@@ -69,7 +69,7 @@ public class BacklogNetworkCrossTalkTest extends JmsMultipleBrokersTestSupport
{
         MessageConsumer clientB = createConsumer("B", destA);
 
 
-        final long maxWait = 5 * 60 * 1000l;
+        final long maxWait = 5 * 60 * 1000L;
         MessageIdList listA = getConsumerMessages("A", clientA);
         listA.setMaximumDuration(maxWait);
         listA.waitForMessagesToArrive(numMessages);

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/BrokerQueueNetworkWithDisconnectTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/BrokerQueueNetworkWithDisconnectTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/BrokerQueueNetworkWithDisconnectTest.java
index 0b8de29..e32a1bc 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/BrokerQueueNetworkWithDisconnectTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/BrokerQueueNetworkWithDisconnectTest.java
@@ -88,7 +88,7 @@ public class BrokerQueueNetworkWithDisconnectTest extends JmsMultipleBrokersTest
 
     @SuppressWarnings("unchecked")
     public void testNoStuckConnectionsWithTransportDisconnect() throws Exception {
-        inactiveDuration=60000l;
+        inactiveDuration=60000L;
         useDuplexNetworkBridge = true;
 
         bridgeBrokers(SPOKE, HUB);

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/ConcurrentProducerDurableConsumerTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/ConcurrentProducerDurableConsumerTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/ConcurrentProducerDurableConsumerTest.java
index a5233ee..e1035a6 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/ConcurrentProducerDurableConsumerTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/ConcurrentProducerDurableConsumerTest.java
@@ -405,7 +405,7 @@ public class ConcurrentProducerDurableConsumerTest extends TestSupport
{
         final int batchSize = 1000;
         CountDownLatch firstReceiptLatch = new CountDownLatch(1);
         long mark = System.currentTimeMillis();
-        long firstReceipt = 0l;
+        long firstReceipt = 0L;
         long receiptAccumulator = 0;
         long batchReceiptAccumulator = 0;
         long maxReceiptTime = 0;

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/ConcurrentProducerQueueConsumerTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/ConcurrentProducerQueueConsumerTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/ConcurrentProducerQueueConsumerTest.java
index e9e3b54..34807c6 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/ConcurrentProducerQueueConsumerTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/ConcurrentProducerQueueConsumerTest.java
@@ -362,7 +362,7 @@ public class ConcurrentProducerQueueConsumerTest extends TestSupport
         final CountDownLatch firstReceiptLatch = new CountDownLatch(1);
 
         long mark = System.currentTimeMillis();
-        long firstReceipt = 0l;
+        long firstReceipt = 0L;
         long receiptAccumulator = 0;
         long batchReceiptAccumulator = 0;
         long maxReceiptTime = 0;

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/JdbcDurableSubDupTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/JdbcDurableSubDupTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/JdbcDurableSubDupTest.java
index 0cb2648..1b3be06 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/JdbcDurableSubDupTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/JdbcDurableSubDupTest.java
@@ -239,7 +239,7 @@ public class JdbcDurableSubDupTest {
 
             ActiveMQConnectionFactory factory;
             MessageProducer messageProducer;
-            long timeToLive = 0l;
+            long timeToLive = 0L;
 
             TextMessage message = null;
 

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/MessageGroupReconnectDistributionTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/MessageGroupReconnectDistributionTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/MessageGroupReconnectDistributionTest.java
index da2f367..bbc3a7a 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/MessageGroupReconnectDistributionTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/MessageGroupReconnectDistributionTest.java
@@ -122,8 +122,8 @@ public class MessageGroupReconnectDistributionTest {
         final ArrayList<AtomicLong> batchCounters = new ArrayList<AtomicLong>(numConsumers);
 
         for (int i = 0; i < numConsumers; i++) {
-            consumedCounters.add(new AtomicLong(0l));
-            batchCounters.add(new AtomicLong(0l));
+            consumedCounters.add(new AtomicLong(0L));
+            batchCounters.add(new AtomicLong(0L));
 
             final int id = i;
             executorService.submit(new Runnable() {

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/64ecb956/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/ThreeBrokerTempDestDemandSubscriptionCleanupTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/ThreeBrokerTempDestDemandSubscriptionCleanupTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/ThreeBrokerTempDestDemandSubscriptionCleanupTest.java
index 08435df..aa1b89b 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/ThreeBrokerTempDestDemandSubscriptionCleanupTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/ThreeBrokerTempDestDemandSubscriptionCleanupTest.java
@@ -122,7 +122,7 @@ public class ThreeBrokerTempDestDemandSubscriptionCleanupTest extends
JmsMultipl
         threadService.submit(tester);
 
         threadService.shutdown();
-        assertTrue("executor done on time", threadService.awaitTermination(30l, TimeUnit.SECONDS));
+        assertTrue("executor done on time", threadService.awaitTermination(30L, TimeUnit.SECONDS));
 
         // for the real test... we should not have any subscriptions left on broker C for
the temp dests
         BrokerItem brokerC = brokers.get(BROKER_C);


Mime
View raw message