You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@heron.apache.org by GitBox <gi...@apache.org> on 2022/01/21 20:56:34 UTC

[GitHub] [incubator-heron] nicknezis opened a new issue #3762: Upgrade to Log4J 2.x

nicknezis opened a new issue #3762:
URL: https://github.com/apache/incubator-heron/issues/3762


   We should upgrade our Log4J dependency to 2.x. There is a migration guide that mentions an adapter that could help our 1.x code work with the newer log4j 2.17.1 dependency.
   
   https://logging.apache.org/log4j/2.x/manual/migration.html
   


-- 
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: commits-unsubscribe@heron.apache.org

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



[GitHub] [incubator-heron] surahman commented on issue #3762: Upgrade to Log4J 2.x

Posted by GitBox <gi...@apache.org>.
surahman commented on issue #3762:
URL: https://github.com/apache/incubator-heron/issues/3762#issuecomment-1018887773


   I believe it would be a fairly quick fix to employ the bridge adapter in **_Option 1_**.
   
   I had a look at **_Option 2_** in the list and I could not find references to most of the mentioned functions. There are similarly named logging functions for Python but the logging backend for them is different. The two areas in **_Option 2_** that will raise issues:
   
   * `String concatenation like logger.info("hi " + userName)`
   * `Calls to org.apache.log4j.Logger.setLevel() or similar methods`
   
   Because of the line length cap at 80 (why? this max line length is a legacy from the punched card era), we have to split line lengths. I mostly used format strings because they are more efficient but there were places in the code where there was the use of concatenation.
   
   We do set levels for logging, but this is mostly through a parameter to the log message function. I could not find a reference to the use of `setLevel` in the Java codebase.


-- 
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: commits-unsubscribe@heron.apache.org

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



[GitHub] [incubator-heron] nicknezis commented on issue #3762: Upgrade to Log4J 2.x

Posted by GitBox <gi...@apache.org>.
nicknezis commented on issue #3762:
URL: https://github.com/apache/incubator-heron/issues/3762#issuecomment-1073518147


   Resolved by #3791 


-- 
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: commits-unsubscribe@heron.apache.org

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



[GitHub] [incubator-heron] thinker0 commented on issue #3762: Upgrade to Log4J 2.x

Posted by GitBox <gi...@apache.org>.
thinker0 commented on issue #3762:
URL: https://github.com/apache/incubator-heron/issues/3762#issuecomment-1065820392


   Change log4j to slf4j of Logging
   https://github.com/apache/incubator-heron/pull/3791


-- 
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: commits-unsubscribe@heron.apache.org

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



[GitHub] [incubator-heron] thinker0 commented on issue #3762: Upgrade to Log4J 2.x

Posted by GitBox <gi...@apache.org>.
thinker0 commented on issue #3762:
URL: https://github.com/apache/incubator-heron/issues/3762#issuecomment-1065154057


   Wouldn't it be better to use slf4j-over-log4j, logback?


-- 
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: commits-unsubscribe@heron.apache.org

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



[GitHub] [incubator-heron] nicknezis closed issue #3762: Upgrade to Log4J 2.x

Posted by GitBox <gi...@apache.org>.
nicknezis closed issue #3762:
URL: https://github.com/apache/incubator-heron/issues/3762


   


-- 
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: commits-unsubscribe@heron.apache.org

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



[GitHub] [incubator-heron] thinker0 edited a comment on issue #3762: Upgrade to Log4J 2.x

Posted by GitBox <gi...@apache.org>.
thinker0 edited a comment on issue #3762:
URL: https://github.com/apache/incubator-heron/issues/3762#issuecomment-1065154057


   Wouldn't it be better to use slf4j-over-log4j, logback?
   
   without modifying the source.


-- 
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: commits-unsubscribe@heron.apache.org

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