forked from elastic/rally
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
With this commit we disable automatic log rotation in Rally's out-of-the-box logging configuration because it can lead to race conditions (multiple processes attempting to rollover the log file). We also migrate existing configurations if possible (i.e. the user did not modify it) and provide an example configuration for `logrotate`. Closes elastic#539 Relates elastic#560
- Loading branch information
1 parent
cff5b2c
commit d6626f9
Showing
7 changed files
with
112 additions
and
5 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
{ | ||
"version": 1, | ||
"formatters": { | ||
"normal": { | ||
"format": "%(asctime)s,%(msecs)d %(actorAddress)s/PID:%(process)d %(name)s %(levelname)s %(message)s", | ||
"datefmt": "%Y-%m-%d %H:%M:%S", | ||
"()": "esrally.log.configure_utc_formatter" | ||
}, | ||
"profile": { | ||
"format": "%(asctime)s,%(msecs)d PID:%(process)d %(name)s %(levelname)s %(message)s", | ||
"datefmt": "%Y-%m-%d %H:%M:%S", | ||
"()": "esrally.log.configure_utc_formatter" | ||
} | ||
}, | ||
"filters": { | ||
"isActorLog": { | ||
"()": "thespian.director.ActorAddressLogFilter" | ||
} | ||
}, | ||
"handlers": { | ||
"rally_log_handler": { | ||
"class": "logging.handlers.TimedRotatingFileHandler", | ||
"filename": "${LOG_PATH}/rally.log", | ||
"utc": true, | ||
"when": "midnight", | ||
"backupCount": 14, | ||
"encoding": "UTF-8", | ||
"formatter": "normal", | ||
"filters": ["isActorLog"] | ||
}, | ||
"rally_profile_handler": { | ||
"class": "logging.FileHandler", | ||
"filename": "${LOG_PATH}/profile.log", | ||
"delay": true, | ||
"encoding": "UTF-8", | ||
"formatter": "profile" | ||
} | ||
}, | ||
"root": { | ||
"handlers": ["rally_log_handler"], | ||
"level": "INFO" | ||
}, | ||
"loggers": { | ||
"elasticsearch": { | ||
"handlers": ["rally_log_handler"], | ||
"level": "WARNING", | ||
"propagate": false | ||
}, | ||
"rally.profile": { | ||
"handlers": ["rally_profile_handler"], | ||
"level": "INFO", | ||
"propagate": false | ||
} | ||
} | ||
} |