Skip to content

Comments

Delete explicit claim for log configuration file position in surefire…#8715

Merged
merlimat merged 1 commit intoapache:masterfrom
Renkai:remove_log_conf
Nov 27, 2020
Merged

Delete explicit claim for log configuration file position in surefire…#8715
merlimat merged 1 commit intoapache:masterfrom
Renkai:remove_log_conf

Conversation

@Renkai
Copy link
Contributor

@Renkai Renkai commented Nov 26, 2020

As this page https://logging.apache.org/log4j/2.x/manual/configuration.html said,
If we define log4j.configurationFile explicitly, it will become the highest priority to configure log related properties, that means any log configuration file in any module will be disabled, that will be the only active configuration file no matter we run some class or test some class in this project.

But we may need different configuration file for different module, and different configuration files in main directories and test directories.

For example, I may want to put a log4j2-test.xml in src/test/resources with loglevel debug, which only effective when I execute mvn test, but -Dlog4j.configurationFile=log4j2.xml make it impossible.

With -Dlog4j.configurationFile=log4j2.xml removed, log4j2.xml is still the default configuration file for a module if there is no other configuration file in corresponding modules, So I think it's OK to remove a explicit define.

… plugin

Signed-off-by: Renkai <gaelookair@gmail.com>
@Renkai
Copy link
Contributor Author

Renkai commented Nov 26, 2020

/pulsarbot run-failure-checks

@Renkai
Copy link
Contributor Author

Renkai commented Nov 26, 2020

/pulsarbot run-failure-checks

@merlimat merlimat merged commit ea5882a into apache:master Nov 27, 2020
@Renkai Renkai deleted the remove_log_conf branch November 28, 2020 01:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants