Don't trigger aggregator fail if fine
This commit is contained in:
parent
ca5327b908
commit
0a367898a0
|
@ -455,6 +455,7 @@ class NodeInstance(object):
|
||||||
# Handle our current Patroni leader being us
|
# Handle our current Patroni leader being us
|
||||||
if stdout and stdout.split('\n')[-1].split() == ["Error:", "Switchover", "target", "and", "source", "are", "the", "same."]:
|
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')
|
self.logger.out('Failed to switch Patroni leader to ourselves; this is fine\n{}'.format(stdout), state='w')
|
||||||
|
patroni_failed = False
|
||||||
break
|
break
|
||||||
# Handle a failed switchover
|
# Handle a failed switchover
|
||||||
elif stdout and (stdout.split('\n')[-1].split()[:2] == ["Switchover", "failed,"] or stdout.strip().split('\n')[-1].split()[:1] == ["Error"]):
|
elif stdout and (stdout.split('\n')[-1].split()[:2] == ["Switchover", "failed,"] or stdout.strip().split('\n')[-1].split()[:1] == ["Error"]):
|
||||||
|
|
Loading…
Reference in New Issue