-
Notifications
You must be signed in to change notification settings - Fork 24.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Isolate console appender startup logic (#86243)
When bootstrapping Elasticsearch, the console appender is automatically added by our log4j config. However, there are some cases where we want to remove that appender. First, if --quiet is passed, we do not want to log anything to it. Second, if we are daemonizing, then we want to close the streams, so we need to remove it if it exists. Third, when huge guice/startup exceptions occur, we log these only to the ES log file, so we need to remove the appender temporarily. This commit moves the logic for mucking with the console appender into LogConfigurator. In the future this can be better isolated within logging, perhaps even avoiding creating the console appender to begin with when using --quiet, but for now this at least gets some log specific logic out of bootstrap. relates #85758
- Loading branch information
Showing
5 changed files
with
74 additions
and
54 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters