Adding leader and not being leader logging on the overlord. (#17519)

This commit is contained in:
Karan Kumar 2024-12-03 22:36:53 +05:30 committed by GitHub
parent 9ef46fc92d
commit 0eb8d733d4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 1 deletions

View File

@ -106,7 +106,7 @@ public class DruidOverlord
giant.lock(); giant.lock();
// I AM THE MASTER OF THE UNIVERSE. // I AM THE MASTER OF THE UNIVERSE.
log.info("By the power of Grayskull, I have the power!"); log.info("By the power of Grayskull, I have the power. I am the leader");
try { try {
final TaskRunner taskRunner = runnerFactory.build(); final TaskRunner taskRunner = runnerFactory.build();
@ -193,6 +193,7 @@ public class DruidOverlord
giant.lock(); giant.lock();
try { try {
initialized = false; initialized = false;
log.info("I am no longer the leader...");
final Lifecycle leaderLifecycle = leaderLifecycleRef.getAndSet(null); final Lifecycle leaderLifecycle = leaderLifecycleRef.getAndSet(null);
if (leaderLifecycle != null) { if (leaderLifecycle != null) {