You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by ro...@apache.org on 2022/05/16 15:28:37 UTC

[activemq-artemis] branch new-logging updated (39ad36719b -> 10a4bc1e02)

This is an automated email from the ASF dual-hosted git repository.

robbie pushed a change to branch new-logging
in repository https://gitbox.apache.org/repos/asf/activemq-artemis.git


    from 39ad36719b Placing getlogger back in place
     new 71bffc993a add missing license header
     new 10a4bc1e02 tweak variables for simplicity, make debug env variable align better with processor name/purpose

The 2 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:
 .../artemis/logprocessor/LogProcessor.java         | 23 +++++++++-------------
 .../artemis/logprocessor/annotation/GetLogger.java | 17 ++++++++++++++++
 2 files changed, 26 insertions(+), 14 deletions(-)


[activemq-artemis] 01/02: add missing license header

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

robbie pushed a commit to branch new-logging
in repository https://gitbox.apache.org/repos/asf/activemq-artemis.git

commit 71bffc993a15554107da372a0c4b024845df7320
Author: Robbie Gemmell <ro...@apache.org>
AuthorDate: Mon May 16 16:18:14 2022 +0100

    add missing license header
---
 .../artemis/logprocessor/annotation/GetLogger.java      | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

diff --git a/artemis-log-processor/src/main/java/org/apache/activemq/artemis/logprocessor/annotation/GetLogger.java b/artemis-log-processor/src/main/java/org/apache/activemq/artemis/logprocessor/annotation/GetLogger.java
index 87481209ae..aa675dc934 100644
--- a/artemis-log-processor/src/main/java/org/apache/activemq/artemis/logprocessor/annotation/GetLogger.java
+++ b/artemis-log-processor/src/main/java/org/apache/activemq/artemis/logprocessor/annotation/GetLogger.java
@@ -1,3 +1,20 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
 package org.apache.activemq.artemis.logprocessor.annotation;
 
 import java.lang.annotation.ElementType;


[activemq-artemis] 02/02: tweak variables for simplicity, make debug env variable align better with processor name/purpose

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

robbie pushed a commit to branch new-logging
in repository https://gitbox.apache.org/repos/asf/activemq-artemis.git

commit 10a4bc1e025060a8f67393ebf1107b423e29982d
Author: Robbie Gemmell <ro...@apache.org>
AuthorDate: Mon May 16 16:27:33 2022 +0100

    tweak variables for simplicity, make debug env variable align better with processor name/purpose
---
 .../artemis/logprocessor/LogProcessor.java         | 23 +++++++++-------------
 1 file changed, 9 insertions(+), 14 deletions(-)

diff --git a/artemis-log-processor/src/main/java/org/apache/activemq/artemis/logprocessor/LogProcessor.java b/artemis-log-processor/src/main/java/org/apache/activemq/artemis/logprocessor/LogProcessor.java
index d4b4f5c119..d9aacf6491 100644
--- a/artemis-log-processor/src/main/java/org/apache/activemq/artemis/logprocessor/LogProcessor.java
+++ b/artemis-log-processor/src/main/java/org/apache/activemq/artemis/logprocessor/LogProcessor.java
@@ -47,25 +47,20 @@ public class LogProcessor extends AbstractProcessor {
    private static final boolean DEBUG;
 
    static {
-      boolean activeResult;
-     {
-         try {
-            String activeEnv = System.getenv("ARTEMIS_PROCESSOR_DEBUG");
-            if (activeEnv != null) {
-               activeResult = Boolean.parseBoolean(activeEnv);
-            } else {
-               activeResult = false;
-            }
-         } catch (Exception e) {
-            e.printStackTrace();
-            activeResult = false;
+      boolean debugResult = false;
+      try {
+         String debugEnvVariable = System.getenv("ARTEMIS_LOG_PROCESSOR_DEBUG");
+         if (debugEnvVariable != null) {
+            debugResult = Boolean.parseBoolean(debugEnvVariable);
          }
+      } catch (Exception e) {
+         e.printStackTrace();
       }
-      DEBUG = activeResult;
+      DEBUG = debugResult;
    }
 
    /**
-    * define a system variable named ARTEMIS_PROCESSOR_DEBUG=true in order to see debug output
+    * define a system variable ARTEMIS_LOG_PROCESSOR_DEBUG=true in order to see debug output
     */
    protected static void debug(String debugMessage) {
       if (DEBUG) {