jbertram commented on code in PR #5533:
URL: https://github.com/apache/activemq-artemis/pull/5533#discussion_r1972288652


##########
artemis-server/src/main/java/org/apache/activemq/artemis/core/management/impl/ActiveMQServerControlImpl.java:
##########
@@ -4721,6 +4722,22 @@ public long getAuthorizationFailureCount() {
       return server.getSecurityStore().getAuthorizationFailureCount();
    }
 
+   @Override
+   public void exportConfigAsProperties() throws Exception {
+      if (AuditLogger.isBaseLoggingEnabled()) {
+         AuditLogger.exportConfigAsProperties(this.server);
+      }
+
+      try (AutoCloseable lock = server.managementLock()) {
+         if (System.getProperty(TMP_DIR_SYSTEM_PROPERTY) == null) {
+            throw new IllegalStateException(TMP_DIR_SYSTEM_PROPERTY + " system 
property must be set");
+         } else {
+            File exportFileInTmp = new 
File(System.getProperty(TMP_DIR_SYSTEM_PROPERTY), CONFIG_AS_PROPERTIES_FILE);

Review Comment:
   Why not simply print the export and then users can do whatever they want 
with it (e.g. pipe it to a file, parse it in memory, etc.)?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: gitbox-unsubscr...@activemq.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscr...@activemq.apache.org
For additional commands, e-mail: gitbox-h...@activemq.apache.org
For further information, visit: https://activemq.apache.org/contact


Reply via email to