mirror of https://github.com/apache/activemq.git
https://issues.apache.org/jira/browse/AMQ-3431 - guard debug logging
git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@1152757 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
be37064a17
commit
44ef96e6d3
|
@ -108,7 +108,9 @@ public class TransactionBroker extends BrokerFilter {
|
||||||
}
|
}
|
||||||
transaction.setState(Transaction.PREPARED_STATE);
|
transaction.setState(Transaction.PREPARED_STATE);
|
||||||
registerMBean(transaction);
|
registerMBean(transaction);
|
||||||
|
if (LOG.isDebugEnabled()) {
|
||||||
LOG.debug("recovered prepared transaction: " + transaction.getTransactionId());
|
LOG.debug("recovered prepared transaction: " + transaction.getTransactionId());
|
||||||
|
}
|
||||||
} catch (Throwable e) {
|
} catch (Throwable e) {
|
||||||
throw new WrappedException(e);
|
throw new WrappedException(e);
|
||||||
}
|
}
|
||||||
|
|
|
@ -475,7 +475,9 @@ public class Queue extends BaseDestination implements Task, UsageListener {
|
||||||
if (ref.getMessageId().getBrokerSequenceId() == lastDeiveredSequenceId) {
|
if (ref.getMessageId().getBrokerSequenceId() == lastDeiveredSequenceId) {
|
||||||
lastDeliveredRef = ref;
|
lastDeliveredRef = ref;
|
||||||
markAsRedelivered = true;
|
markAsRedelivered = true;
|
||||||
|
if (LOG.isDebugEnabled()) {
|
||||||
LOG.debug("found lastDeliveredSeqID: " + lastDeiveredSequenceId + ", message reference: " + ref.getMessageId());
|
LOG.debug("found lastDeliveredSeqID: " + lastDeiveredSequenceId + ", message reference: " + ref.getMessageId());
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -984,7 +986,9 @@ public class Queue extends BaseDestination implements Task, UsageListener {
|
||||||
for (MessageReference ref : toExpire) {
|
for (MessageReference ref : toExpire) {
|
||||||
pagedInPendingDispatch.remove(ref);
|
pagedInPendingDispatch.remove(ref);
|
||||||
if (broker.isExpired(ref)) {
|
if (broker.isExpired(ref)) {
|
||||||
|
if (LOG.isDebugEnabled()) {
|
||||||
LOG.debug("expiring from pagedInPending: " + ref);
|
LOG.debug("expiring from pagedInPending: " + ref);
|
||||||
|
}
|
||||||
messageExpired(connectionContext, ref);
|
messageExpired(connectionContext, ref);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1000,7 +1004,9 @@ public class Queue extends BaseDestination implements Task, UsageListener {
|
||||||
}
|
}
|
||||||
for (MessageReference ref : toExpire) {
|
for (MessageReference ref : toExpire) {
|
||||||
if (broker.isExpired(ref)) {
|
if (broker.isExpired(ref)) {
|
||||||
|
if (LOG.isDebugEnabled()) {
|
||||||
LOG.debug("expiring from pagedInMessages: " + ref);
|
LOG.debug("expiring from pagedInMessages: " + ref);
|
||||||
|
}
|
||||||
messageExpired(connectionContext, ref);
|
messageExpired(connectionContext, ref);
|
||||||
} else {
|
} else {
|
||||||
pagedInMessagesLock.writeLock().lock();
|
pagedInMessagesLock.writeLock().lock();
|
||||||
|
@ -1021,7 +1027,9 @@ public class Queue extends BaseDestination implements Task, UsageListener {
|
||||||
MessageReference node = messages.next();
|
MessageReference node = messages.next();
|
||||||
if (node.isExpired()) {
|
if (node.isExpired()) {
|
||||||
if (broker.isExpired(node)) {
|
if (broker.isExpired(node)) {
|
||||||
|
if (LOG.isDebugEnabled()) {
|
||||||
LOG.debug("expiring from messages: " + node);
|
LOG.debug("expiring from messages: " + node);
|
||||||
|
}
|
||||||
messageExpired(connectionContext, createMessageReference(node.getMessage()));
|
messageExpired(connectionContext, createMessageReference(node.getMessage()));
|
||||||
}
|
}
|
||||||
messages.remove();
|
messages.remove();
|
||||||
|
|
|
@ -669,7 +669,9 @@ public class RegionBroker extends EmptyBroker {
|
||||||
brokerInfos.put(info.getBrokerId(), existing);
|
brokerInfos.put(info.getBrokerId(), existing);
|
||||||
}
|
}
|
||||||
existing.incrementRefCount();
|
existing.incrementRefCount();
|
||||||
|
if (LOG.isDebugEnabled()) {
|
||||||
LOG.debug(getBrokerName() + " addBroker:" + info.getBrokerName() + " brokerInfo size : " + brokerInfos.size());
|
LOG.debug(getBrokerName() + " addBroker:" + info.getBrokerName() + " brokerInfo size : " + brokerInfos.size());
|
||||||
|
}
|
||||||
addBrokerInClusterUpdate();
|
addBrokerInClusterUpdate();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -680,7 +682,9 @@ public class RegionBroker extends EmptyBroker {
|
||||||
if (existing != null && existing.decrementRefCount() == 0) {
|
if (existing != null && existing.decrementRefCount() == 0) {
|
||||||
brokerInfos.remove(info.getBrokerId());
|
brokerInfos.remove(info.getBrokerId());
|
||||||
}
|
}
|
||||||
|
if (LOG.isDebugEnabled()) {
|
||||||
LOG.debug(getBrokerName() + " removeBroker:" + info.getBrokerName() + " brokerInfo size : " + brokerInfos.size());
|
LOG.debug(getBrokerName() + " removeBroker:" + info.getBrokerName() + " brokerInfo size : " + brokerInfos.size());
|
||||||
|
}
|
||||||
removeBrokerInClusterUpdate();
|
removeBrokerInClusterUpdate();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -76,8 +76,10 @@ public class TempQueue extends Queue{
|
||||||
.getConnectionId()))) {
|
.getConnectionId()))) {
|
||||||
|
|
||||||
tempDest.setConnectionId(sub.getConsumerInfo().getConsumerId().getConnectionId());
|
tempDest.setConnectionId(sub.getConsumerInfo().getConsumerId().getConnectionId());
|
||||||
|
if (LOG.isDebugEnabled()) {
|
||||||
LOG.debug(" changed ownership of " + this + " to "+ tempDest.getConnectionId());
|
LOG.debug(" changed ownership of " + this + " to "+ tempDest.getConnectionId());
|
||||||
}
|
}
|
||||||
|
}
|
||||||
super.addSubscription(context, sub);
|
super.addSubscription(context, sub);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -61,8 +61,10 @@ public class TempTopic extends Topic implements Task{
|
||||||
.getConnectionId()))) {
|
.getConnectionId()))) {
|
||||||
|
|
||||||
tempDest.setConnectionId(sub.getConsumerInfo().getConsumerId().getConnectionId());
|
tempDest.setConnectionId(sub.getConsumerInfo().getConsumerId().getConnectionId());
|
||||||
|
if (LOG.isDebugEnabled()) {
|
||||||
LOG.debug(" changed ownership of " + this + " to "+ tempDest.getConnectionId());
|
LOG.debug(" changed ownership of " + this + " to "+ tempDest.getConnectionId());
|
||||||
}
|
}
|
||||||
|
}
|
||||||
super.addSubscription(context, sub);
|
super.addSubscription(context, sub);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -214,7 +214,9 @@ public class TopicRegion extends AbstractRegion {
|
||||||
for (int i = 0; i < infos.length; i++) {
|
for (int i = 0; i < infos.length; i++) {
|
||||||
|
|
||||||
SubscriptionInfo info = infos[i];
|
SubscriptionInfo info = infos[i];
|
||||||
|
if (LOG.isDebugEnabled()) {
|
||||||
LOG.debug("Restoring durable subscription: " + info);
|
LOG.debug("Restoring durable subscription: " + info);
|
||||||
|
}
|
||||||
SubscriptionKey key = new SubscriptionKey(info);
|
SubscriptionKey key = new SubscriptionKey(info);
|
||||||
|
|
||||||
// A single durable sub may be subscribing to multiple topics.
|
// A single durable sub may be subscribing to multiple topics.
|
||||||
|
|
Loading…
Reference in New Issue