Remove use of account lock executor in

ClearOrphanedFoundationDbQueuesCommand
This commit is contained in:
Ameya Lokare authored and Jon Chambers committed 2026-09-02 16:53:51 -04:00
1 parent b6bed9d772
commit 7bc8b93c18
3 files changed
+3 -3

No files matched your search

@@ -523,7 +523,7 @@ public class AccountsManager extends RedisPubSubAdapter<String, String> implemen
accountLockManager.withLock(Set.of(maybeRecentlyDeletedAccountIdentifier.get()), () -> {
accounts.create(account, additionalWriteItems);
return null;
}, accountLockExecutor);
});
} else {
accounts.create(account, additionalWriteItems);
}
@@ -209,7 +209,7 @@ public class ClearOrphanedFoundationDbQueuesCommand extends AbstractCommandWithD
}
clearQueue(database, aci, transactionRetryLimit, transactionTimeout);
return null;
}, executor), executor));
}), executor));
}
private void clearQueue(final Database database, final AciServiceIdentifier aci, final long transactionRetryLimit,
@@ -70,7 +70,7 @@ class ClearOrphanedFoundationDbQueuesCommandTest {
accountsManager = mock(AccountsManager.class);
accountLockManager = mock(AccountLockManager.class);
when(accountLockManager.withLock(any(), any(), any())).thenAnswer(invocation -> {
when(accountLockManager.withLock(any(), any())).thenAnswer(invocation -> {
//noinspection rawtypes
final ThrowingSupplier supplier = invocation.getArgument(1);
return supplier.get();