Don't trigger aggregator fail if fine

This commit is contained in:
Joshua Boniface 2020-03-12 13:22:12 -04:00
parent ca5327b908
commit 0a367898a0
1 changed files with 1 additions and 0 deletions

View File

@ -455,6 +455,7 @@ class NodeInstance(object):
# Handle our current Patroni leader being us
if stdout and stdout.split('\n')[-1].split() == ["Error:", "Switchover", "target", "and", "source", "are", "the", "same."]:
self.logger.out('Failed to switch Patroni leader to ourselves; this is fine\n{}'.format(stdout), state='w')
patroni_failed = False
break
# Handle a failed switchover
elif stdout and (stdout.split('\n')[-1].split()[:2] == ["Switchover", "failed,"] or stdout.strip().split('\n')[-1].split()[:1] == ["Error"]):