[ARTEMIS-561] Using long for counters, and renaming variables
This commit is contained in:
parent
0ed7f586a8
commit
d554301c70
|
@ -90,9 +90,9 @@ public interface JMSBridge extends ActiveMQComponent {
|
||||||
|
|
||||||
boolean isFailed();
|
boolean isFailed();
|
||||||
|
|
||||||
int getMessageCount();
|
long getMessageCount();
|
||||||
|
|
||||||
int getabortedMessageCount();
|
long getAbortedMessageCount();
|
||||||
|
|
||||||
void setSourceConnectionFactoryFactory(ConnectionFactoryFactory cff);
|
void setSourceConnectionFactoryFactory(ConnectionFactoryFactory cff);
|
||||||
|
|
||||||
|
|
|
@ -181,9 +181,9 @@ public final class JMSBridgeImpl implements JMSBridge {
|
||||||
|
|
||||||
private ClassLoader moduleTccl;
|
private ClassLoader moduleTccl;
|
||||||
|
|
||||||
private int message_count = 0;
|
private long messageCount = 0;
|
||||||
|
|
||||||
private int aborted_message_count = 0;
|
private long abortedMessageCount = 0;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Constructor for MBean
|
* Constructor for MBean
|
||||||
|
@ -492,7 +492,7 @@ public final class JMSBridgeImpl implements JMSBridge {
|
||||||
|
|
||||||
try {
|
try {
|
||||||
tx.rollback();
|
tx.rollback();
|
||||||
aborted_message_count += messages.size();
|
abortedMessageCount += messages.size();
|
||||||
}
|
}
|
||||||
catch (Exception ignore) {
|
catch (Exception ignore) {
|
||||||
if (JMSBridgeImpl.trace) {
|
if (JMSBridgeImpl.trace) {
|
||||||
|
@ -780,13 +780,13 @@ public final class JMSBridgeImpl implements JMSBridge {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public synchronized int getMessageCount() {
|
public synchronized long getMessageCount() {
|
||||||
return message_count;
|
return messageCount;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public synchronized int getabortedMessageCount() {
|
public synchronized long getAbortedMessageCount() {
|
||||||
return aborted_message_count;
|
return abortedMessageCount;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -1214,7 +1214,7 @@ public final class JMSBridgeImpl implements JMSBridge {
|
||||||
try {
|
try {
|
||||||
// Terminate the tx
|
// Terminate the tx
|
||||||
tx.rollback();
|
tx.rollback();
|
||||||
aborted_message_count += messages.size();
|
abortedMessageCount += messages.size();
|
||||||
}
|
}
|
||||||
catch (Throwable ignore) {
|
catch (Throwable ignore) {
|
||||||
if (JMSBridgeImpl.trace) {
|
if (JMSBridgeImpl.trace) {
|
||||||
|
@ -1414,7 +1414,7 @@ public final class JMSBridgeImpl implements JMSBridge {
|
||||||
try {
|
try {
|
||||||
// we call this just in case there is a failure other than failover
|
// we call this just in case there is a failure other than failover
|
||||||
tx.rollback();
|
tx.rollback();
|
||||||
aborted_message_count += messages.size();
|
abortedMessageCount += messages.size();
|
||||||
}
|
}
|
||||||
catch (Throwable ignored) {
|
catch (Throwable ignored) {
|
||||||
}
|
}
|
||||||
|
@ -1511,7 +1511,7 @@ public final class JMSBridgeImpl implements JMSBridge {
|
||||||
targetProducer.send(targetDestination, msg, msg.getJMSDeliveryMode(), msg.getJMSPriority(), timeToLive);
|
targetProducer.send(targetDestination, msg, msg.getJMSDeliveryMode(), msg.getJMSPriority(), timeToLive);
|
||||||
|
|
||||||
if (msg != null)
|
if (msg != null)
|
||||||
message_count++;
|
messageCount++;
|
||||||
if (JMSBridgeImpl.trace) {
|
if (JMSBridgeImpl.trace) {
|
||||||
ActiveMQJMSBridgeLogger.LOGGER.trace("Sent message " + msg);
|
ActiveMQJMSBridgeLogger.LOGGER.trace("Sent message " + msg);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue