Skip to content

Commit

Permalink
Log status transitions to DOWN at error level, instead of warn
Browse files Browse the repository at this point in the history
I also dropped the transitions out of down to info, rather than warn, since
there isn't really anything to be concerned about on such a transition
  • Loading branch information
jamesmulcahy committed Aug 28, 2020
1 parent 25996d0 commit 50eecc2
Showing 1 changed file with 2 additions and 4 deletions.
Expand Up @@ -1349,10 +1349,8 @@ public String getId() {

@Override
public void notify(StatusChangeEvent statusChangeEvent) {
if (InstanceStatus.DOWN == statusChangeEvent.getStatus() ||
InstanceStatus.DOWN == statusChangeEvent.getPreviousStatus()) {
// log at warn level if DOWN was involved
logger.warn("Saw local status change event {}", statusChangeEvent);
if (statusChangeEvent.getStatus() == InstanceStatus.DOWN) {
logger.error("Saw local status change event {}", statusChangeEvent);
} else {
logger.info("Saw local status change event {}", statusChangeEvent);
}
Expand Down

0 comments on commit 50eecc2

Please sign in to comment.