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 2020/07/30 16:01:35 UTC
[activemq-artemis] branch master updated (e048328 -> 74f4500)
This is an automated email from the ASF dual-hosted git repository.
clebertsuconic pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/activemq-artemis.git.
from e048328 This closes #3227
new a45f383 ARTEMIS-2839 audit logging typo for resuming queue
new 4c79b25 ARTEMIS-2840 missing AddressControl audit logging
new 74f4500 This closes #3215
The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
.../apache/activemq/artemis/logs/AuditLogger.java | 35 +++++++++++++++++++++-
.../core/management/impl/AddressControlImpl.java | 16 ++++++++++
2 files changed, 50 insertions(+), 1 deletion(-)
[activemq-artemis] 02/03: ARTEMIS-2840 missing AddressControl audit
logging
Posted by cl...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
clebertsuconic pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/activemq-artemis.git
commit 4c79b25dc2cba58dc076e63d36dd4f8561057fd5
Author: Justin Bertram <jb...@apache.org>
AuthorDate: Thu Jul 9 11:33:47 2020 -0500
ARTEMIS-2840 missing AddressControl audit logging
---
.../apache/activemq/artemis/logs/AuditLogger.java | 33 ++++++++++++++++++++++
.../core/management/impl/AddressControlImpl.java | 16 +++++++++++
2 files changed, 49 insertions(+)
diff --git a/artemis-commons/src/main/java/org/apache/activemq/artemis/logs/AuditLogger.java b/artemis-commons/src/main/java/org/apache/activemq/artemis/logs/AuditLogger.java
index da32031..209402d 100644
--- a/artemis-commons/src/main/java/org/apache/activemq/artemis/logs/AuditLogger.java
+++ b/artemis-commons/src/main/java/org/apache/activemq/artemis/logs/AuditLogger.java
@@ -2695,5 +2695,38 @@ public interface AuditLogger extends BasicLogger {
@Message(id = 601730, value = "User {0} is enabling on target resource: {1} {2}", format = Message.Format.MESSAGE_FORMAT)
void enable(String user, Object source, Object... args);
+ static void pauseAddressSuccess(String queueName) {
+ RESOURCE_LOGGER.pauseAddressSuccess(getCaller(), queueName);
+ }
+
+ @LogMessage(level = Logger.Level.INFO)
+ @Message(id = 601731, value = "User {0} has paused address {1}", format = Message.Format.MESSAGE_FORMAT)
+ void pauseAddressSuccess(String user, String queueName);
+
+
+ static void pauseAddressFailure(String queueName) {
+ RESOURCE_LOGGER.pauseAddressFailure(getCaller(), queueName);
+ }
+
+ @LogMessage(level = Logger.Level.INFO)
+ @Message(id = 601732, value = "User {0} failed to pause address {1}", format = Message.Format.MESSAGE_FORMAT)
+ void pauseAddressFailure(String user, String queueName);
+
+ static void resumeAddressSuccess(String queueName) {
+ RESOURCE_LOGGER.resumeAddressSuccess(getCaller(), queueName);
+ }
+
+ @LogMessage(level = Logger.Level.INFO)
+ @Message(id = 601733, value = "User {0} has resumed address {1}", format = Message.Format.MESSAGE_FORMAT)
+ void resumeAddressSuccess(String user, String queueName);
+
+
+ static void resumeAddressFailure(String queueName) {
+ RESOURCE_LOGGER.resumeAddressFailure(getCaller(), queueName);
+ }
+
+ @LogMessage(level = Logger.Level.INFO)
+ @Message(id = 601734, value = "User {0} failed to resume address {1}", format = Message.Format.MESSAGE_FORMAT)
+ void resumeAddressFailure(String user, String queueName);
}
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/management/impl/AddressControlImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/management/impl/AddressControlImpl.java
index 9da31ab..166c01e 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/management/impl/AddressControlImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/management/impl/AddressControlImpl.java
@@ -413,6 +413,14 @@ public class AddressControlImpl extends AbstractControl implements AddressContro
addressInfo.setPostOffice(server.getPostOffice());
addressInfo.setStorageManager(server.getStorageManager());
addressInfo.pause(persist);
+ if (AuditLogger.isResourceLoggingEnabled()) {
+ AuditLogger.pauseAddressSuccess(addressInfo.getName().toString());
+ }
+ } catch (Exception e) {
+ if (AuditLogger.isResourceLoggingEnabled()) {
+ AuditLogger.pauseAddressFailure(addressInfo.getName().toString());
+ }
+ throw e;
} finally {
blockOnIO();
}
@@ -431,6 +439,14 @@ public class AddressControlImpl extends AbstractControl implements AddressContro
addressInfo.setPostOffice(server.getPostOffice());
addressInfo.setStorageManager(server.getStorageManager());
addressInfo.resume();
+ if (AuditLogger.isResourceLoggingEnabled()) {
+ AuditLogger.resumeAddressSuccess(addressInfo.getName().toString());
+ }
+ } catch (Exception e) {
+ if (AuditLogger.isResourceLoggingEnabled()) {
+ AuditLogger.resumeAddressFailure(addressInfo.getName().toString());
+ }
+ throw e;
} finally {
blockOnIO();
}
[activemq-artemis] 01/03: ARTEMIS-2839 audit logging typo for
resuming queue
Posted by cl...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
clebertsuconic pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/activemq-artemis.git
commit a45f383e1a5d5b3bc97a75995b6556ee2cbf81ec
Author: Justin Bertram <jb...@apache.org>
AuthorDate: Thu Jul 9 10:40:55 2020 -0500
ARTEMIS-2839 audit logging typo for resuming queue
---
.../src/main/java/org/apache/activemq/artemis/logs/AuditLogger.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/artemis-commons/src/main/java/org/apache/activemq/artemis/logs/AuditLogger.java b/artemis-commons/src/main/java/org/apache/activemq/artemis/logs/AuditLogger.java
index 2cab145..da32031 100644
--- a/artemis-commons/src/main/java/org/apache/activemq/artemis/logs/AuditLogger.java
+++ b/artemis-commons/src/main/java/org/apache/activemq/artemis/logs/AuditLogger.java
@@ -2619,7 +2619,7 @@ public interface AuditLogger extends BasicLogger {
}
@LogMessage(level = Logger.Level.INFO)
- @Message(id = 601721, value = "User {0} has paused queue {1}", format = Message.Format.MESSAGE_FORMAT)
+ @Message(id = 601721, value = "User {0} has resumed queue {1}", format = Message.Format.MESSAGE_FORMAT)
void resumeQueueSuccess(String user, String queueName);
[activemq-artemis] 03/03: This closes #3215
Posted by cl...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
clebertsuconic pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/activemq-artemis.git
commit 74f4500c044be0b4451fca12b8341d6a35a27b52
Merge: e048328 4c79b25
Author: Clebert Suconic <cl...@apache.org>
AuthorDate: Thu Jul 30 12:01:25 2020 -0400
This closes #3215
.../apache/activemq/artemis/logs/AuditLogger.java | 35 +++++++++++++++++++++-
.../core/management/impl/AddressControlImpl.java | 16 ++++++++++
2 files changed, 50 insertions(+), 1 deletion(-)