link3280 opened a new issue #1858:
URL: https://github.com/apache/incubator-kyuubi/issues/1858


   ### Code of Conduct
   
   - [X] I agree to follow this project's [Code of 
Conduct](https://www.apache.org/foundation/policies/conduct)
   
   
   ### Search before asking
   
   - [X] I have searched in the 
[issues](https://github.com/apache/incubator-kyuubi/issues?q=is%3Aissue) and 
found no similar issues.
   
   
   ### Describe the bug
   
   After https://github.com/apache/incubator-kyuubi/issues/1769 we migrated to 
log4j2. The new configuration files are named `log4j2.properties`, which is a 
good default for the production environment, but not the best choice for the 
test environment. 
   
   Because log4j2 will look for `log4j2-test.properties` before 
`log4j2.properties` (as described in `Automatic Configuration` section in 
https://logging.apache.org/log4j/2.x/manual/configuration.html), 
`log4j2-test.properties` in imported dependencies will have a higher priority 
than the configuration we provided. For example, Flink engine includes the test 
jar of Flink runtime, which contains a `log4j2-test.properties`, so our test 
log configuration is not effective.
   
   I think there're two approaches to solve this:
   
   - Rename all `log4j2 properties` in the directories to 
`log4j2-test.properties`.
   - Explicitly specify the configuration name by system property 
`log4j2.configurationFile`.
   
   I prefer the first one. 
   
   ### Affects Version(s)
   
   1.5.0
   
   ### Kyuubi Server Log Output
   
   _No response_
   
   ### Kyuubi Engine Log Output
   
   _No response_
   
   ### Kyuubi Server Configurations
   
   _No response_
   
   ### Kyuubi Engine Configurations
   
   _No response_
   
   ### Additional context
   
   _No response_
   
   ### Are you willing to submit PR?
   
   - [X] Yes I am willing to submit a PR!


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to