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/09/29 01:44:09 UTC
[1/2] activemq-artemis git commit: This closes #1502
Repository: activemq-artemis
Updated Branches:
refs/heads/master 3035a57e4 -> af6e3562a
This closes #1502
Project: http://git-wip-us.apache.org/repos/asf/activemq-artemis/repo
Commit: http://git-wip-us.apache.org/repos/asf/activemq-artemis/commit/af6e3562
Tree: http://git-wip-us.apache.org/repos/asf/activemq-artemis/tree/af6e3562
Diff: http://git-wip-us.apache.org/repos/asf/activemq-artemis/diff/af6e3562
Branch: refs/heads/master
Commit: af6e3562a8ecc64da65c28c9664a4cde9379ab43
Parents: 3035a57 7c433e5
Author: Clebert Suconic <cl...@apache.org>
Authored: Thu Sep 28 21:41:40 2017 -0400
Committer: Clebert Suconic <cl...@apache.org>
Committed: Thu Sep 28 21:41:40 2017 -0400
----------------------------------------------------------------------
.../core/config/impl/ConfigurationImpl.java | 5 +-
.../core/paging/cursor/PagedReferenceImpl.java | 4 +-
.../cursor/impl/PageCursorProviderImpl.java | 4 +-
.../cursor/impl/PageSubscriptionImpl.java | 4 +-
.../journal/AbstractJournalStorageManager.java | 4 +-
.../impl/journal/JournalStorageManager.java | 2 +-
.../impl/journal/LargeServerMessageImpl.java | 2 +-
.../impl/journal/LargeServerMessageInSync.java | 2 +-
.../core/ServerSessionPacketHandler.java | 2 +-
.../core/remoting/impl/invm/InVMAcceptor.java | 3 +-
.../core/remoting/impl/netty/NettyAcceptor.java | 2 +-
.../server/impl/RemotingServiceImpl.java | 2 +-
.../core/replication/ReplicationManager.java | 2 +-
.../core/server/ActiveMQServerLogger.java | 260 ++++++++++++++++++-
.../core/server/cluster/BackupManager.java | 2 +-
.../core/server/cluster/ClusterManager.java | 4 +-
.../server/cluster/ha/ColocatedHAManager.java | 2 +-
.../cluster/impl/ClusterConnectionImpl.java | 4 +-
.../core/server/cluster/impl/Redistributor.java | 6 +-
.../core/server/impl/ActiveMQServerImpl.java | 10 +-
.../core/server/impl/ColocatedActivation.java | 4 +-
.../impl/LegacyLDAPSecuritySettingPlugin.java | 6 +-
.../artemis/core/server/impl/QueueImpl.java | 20 +-
.../artemis/core/server/impl/RefsOperation.java | 4 +-
.../core/server/impl/ScaleDownHandler.java | 2 +-
.../core/server/impl/ServerConsumerImpl.java | 2 +-
.../core/server/impl/ServerSessionImpl.java | 14 +-
.../impl/SharedStoreBackupActivation.java | 5 +-
.../server/impl/TransientQueueManagerImpl.java | 2 +-
.../management/impl/ManagementServiceImpl.java | 2 +-
.../core/server/reload/ReloadManagerImpl.java | 2 +-
.../core/transaction/impl/TransactionImpl.java | 2 +-
.../core/protocol/AbstractProtocolManager.java | 2 +-
.../security/ActiveMQJAASSecurityManager.java | 5 +-
.../spi/core/security/jaas/LDAPLoginModule.java | 4 +-
.../security/jaas/ReloadableProperties.java | 2 +-
36 files changed, 328 insertions(+), 76 deletions(-)
----------------------------------------------------------------------
[2/2] activemq-artemis git commit: ARTEMIS-1382 Improve
artemis-server logging
Posted by cl...@apache.org.
ARTEMIS-1382 Improve artemis-server logging
Project: http://git-wip-us.apache.org/repos/asf/activemq-artemis/repo
Commit: http://git-wip-us.apache.org/repos/asf/activemq-artemis/commit/7c433e52
Tree: http://git-wip-us.apache.org/repos/asf/activemq-artemis/tree/7c433e52
Diff: http://git-wip-us.apache.org/repos/asf/activemq-artemis/diff/7c433e52
Branch: refs/heads/master
Commit: 7c433e527ac636a5dfc17b4f49da3052ef3376ea
Parents: 3035a57
Author: Dmitrii Tikhomirov <dt...@redhat.com>
Authored: Wed Sep 27 15:40:18 2017 +0200
Committer: Clebert Suconic <cl...@apache.org>
Committed: Thu Sep 28 21:41:40 2017 -0400
----------------------------------------------------------------------
.../core/config/impl/ConfigurationImpl.java | 5 +-
.../core/paging/cursor/PagedReferenceImpl.java | 4 +-
.../cursor/impl/PageCursorProviderImpl.java | 4 +-
.../cursor/impl/PageSubscriptionImpl.java | 4 +-
.../journal/AbstractJournalStorageManager.java | 4 +-
.../impl/journal/JournalStorageManager.java | 2 +-
.../impl/journal/LargeServerMessageImpl.java | 2 +-
.../impl/journal/LargeServerMessageInSync.java | 2 +-
.../core/ServerSessionPacketHandler.java | 2 +-
.../core/remoting/impl/invm/InVMAcceptor.java | 3 +-
.../core/remoting/impl/netty/NettyAcceptor.java | 2 +-
.../server/impl/RemotingServiceImpl.java | 2 +-
.../core/replication/ReplicationManager.java | 2 +-
.../core/server/ActiveMQServerLogger.java | 260 ++++++++++++++++++-
.../core/server/cluster/BackupManager.java | 2 +-
.../core/server/cluster/ClusterManager.java | 4 +-
.../server/cluster/ha/ColocatedHAManager.java | 2 +-
.../cluster/impl/ClusterConnectionImpl.java | 4 +-
.../core/server/cluster/impl/Redistributor.java | 6 +-
.../core/server/impl/ActiveMQServerImpl.java | 10 +-
.../core/server/impl/ColocatedActivation.java | 4 +-
.../impl/LegacyLDAPSecuritySettingPlugin.java | 6 +-
.../artemis/core/server/impl/QueueImpl.java | 20 +-
.../artemis/core/server/impl/RefsOperation.java | 4 +-
.../core/server/impl/ScaleDownHandler.java | 2 +-
.../core/server/impl/ServerConsumerImpl.java | 2 +-
.../core/server/impl/ServerSessionImpl.java | 14 +-
.../impl/SharedStoreBackupActivation.java | 5 +-
.../server/impl/TransientQueueManagerImpl.java | 2 +-
.../management/impl/ManagementServiceImpl.java | 2 +-
.../core/server/reload/ReloadManagerImpl.java | 2 +-
.../core/transaction/impl/TransactionImpl.java | 2 +-
.../core/protocol/AbstractProtocolManager.java | 2 +-
.../security/ActiveMQJAASSecurityManager.java | 5 +-
.../spi/core/security/jaas/LDAPLoginModule.java | 4 +-
.../security/jaas/ReloadableProperties.java | 2 +-
36 files changed, 328 insertions(+), 76 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/config/impl/ConfigurationImpl.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/config/impl/ConfigurationImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/config/impl/ConfigurationImpl.java
index ef11171..ff68f15 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/config/impl/ConfigurationImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/config/impl/ConfigurationImpl.java
@@ -918,7 +918,7 @@ public class ConfigurationImpl implements Configuration, Serializable {
@Override
@Deprecated
public ConfigurationImpl setWildcardRoutingEnabled(final boolean enabled) {
- logger.info("Usage of wildcardRoutingEnabled configuration property is deprecated, please use wildCardConfiguration.routingEnabled instead");
+ ActiveMQServerLogger.LOGGER.deprecatedWildcardRoutingEnabled();
wildcardConfiguration.setRoutingEnabled(enabled);
return this;
}
@@ -1513,8 +1513,7 @@ public class ConfigurationImpl implements Configuration, Serializable {
TransportConfiguration connector = getConnectorConfigurations().get(connectorName);
if (connector == null) {
- ActiveMQServerLogger.LOGGER.warn("bridgeNoConnector(connectorName)");
-
+ ActiveMQServerLogger.LOGGER.connectionConfigurationIsNull(connectorName == null ? "null" : connectorName);
return null;
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/cursor/PagedReferenceImpl.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/cursor/PagedReferenceImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/cursor/PagedReferenceImpl.java
index cd4f70a..25874f0 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/cursor/PagedReferenceImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/cursor/PagedReferenceImpl.java
@@ -118,7 +118,7 @@ public class PagedReferenceImpl implements PagedReference {
try {
messageEstimate = getMessage().getMemoryEstimate();
} catch (Throwable e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.errorCalculateMessageMemoryEstimate(e);
}
}
return messageEstimate;
@@ -136,7 +136,7 @@ public class PagedReferenceImpl implements PagedReference {
Message msg = getMessage();
return msg.getScheduledDeliveryTime();
} catch (Throwable e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.errorCalculateScheduledDeliveryTime(e);
return 0L;
}
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/cursor/impl/PageCursorProviderImpl.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/cursor/impl/PageCursorProviderImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/cursor/impl/PageCursorProviderImpl.java
index c1e1761..2030d25 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/cursor/impl/PageCursorProviderImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/cursor/impl/PageCursorProviderImpl.java
@@ -313,14 +313,14 @@ public class PageCursorProviderImpl implements PageCursorProvider {
try {
sub.onPageModeCleared(tx);
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn("Error while cleaning paging on queue " + sub.getQueue().getName(), e);
+ ActiveMQServerLogger.LOGGER.errorCleaningPagingOnQueue(e, sub.getQueue().getName().toString());
}
}
try {
tx.commit();
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn("Error while cleaning page, during the commit", e);
+ ActiveMQServerLogger.LOGGER.errorCleaningPagingDuringCommit(e);
}
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/cursor/impl/PageSubscriptionImpl.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/cursor/impl/PageSubscriptionImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/cursor/impl/PageSubscriptionImpl.java
index fa2c748..a674935 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/cursor/impl/PageSubscriptionImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/paging/cursor/impl/PageSubscriptionImpl.java
@@ -725,7 +725,7 @@ final class PageSubscriptionImpl implements PageSubscription {
try {
store.deletePageComplete(completeInfo.getRecordID());
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn("Error while deleting page-complete-record", e);
+ ActiveMQServerLogger.LOGGER.errorDeletingPageCompleteRecord(e);
}
info.setCompleteInfo(null);
}
@@ -734,7 +734,7 @@ final class PageSubscriptionImpl implements PageSubscription {
try {
store.deleteCursorAcknowledge(deleteInfo.getRecordID());
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn("Error while deleting page-complete-record", e);
+ ActiveMQServerLogger.LOGGER.errorDeletingPageCompleteRecord(e);
}
}
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/AbstractJournalStorageManager.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/AbstractJournalStorageManager.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/AbstractJournalStorageManager.java
index f757f4b..1c5a4c3 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/AbstractJournalStorageManager.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/AbstractJournalStorageManager.java
@@ -1437,12 +1437,12 @@ public abstract class AbstractJournalStorageManager extends CriticalComponentImp
queueBindingEncoding.addQueueStatusEncoding(statusEncoding);
} else {
// unlikely to happen, so I didn't bother about the Logger method
- logger.info("There is no queue with ID " + statusEncoding.queueID + ", deleting record " + statusEncoding.getId());
+ ActiveMQServerLogger.LOGGER.infoNoQueueWithID(statusEncoding.queueID, statusEncoding.getId());
this.deleteQueueStatus(statusEncoding.getId());
}
} else {
// unlikely to happen
- logger.warn("Invalid record type " + rec, new Exception("invalid record type " + rec));
+ ActiveMQServerLogger.LOGGER.invalidRecordType(rec, new Exception("invalid record type " + rec));
}
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/JournalStorageManager.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/JournalStorageManager.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/JournalStorageManager.java
index 2341a66..0bd4df3 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/JournalStorageManager.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/JournalStorageManager.java
@@ -604,7 +604,7 @@ public class JournalStorageManager extends AbstractJournalStorageManager {
storageManagerLock.writeLock().unlock();
}
} catch (Exception e) {
- logger.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableToStartReplication(e);
stopReplication();
throw e;
} finally {
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/LargeServerMessageImpl.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/LargeServerMessageImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/LargeServerMessageImpl.java
index b8236af..0a2d3b2 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/LargeServerMessageImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/LargeServerMessageImpl.java
@@ -439,7 +439,7 @@ public final class LargeServerMessageImpl extends CoreMessage implements LargeSe
try {
bodySize = file.size();
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableToCalculateFileSize(e);
}
}
return bodySize;
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/LargeServerMessageInSync.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/LargeServerMessageInSync.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/LargeServerMessageInSync.java
index 66ccd8c..509f9d7 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/LargeServerMessageInSync.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/persistence/impl/journal/LargeServerMessageInSync.java
@@ -69,7 +69,7 @@ public final class LargeServerMessageInSync implements ReplicatedLargeMessage {
}
}
} catch (Throwable e) {
- logger.warn("Error while sincing data on largeMessageInSync::" + mainLM);
+ ActiveMQServerLogger.LOGGER.errorWhileSyncingData(mainLM.toString(), e);
}
if (logger.isTraceEnabled()) {
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/protocol/core/ServerSessionPacketHandler.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/protocol/core/ServerSessionPacketHandler.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/protocol/core/ServerSessionPacketHandler.java
index e89dee0..8f3c5be 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/protocol/core/ServerSessionPacketHandler.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/protocol/core/ServerSessionPacketHandler.java
@@ -819,7 +819,7 @@ public class ServerSessionPacketHandler implements ChannelHandler {
ServerSession session) {
session.markTXFailed(t);
if (requiresResponse) {
- ActiveMQServerLogger.LOGGER.warn("Sending unexpected exception to the client", t);
+ ActiveMQServerLogger.LOGGER.sendingUnexpectedExceptionToClient(t);
ActiveMQException activeMQInternalErrorException = new ActiveMQInternalErrorException();
activeMQInternalErrorException.initCause(t);
response = new ActiveMQExceptionMessage(activeMQInternalErrorException);
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/remoting/impl/invm/InVMAcceptor.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/remoting/impl/invm/InVMAcceptor.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/remoting/impl/invm/InVMAcceptor.java
index 8c2bee5..a2fdeb0 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/remoting/impl/invm/InVMAcceptor.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/remoting/impl/invm/InVMAcceptor.java
@@ -29,6 +29,7 @@ import org.apache.activemq.artemis.core.remoting.impl.AbstractAcceptor;
import org.apache.activemq.artemis.core.security.ActiveMQPrincipal;
import org.apache.activemq.artemis.core.server.ActiveMQComponent;
import org.apache.activemq.artemis.core.server.ActiveMQMessageBundle;
+import org.apache.activemq.artemis.core.server.ActiveMQServerLogger;
import org.apache.activemq.artemis.core.server.cluster.ClusterConnection;
import org.apache.activemq.artemis.core.server.management.Notification;
import org.apache.activemq.artemis.core.server.management.NotificationService;
@@ -170,7 +171,7 @@ public final class InVMAcceptor extends AbstractAcceptor {
try {
notificationService.sendNotification(notification);
} catch (Exception e) {
- logger.warn("failed to send notification", e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.failedToSendNotification(e);
}
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/remoting/impl/netty/NettyAcceptor.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/remoting/impl/netty/NettyAcceptor.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/remoting/impl/netty/NettyAcceptor.java
index 88881aa..6141d6c 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/remoting/impl/netty/NettyAcceptor.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/remoting/impl/netty/NettyAcceptor.java
@@ -613,7 +613,7 @@ public class NettyAcceptor extends AbstractAcceptor {
try {
notificationService.sendNotification(notification);
} catch (Exception e) {
- logger.warn("failed to send notification", e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.failedToSendNotification(e);
}
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/remoting/server/impl/RemotingServiceImpl.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/remoting/server/impl/RemotingServiceImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/remoting/server/impl/RemotingServiceImpl.java
index caccee3..94c776c 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/remoting/server/impl/RemotingServiceImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/remoting/server/impl/RemotingServiceImpl.java
@@ -714,7 +714,7 @@ public class RemotingServiceImpl implements RemotingService, ServerConnectionLif
// failure detection could be affected
conn.flush();
} catch (Throwable e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.failedToFlushOutstandingDataFromTheConnection(e);
}
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/replication/ReplicationManager.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/replication/ReplicationManager.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/replication/ReplicationManager.java
index 1dbacc9..3642272 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/replication/ReplicationManager.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/replication/ReplicationManager.java
@@ -402,7 +402,7 @@ public final class ReplicationManager implements ActiveMQComponent {
OperationContext ctx = pendingTokens.poll();
if (ctx == null) {
- logger.warn("Missing replication token on queue");
+ ActiveMQServerLogger.LOGGER.missingReplicationTokenOnQueue();
return;
}
ctx.replicationDone();
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/ActiveMQServerLogger.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/ActiveMQServerLogger.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/ActiveMQServerLogger.java
index 2ff784c..83ff12e 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/ActiveMQServerLogger.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/ActiveMQServerLogger.java
@@ -31,6 +31,7 @@ package org.apache.activemq.artemis.core.server;
* so an INFO message would be 101000 to 101999
*/
+import javax.naming.NamingException;
import javax.transaction.xa.Xid;
import java.io.File;
import java.net.SocketAddress;
@@ -394,6 +395,38 @@ public interface ActiveMQServerLogger extends BasicLogger {
@Message(id = 221071, value = "Failing over based on quorum vote results.", format = Message.Format.MESSAGE_FORMAT)
void failingOverBasedOnQuorumVoteResults();
+ @LogMessage(level = Logger.Level.INFO)
+ @Message(id = 221072, value = "Can't find roles for the subject.", format = Message.Format.MESSAGE_FORMAT)
+ void failedToFindRolesForTheSubject(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.INFO)
+ @Message(id = 221073, value = "Can't add role principal.", format = Message.Format.MESSAGE_FORMAT)
+ void failedAddRolePrincipal(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.INFO)
+ @Message(id = 221074, value = "Debug started : size = {0} bytes, messages = {1}", format = Message.Format.MESSAGE_FORMAT)
+ void debugStarted(Long globalSizeBytes, Long numberOfMessages);
+
+ @LogMessage(level = Logger.Level.INFO)
+ @Message(id = 221075, value = "Usage of wildcardRoutingEnabled configuration property is deprecated, please use wildCardConfiguration.enabled instead", format = Message.Format.MESSAGE_FORMAT)
+ void deprecatedWildcardRoutingEnabled();
+
+ @LogMessage(level = Logger.Level.INFO)
+ @Message(id = 221076, value = "{0}", format = Message.Format.MESSAGE_FORMAT)
+ void onDestroyConnectionWithSessionMetadata(String msg);
+
+ @LogMessage(level = Logger.Level.INFO)
+ @Message(id = 221077, value = "There is no queue with ID {0}, deleting record {1}", format = Message.Format.MESSAGE_FORMAT)
+ void infoNoQueueWithID(Long id, Long record);
+
+ @LogMessage(level = Logger.Level.INFO)
+ @Message(id = 221078, value = "Scaled down {0} messages total.", format = Message.Format.MESSAGE_FORMAT)
+ void infoScaledDownMessages(Long num);
+
+ @LogMessage(level = Logger.Level.INFO)
+ @Message(id = 221079, value = "Ignoring prepare on xid as already called : {0}", format = Message.Format.MESSAGE_FORMAT)
+ void ignoringPrepareOnXidAlreadyCalled(String xid);
+
@LogMessage(level = Logger.Level.WARN)
@Message(id = 222000, value = "ActiveMQServer is being finalized and has not been stopped. Please remember to stop the server before letting it go out of scope",
format = Message.Format.MESSAGE_FORMAT)
@@ -425,9 +458,6 @@ public interface ActiveMQServerLogger extends BasicLogger {
@LogMessage(level = Logger.Level.WARN)
@Message(id = 222008, value = "unable to restart server, please kill and restart manually", format = Message.Format.MESSAGE_FORMAT)
- void serverRestartWarning();
-
- @LogMessage(level = Logger.Level.WARN)
void serverRestartWarning(@Cause Exception e);
@LogMessage(level = Logger.Level.WARN)
@@ -1348,6 +1378,206 @@ public interface ActiveMQServerLogger extends BasicLogger {
@Message(id = 222218, value = "Server disconnecting: {0}", format = Message.Format.MESSAGE_FORMAT)
void disconnectCritical(String reason, @Cause Exception e);
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222219, value = "File {0} does not exist",
+ format = Message.Format.MESSAGE_FORMAT)
+ void fileDoesNotExist(String path);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222220, value = " Error while cleaning paging on queue {0}", format = Message.Format.MESSAGE_FORMAT)
+ void errorCleaningPagingOnQueue(@Cause Exception e, String queue);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222221, value = "Error while cleaning page, during the commit", format = Message.Format.MESSAGE_FORMAT)
+ void errorCleaningPagingDuringCommit(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222222, value = "Error while deleting page-complete-record", format = Message.Format.MESSAGE_FORMAT)
+ void errorDeletingPageCompleteRecord(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222223, value = "Failed to calculate message memory estimate", format = Message.Format.MESSAGE_FORMAT)
+ void errorCalculateMessageMemoryEstimate(@Cause Throwable e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222224, value = "Failed to calculate scheduled delivery time", format = Message.Format.MESSAGE_FORMAT)
+ void errorCalculateScheduledDeliveryTime(@Cause Throwable e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222225, value = "Sending unexpected exception to the client", format = Message.Format.MESSAGE_FORMAT)
+ void sendingUnexpectedExceptionToClient(@Cause Throwable e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222226, value = "Connection configuration is null for connectorName {0}", format = Message.Format.MESSAGE_FORMAT)
+ void connectionConfigurationIsNull(String connectorName);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222227, value = "Failed to process an event", format = Message.Format.MESSAGE_FORMAT)
+ void failedToProcessEvent(@Cause NamingException e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222228, value = "Missing replication token on queue", format = Message.Format.MESSAGE_FORMAT)
+ void missingReplicationTokenOnQueue();
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222229, value = "Failed to perform rollback", format = Message.Format.MESSAGE_FORMAT)
+ void failedToPerformRollback(@Cause IllegalStateException e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222230, value = "Failed to send notification", format = Message.Format.MESSAGE_FORMAT)
+ void failedToSendNotification(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222231, value = "Failed to flush outstanding data from the connection", format = Message.Format.MESSAGE_FORMAT)
+ void failedToFlushOutstandingDataFromTheConnection(@Cause Throwable e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222232, value = "Unable to acquire lock", format = Message.Format.MESSAGE_FORMAT)
+ void unableToAcquireLock(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222233, value = "Unable to destroy connection with session metadata", format = Message.Format.MESSAGE_FORMAT)
+ void unableDestroyConnectionWithSessionMetadata(@Cause Throwable e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222234, value = "Unable to deactivate a callback", format = Message.Format.MESSAGE_FORMAT)
+ void unableToDeactiveCallback(@Cause Throwable e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222235, value = "Unable to inject a monitor", format = Message.Format.MESSAGE_FORMAT)
+ void unableToInjectMonitor(@Cause Throwable e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222236, value = "Unable to flush deliveries", format = Message.Format.MESSAGE_FORMAT)
+ void unableToFlushDeliveries(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222237, value = "Unable to flush deliveries", format = Message.Format.MESSAGE_FORMAT)
+ void unableToCancelRedistributor(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222238, value = "Unable to commit transaction", format = Message.Format.MESSAGE_FORMAT)
+ void unableToCommitTransaction(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222239, value = "Unable to delete Queue status", format = Message.Format.MESSAGE_FORMAT)
+ void unableToDeleteQueueStatus(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222240, value = "Unable to pause a Queue", format = Message.Format.MESSAGE_FORMAT)
+ void unableToPauseQueue(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222241, value = "Unable to resume a Queue", format = Message.Format.MESSAGE_FORMAT)
+ void unableToResumeQueue(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222242, value = "Unable to obtain message priority, using default ", format = Message.Format.MESSAGE_FORMAT)
+ void unableToGetMessagePriority(@Cause Throwable e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222243, value = "Unable to extract GroupID from message", format = Message.Format.MESSAGE_FORMAT)
+ void unableToExtractGroupID(@Cause Throwable e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222244, value = "Unable to check if message expired", format = Message.Format.MESSAGE_FORMAT)
+ void unableToCheckIfMessageExpired(@Cause Throwable e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222245, value = "Unable to perform post acknowledge", format = Message.Format.MESSAGE_FORMAT)
+ void unableToPerformPostAcknowledge(@Cause Throwable e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222246, value = "Unable to rollback on close", format = Message.Format.MESSAGE_FORMAT)
+ void unableToRollbackOnClose(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222247, value = "Unable to close consumer", format = Message.Format.MESSAGE_FORMAT)
+ void unableToCloseConsumer(@Cause Throwable e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222248, value = "Unable to remove consumer", format = Message.Format.MESSAGE_FORMAT)
+ void unableToRemoveConsumer(@Cause Throwable e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222249, value = "Unable to rollback on TX timed out", format = Message.Format.MESSAGE_FORMAT)
+ void unableToRollbackOnTxTimedOut(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222250, value = "Unable to delete heuristic completion from storage manager", format = Message.Format.MESSAGE_FORMAT)
+ void unableToDeleteHeuristicCompletion(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222251, value = "Unable to start replication", format = Message.Format.MESSAGE_FORMAT)
+ void unableToStartReplication(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222252, value = "Unable to calculate file size", format = Message.Format.MESSAGE_FORMAT)
+ void unableToCalculateFileSize(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222253, value = "Error while syncing data on largeMessageInSync:: {0}", format = Message.Format.MESSAGE_FORMAT)
+ void errorWhileSyncingData(String target, @Cause Throwable e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222254, value = "Invalid record type {0}", format = Message.Format.MESSAGE_FORMAT)
+ void invalidRecordType(byte type, @Cause Throwable e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222255, value = "Unable to calculate file store usage", format = Message.Format.MESSAGE_FORMAT)
+ void unableToCalculateFileStoreUsage(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222256, value = "Failed to unregister acceptors", format = Message.Format.MESSAGE_FORMAT)
+ void failedToUnregisterAcceptors(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222257, value = "Failed to decrement message reference count", format = Message.Format.MESSAGE_FORMAT)
+ void failedToDecrementMessageReferenceCount(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222258, value = "Error on deleting queue {0}", format = Message.Format.MESSAGE_FORMAT)
+ void errorOnDeletingQueue(String queueName, @Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222259, value = "Failed to flush the executor", format = Message.Format.MESSAGE_FORMAT)
+ void failedToFlushExecutor(@Cause InterruptedException e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222260, value = "Failed to perform rollback", format = Message.Format.MESSAGE_FORMAT)
+ void failedToRollback(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222261, value = "Failed to activate a backup", format = Message.Format.MESSAGE_FORMAT)
+ void failedToActivateBackup(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222262, value = "Failed to stop cluster manager", format = Message.Format.MESSAGE_FORMAT)
+ void failedToStopClusterManager(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222263, value = "Failed to stop cluster connection", format = Message.Format.MESSAGE_FORMAT)
+ void failedToStopClusterConnection(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222264, value = "Failed to process message reference after rollback", format = Message.Format.MESSAGE_FORMAT)
+ void failedToProcessMessageReferenceAfterRollback(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222265, value = "Failed to finish delivery, unable to lock delivery", format = Message.Format.MESSAGE_FORMAT)
+ void failedToFinishDelivery(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222266, value = "Failed to send request to the node", format = Message.Format.MESSAGE_FORMAT)
+ void failedToSendRequestToNode(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222267, value = "Failed to disconnect bindings", format = Message.Format.MESSAGE_FORMAT)
+ void failedToDisconnectBindings(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.WARN)
+ @Message(id = 222268, value = "Failed to remove a record", format = Message.Format.MESSAGE_FORMAT)
+ void failedToRemoveRecord(@Cause Exception e);
@LogMessage(level = Logger.Level.ERROR)
@Message(id = 224000, value = "Failure in initialisation", format = Message.Format.MESSAGE_FORMAT)
@@ -1654,4 +1884,28 @@ public interface ActiveMQServerLogger extends BasicLogger {
@LogMessage(level = Logger.Level.WARN)
@Message(id = 224078, value = "The size of duplicate cache detection (<id_cache-size/>) appears to be too large {0}. It should be no greater than the number of messages that can be squeezed into conformation buffer (<confirmation-window-size/>) {1}.", format = Message.Format.MESSAGE_FORMAT)
void duplicateCacheSizeWarning(int idCacheSize, int confirmationWindowSize);
+
+ @LogMessage(level = Logger.Level.ERROR)
+ @Message(id = 224082, value = "Failed to invoke an interceptor", format = Message.Format.MESSAGE_FORMAT)
+ void failedToInvokeAninterceptor(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.ERROR)
+ @Message(id = 224083, value = "Failed to close context", format = Message.Format.MESSAGE_FORMAT)
+ void failedToCloseContext(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.ERROR)
+ @Message(id = 224084, value = "Failed to open context", format = Message.Format.MESSAGE_FORMAT)
+ void failedToOpenContext(@Cause Exception e);
+
+ @LogMessage(level = Logger.Level.ERROR)
+ @Message(id = 224085, value = "Failed to load property {0}, reason: {1}", format = Message.Format.MESSAGE_FORMAT)
+ void failedToLoadProperty(@Cause Exception e, String key, String reason);
+
+ @LogMessage(level = Logger.Level.ERROR)
+ @Message(id = 224086, value = "Caught unexpected exception", format = Message.Format.MESSAGE_FORMAT)
+ void caughtUnexpectedException(@Cause NamingException e);
+
+ @LogMessage(level = Logger.Level.ERROR)
+ @Message(id = 224087, value = "Error announcing backup: backupServerLocator is null. {0}", format = Message.Format.MESSAGE_FORMAT)
+ void errorAnnouncingBackup(String backupManager);
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/BackupManager.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/BackupManager.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/BackupManager.java
index e1c4175..835cc1f 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/BackupManager.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/BackupManager.java
@@ -235,7 +235,7 @@ public class BackupManager implements ActiveMQComponent {
ServerLocatorInternal localBackupLocator = backupServerLocator;
if (localBackupLocator == null) {
if (!stopping)
- ActiveMQServerLogger.LOGGER.error("Error announcing backup: backupServerLocator is null. " + this);
+ ActiveMQServerLogger.LOGGER.errorAnnouncingBackup(this.toString());
return;
}
if (logger.isDebugEnabled()) {
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/ClusterManager.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/ClusterManager.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/ClusterManager.java
index 8077b28..4e8d77a 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/ClusterManager.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/ClusterManager.java
@@ -510,7 +510,7 @@ public final class ClusterManager implements ActiveMQComponent {
try {
manager.stop();
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.failedToStopClusterManager(e);
}
}
@@ -550,7 +550,7 @@ public final class ClusterManager implements ActiveMQComponent {
try {
clusterConnection.stop();
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.failedToStopClusterConnection(e);
}
}
clearClusterConnections();
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/ha/ColocatedHAManager.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/ha/ColocatedHAManager.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/ha/ColocatedHAManager.java
index 627d59a..c9d9e1f 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/ha/ColocatedHAManager.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/ha/ColocatedHAManager.java
@@ -71,7 +71,7 @@ public class ColocatedHAManager implements HAManager {
try {
activeMQServer.stop();
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.errorStoppingServer(e);
}
}
backupServers.clear();
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/impl/ClusterConnectionImpl.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/impl/ClusterConnectionImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/impl/ClusterConnectionImpl.java
index 2f1fe87..bcfb58d 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/impl/ClusterConnectionImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/impl/ClusterConnectionImpl.java
@@ -1484,7 +1484,7 @@ public final class ClusterConnectionImpl implements ClusterConnection, AfterConn
record.close();
}
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn(e);
+ ActiveMQServerLogger.LOGGER.failedToRemoveRecord(e);
}
}
@@ -1497,7 +1497,7 @@ public final class ClusterConnectionImpl implements ClusterConnection, AfterConn
record.disconnectBindings();
}
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.failedToDisconnectBindings(e);
}
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/impl/Redistributor.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/impl/Redistributor.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/impl/Redistributor.java
index eff8d67..cfb9eee 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/impl/Redistributor.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/impl/Redistributor.java
@@ -131,7 +131,7 @@ public class Redistributor implements Consumer {
boolean ok = pendingRuns.await(10000);
return ok;
} catch (InterruptedException e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.failedToFlushExecutor(e);
return false;
}
}
@@ -181,9 +181,7 @@ public class Redistributor implements Consumer {
tx.rollback();
} catch (Exception e2) {
// Nothing much we can do now
-
- // TODO log
- ActiveMQServerLogger.LOGGER.warn(e2.getMessage(), e2);
+ ActiveMQServerLogger.LOGGER.failedToRollback(e2);
}
}
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ActiveMQServerImpl.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ActiveMQServerImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ActiveMQServerImpl.java
index 0663efe..0e38732 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ActiveMQServerImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ActiveMQServerImpl.java
@@ -680,7 +680,7 @@ public class ActiveMQServerImpl implements ActiveMQServer {
try {
activationLock.acquire();
} catch (Exception e) {
- logger.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableToAcquireLock(e);
}
}
@@ -1306,7 +1306,7 @@ public class ActiveMQServerImpl implements ActiveMQServer {
sessions.remove(session.getName());
}
} catch (Throwable e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableDestroyConnectionWithSessionMetadata(e);
}
}
@@ -1319,7 +1319,7 @@ public class ActiveMQServerImpl implements ActiveMQServer {
return operationsExecuted.toString();
} finally {
// This operation is critical for the knowledge of the admin, so we need to add info logs for later knowledge
- ActiveMQServerLogger.LOGGER.info(operationsExecuted.toString());
+ ActiveMQServerLogger.LOGGER.onDestroyConnectionWithSessionMetadata(operationsExecuted.toString());
}
}
@@ -2165,7 +2165,7 @@ public class ActiveMQServerImpl implements ActiveMQServer {
} catch (Throwable e) {
// https://bugzilla.redhat.com/show_bug.cgi?id=1009530:
// we won't interrupt the shutdown sequence because of a failed callback here
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableToDeactiveCallback(e);
}
}
}
@@ -2410,7 +2410,7 @@ public class ActiveMQServerImpl implements ActiveMQServer {
try {
injectMonitor(new FileStoreMonitor(getScheduledPool(), executorFactory.getExecutor(), configuration.getDiskScanPeriod(), TimeUnit.MILLISECONDS, configuration.getMaxDiskUsage() / 100f, shutdownOnCriticalIO));
} catch (Exception e) {
- logger.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableToInjectMonitor(e);
}
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ColocatedActivation.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ColocatedActivation.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ColocatedActivation.java
index aa75775..a125d82 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ColocatedActivation.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ColocatedActivation.java
@@ -126,7 +126,7 @@ public class ColocatedActivation extends LiveActivation {
try {
started = colocatedHAManager.activateBackup(backupRequestMessage.getBackupSize(), backupRequestMessage.getJournalDirectory(), backupRequestMessage.getBindingsDirectory(), backupRequestMessage.getLargeMessagesDirectory(), backupRequestMessage.getPagingDirectory(), backupRequestMessage.getNodeID());
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.failedToActivateBackup(e);
}
channel.send(new BackupResponseMessage(started));
} else if (activationChannelHandler != null) {
@@ -220,7 +220,7 @@ public class ColocatedActivation extends LiveActivation {
}, colocatedPolicy.getBackupRequestRetryInterval(), TimeUnit.MILLISECONDS);
}
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.failedToSendRequestToNode(e);
}
} else {
nodes.clear();
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/LegacyLDAPSecuritySettingPlugin.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/LegacyLDAPSecuritySettingPlugin.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/LegacyLDAPSecuritySettingPlugin.java
index 9c78c38..6aa762e 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/LegacyLDAPSecuritySettingPlugin.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/LegacyLDAPSecuritySettingPlugin.java
@@ -412,7 +412,7 @@ public class LegacyLDAPSecuritySettingPlugin implements SecuritySettingPlugin {
}
}
} catch (NamingException e) {
- logger.warn("Failed to process an event", e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.failedToProcessEvent(e);
}
}
@@ -464,7 +464,7 @@ public class LegacyLDAPSecuritySettingPlugin implements SecuritySettingPlugin {
}
}
} catch (NamingException e) {
- logger.warn("Failed to process an event", e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.failedToProcessEvent(e);
}
}
@@ -492,7 +492,7 @@ public class LegacyLDAPSecuritySettingPlugin implements SecuritySettingPlugin {
*/
public void namingExceptionThrown(NamingExceptionEvent namingExceptionEvent) {
context = null;
- ActiveMQServerLogger.LOGGER.error("Caught unexpected exception.", namingExceptionEvent.getException());
+ ActiveMQServerLogger.LOGGER.caughtUnexpectedException(namingExceptionEvent.getException());
}
protected class LDAPNamespaceChangeListener implements NamespaceChangeListener, ObjectChangeListener {
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/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 1f1f4fd..bd6b8aa 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
@@ -724,7 +724,7 @@ public class QueueImpl extends CriticalComponentImpl implements Queue {
return false;
}
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableToFlushDeliveries(e);
return false;
}
}
@@ -770,7 +770,7 @@ public class QueueImpl extends CriticalComponentImpl implements Queue {
cancelRedistributor();
} catch (Exception e) {
// nothing that could be done anyway.. just logging
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableToCancelRedistributor(e);
}
}
});
@@ -1691,7 +1691,7 @@ public class QueueImpl extends CriticalComponentImpl implements Queue {
tx.commit();
}
} catch (Exception e) {
- logger.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableToCommitTransaction(e);
}
// If empty we need to schedule depaging to make sure we would depage expired messages as well
@@ -1923,7 +1923,7 @@ public class QueueImpl extends CriticalComponentImpl implements Queue {
try {
storageManager.deleteQueueStatus(pauseStatusRecord);
} catch (Exception e) {
- logger.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableToDeleteQueueStatus(e);
}
}
this.pauseStatusRecord = recordID;
@@ -1940,7 +1940,7 @@ public class QueueImpl extends CriticalComponentImpl implements Queue {
pauseStatusRecord = storageManager.storeQueueStatus(this.id, QueueStatus.PAUSED);
}
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableToPauseQueue(e);
}
paused = true;
}
@@ -1953,7 +1953,7 @@ public class QueueImpl extends CriticalComponentImpl implements Queue {
try {
storageManager.deleteQueueStatus(pauseStatusRecord);
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableToResumeQueue(e);
}
pauseStatusRecord = -1;
}
@@ -2043,7 +2043,7 @@ public class QueueImpl extends CriticalComponentImpl implements Queue {
try {
return ref.getMessage().getPriority();
} catch (Throwable e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableToGetMessagePriority(e);
return 4; // the default one in case of failure
}
}
@@ -2274,7 +2274,7 @@ public class QueueImpl extends CriticalComponentImpl implements Queue {
// But we don't use the groupID on internal queues (clustered queues) otherwise the group map would leak forever
return ref.getMessage().getGroupID();
} catch (Throwable e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableToExtractGroupID(e);
return null;
}
}
@@ -2791,7 +2791,7 @@ public class QueueImpl extends CriticalComponentImpl implements Queue {
return false;
}
} catch (Throwable e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableToCheckIfMessageExpired(e);
return false;
}
}
@@ -2844,7 +2844,7 @@ public class QueueImpl extends CriticalComponentImpl implements Queue {
try {
message = ref.getMessage();
} catch (Throwable e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableToPerformPostAcknowledge(e);
message = null;
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/RefsOperation.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/RefsOperation.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/RefsOperation.java
index c5935d7..6bf69ed 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/RefsOperation.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/RefsOperation.java
@@ -129,7 +129,7 @@ public class RefsOperation extends TransactionOperationAbstract {
}
ackedTX.commit(true);
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.failedToProcessMessageReferenceAfterRollback(e);
}
}
}
@@ -171,7 +171,7 @@ public class RefsOperation extends TransactionOperationAbstract {
// This could happen on after commit, since the page could be deleted on file earlier by another thread
logger.debug(e);
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.failedToDecrementMessageReferenceCount(e);
}
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ScaleDownHandler.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ScaleDownHandler.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ScaleDownHandler.java
index e921cb9..49117f3 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ScaleDownHandler.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ScaleDownHandler.java
@@ -94,7 +94,7 @@ public class ScaleDownHandler {
ClusterControl clusterControl = clusterController.connectToNodeInCluster((ClientSessionFactoryInternal) sessionFactory);
clusterControl.authorize();
long num = scaleDownMessages(sessionFactory, targetNodeId, clusterControl.getClusterUser(), clusterControl.getClusterPassword());
- ActiveMQServerLogger.LOGGER.info("Scaled down " + num + " messages total.");
+ ActiveMQServerLogger.LOGGER.infoScaledDownMessages(num);
scaleDownTransactions(sessionFactory, resourceManager, clusterControl.getClusterUser(), clusterControl.getClusterPassword());
scaleDownDuplicateIDs(duplicateIDMap, sessionFactory, managementAddress, clusterControl.getClusterUser(), clusterControl.getClusterPassword());
clusterControl.announceScaleDown(new SimpleString(this.targetNodeId), nodeManager.getNodeId());
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerConsumerImpl.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerConsumerImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerConsumerImpl.java
index 98015e1..edd15ce 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerConsumerImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerConsumerImpl.java
@@ -690,7 +690,7 @@ public class ServerConsumerImpl implements ServerConsumer, ReadyListener {
}
return true;
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.failedToFinishDelivery(e);
return false;
}
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerSessionImpl.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerSessionImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerSessionImpl.java
index 4d28fc7..fd96415 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerSessionImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerSessionImpl.java
@@ -365,7 +365,7 @@ public class ServerSessionImpl implements ServerSession, FailureListener {
try {
rollback(failed, false);
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableToRollbackOnClose(e);
}
}
}
@@ -378,11 +378,11 @@ public class ServerSessionImpl implements ServerSession, FailureListener {
try {
consumer.close(failed);
} catch (Throwable e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableToCloseConsumer(e);
try {
consumer.removeItself();
} catch (Throwable e2) {
- ActiveMQServerLogger.LOGGER.warn(e2.getMessage(), e2);
+ ActiveMQServerLogger.LOGGER.unableToRemoveConsumer(e2);
}
}
}
@@ -998,7 +998,7 @@ public class ServerSessionImpl implements ServerSession, FailureListener {
try {
storageManager.deleteHeuristicCompletion(id);
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableToDeleteHeuristicCompletion(e);
throw new ActiveMQXAException(XAException.XAER_RMFAIL);
}
} else {
@@ -1078,7 +1078,7 @@ public class ServerSessionImpl implements ServerSession, FailureListener {
// at this point we would be better on rolling back this session as a way to prevent consumers from holding their messages
this.rollback(false);
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.unableToRollbackOnTxTimedOut(e);
}
throw new ActiveMQXAException(XAException.XAER_NOTA, "Cannot find xid in resource manager: " + xid);
@@ -1200,7 +1200,7 @@ public class ServerSessionImpl implements ServerSession, FailureListener {
if (theTx.getState() == Transaction.State.SUSPENDED) {
throw new ActiveMQXAException(XAException.XAER_PROTO, "Cannot prepare transaction, it is suspended " + xid);
} else if (theTx.getState() == Transaction.State.PREPARED) {
- ActiveMQServerLogger.LOGGER.info("ignoring prepare on xid as already called :" + xid);
+ ActiveMQServerLogger.LOGGER.ignoringPrepareOnXidAlreadyCalled(xid.toString());
} else {
theTx.prepare();
}
@@ -1243,7 +1243,7 @@ public class ServerSessionImpl implements ServerSession, FailureListener {
ActiveMQServerLogger.LOGGER.errorCompletingContext(new Exception("warning"));
}
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.errorCompletingContext(e);
}
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/SharedStoreBackupActivation.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/SharedStoreBackupActivation.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/SharedStoreBackupActivation.java
index a955f70..913cc7b 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/SharedStoreBackupActivation.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/SharedStoreBackupActivation.java
@@ -103,7 +103,7 @@ public final class SharedStoreBackupActivation extends Activation {
activeMQServer.start();
}
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.serverRestartWarning();
+ ActiveMQServerLogger.LOGGER.serverRestartWarning(e);
}
}
});
@@ -227,8 +227,7 @@ public final class SharedStoreBackupActivation extends Activation {
activeMQServer.start();
}
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.warn(e.getMessage(), e);
- ActiveMQServerLogger.LOGGER.serverRestartWarning();
+ ActiveMQServerLogger.LOGGER.serverRestartWarning(e);
}
}
});
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/TransientQueueManagerImpl.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/TransientQueueManagerImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/TransientQueueManagerImpl.java
index a8da6eb..125c9fe 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/TransientQueueManagerImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/TransientQueueManagerImpl.java
@@ -43,7 +43,7 @@ public class TransientQueueManagerImpl implements TransientQueueManager {
try {
server.destroyQueue(queueName, null, false);
} catch (ActiveMQException e) {
- ActiveMQServerLogger.LOGGER.warn("Error on deleting queue " + queueName + ", " + e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.errorOnDeletingQueue(queueName.toString(), e);
}
} catch (Exception e) {
ActiveMQServerLogger.LOGGER.errorRemovingTempQueue(e, queueName);
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/management/impl/ManagementServiceImpl.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/management/impl/ManagementServiceImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/management/impl/ManagementServiceImpl.java
index bb9fdb3..e94e40b 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/management/impl/ManagementServiceImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/management/impl/ManagementServiceImpl.java
@@ -304,7 +304,7 @@ public class ManagementServiceImpl implements ManagementService {
try {
unregisterAcceptor(name);
} catch (Exception e) {
- logger.warn("Failed to unregister acceptors", e.getMessage(), e);
+ ActiveMQServerLogger.LOGGER.failedToUnregisterAcceptors(e);
}
}
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/reload/ReloadManagerImpl.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/reload/ReloadManagerImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/reload/ReloadManagerImpl.java
index 8dfc3fe..62ad093 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/reload/ReloadManagerImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/reload/ReloadManagerImpl.java
@@ -102,7 +102,7 @@ public class ReloadManagerImpl extends ActiveMQScheduledComponent implements Rel
}
if (!file.exists()) {
- logger.warn("File " + file + " does not exist");
+ ActiveMQServerLogger.LOGGER.fileDoesNotExist(file.toString());
}
this.lastModified = file.lastModified();
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/core/transaction/impl/TransactionImpl.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/transaction/impl/TransactionImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/transaction/impl/TransactionImpl.java
index cc2fa22..e3a0904 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/transaction/impl/TransactionImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/transaction/impl/TransactionImpl.java
@@ -378,7 +378,7 @@ public class TransactionImpl implements Transaction {
} catch (IllegalStateException e) {
// Something happened before and the TX didn't make to the Journal / Storage
// We will like to execute afterRollback and clear anything pending
- ActiveMQServerLogger.LOGGER.warn(e);
+ ActiveMQServerLogger.LOGGER.failedToPerformRollback(e);
}
// We want to make sure that nothing else gets done after the commit is issued
// this will eliminate any possibility or races
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/protocol/AbstractProtocolManager.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/protocol/AbstractProtocolManager.java b/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/protocol/AbstractProtocolManager.java
index b07a8bd..aaedecd 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/protocol/AbstractProtocolManager.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/protocol/AbstractProtocolManager.java
@@ -40,7 +40,7 @@ public abstract class AbstractProtocolManager<P, I extends BaseInterceptor<P>, C
break;
}
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.error(e);
+ ActiveMQServerLogger.LOGGER.failedToInvokeAninterceptor(e);
}
}
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/security/ActiveMQJAASSecurityManager.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/security/ActiveMQJAASSecurityManager.java b/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/security/ActiveMQJAASSecurityManager.java
index aaaec82..1f4b5f3 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/security/ActiveMQJAASSecurityManager.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/security/ActiveMQJAASSecurityManager.java
@@ -29,6 +29,7 @@ import java.util.Set;
import org.apache.activemq.artemis.core.config.impl.SecurityConfiguration;
import org.apache.activemq.artemis.core.security.CheckType;
import org.apache.activemq.artemis.core.security.Role;
+import org.apache.activemq.artemis.core.server.ActiveMQServerLogger;
import org.apache.activemq.artemis.spi.core.protocol.RemotingConnection;
import org.apache.activemq.artemis.spi.core.security.jaas.JaasCallbackHandler;
import org.apache.activemq.artemis.spi.core.security.jaas.RolePrincipal;
@@ -142,7 +143,7 @@ public class ActiveMQJAASSecurityManager implements ActiveMQSecurityManager3 {
try {
rolesForSubject.addAll(localSubject.getPrincipals(Class.forName(rolePrincipalClass).asSubclass(Principal.class)));
} catch (Exception e) {
- logger.info("Can't find roles for the subject", e);
+ ActiveMQServerLogger.LOGGER.failedToFindRolesForTheSubject(e);
}
if (rolesForSubject.size() > 0 && rolesWithPermission.size() > 0) {
Iterator<Principal> rolesForSubjectIter = rolesForSubject.iterator();
@@ -199,7 +200,7 @@ public class ActiveMQJAASSecurityManager implements ActiveMQSecurityManager3 {
try {
principals.add(createGroupPrincipal(role.getName(), rolePrincipalClass));
} catch (Exception e) {
- logger.info("Can't add role principal", e);
+ ActiveMQServerLogger.LOGGER.failedAddRolePrincipal(e);
}
}
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/security/jaas/LDAPLoginModule.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/security/jaas/LDAPLoginModule.java b/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/security/jaas/LDAPLoginModule.java
index fa40edc..ee2c980 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/security/jaas/LDAPLoginModule.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/security/jaas/LDAPLoginModule.java
@@ -193,7 +193,7 @@ public class LDAPLoginModule implements LoginModule {
context.close();
context = null;
} catch (Exception e) {
- ActiveMQServerLogger.LOGGER.error(e.toString());
+ ActiveMQServerLogger.LOGGER.failedToCloseContext(e);
}
}
}
@@ -576,7 +576,7 @@ public class LDAPLoginModule implements LoginModule {
} catch (NamingException e) {
closeContext();
- ActiveMQServerLogger.LOGGER.error(e.toString());
+ ActiveMQServerLogger.LOGGER.failedToOpenContext(e);
throw e;
}
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/7c433e52/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/security/jaas/ReloadableProperties.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/security/jaas/ReloadableProperties.java b/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/security/jaas/ReloadableProperties.java
index 66ba1a5..bed7d5f 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/security/jaas/ReloadableProperties.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/security/jaas/ReloadableProperties.java
@@ -57,7 +57,7 @@ public class ReloadableProperties {
logger.debug("Load of: " + key);
}
} catch (IOException e) {
- ActiveMQServerLogger.LOGGER.error("Failed to load: " + key + ", reason:" + e.getLocalizedMessage());
+ ActiveMQServerLogger.LOGGER.failedToLoadProperty(e, key.toString(), e.getLocalizedMessage());
if (key.isDebug()) {
logger.debug("Load of: " + key + ", failure exception" + e);
}