DBZ-6875 Ensuring root user is created when using authenticated mongo rs
This commit is contained in:
parent
83e6f28e41
commit
2f70c30962
@ -270,6 +270,9 @@ public void start() {
|
||||
// Create rootUser
|
||||
LOGGER.info("[{}] Creating root user...", name);
|
||||
createRootUser();
|
||||
// Make sure RS status is available to root user
|
||||
awaitReplicaPrimary();
|
||||
|
||||
started = true;
|
||||
}
|
||||
|
||||
@ -329,6 +332,7 @@ public void awaitReplicaPrimary() {
|
||||
await()
|
||||
.atMost(1, MINUTES)
|
||||
.pollDelay(1, SECONDS)
|
||||
.ignoreException(IllegalArgumentException.class)
|
||||
.until(() -> tryPrimary().isPresent());
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user