diff options
author | Tyler Seip <Tyler.Seip@mongodb.com> | 2021-03-19 18:28:46 +0000 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2021-03-23 17:37:22 +0000 |
commit | 8c463d0aa0cce19073210d274dcbb04c156dc802 (patch) | |
tree | 831640a2819370a0dc3641b02da5adad23e651a7 /src/mongo/db/repl/wait_for_majority_service.cpp | |
parent | f447e57dd2c5dbb39feef9cfe071ff1cc1de54d5 (diff) | |
download | mongo-8c463d0aa0cce19073210d274dcbb04c156dc802.tar.gz |
SERVER-53230: Rename cancelation -> cancellation everywhere
Diffstat (limited to 'src/mongo/db/repl/wait_for_majority_service.cpp')
-rw-r--r-- | src/mongo/db/repl/wait_for_majority_service.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/mongo/db/repl/wait_for_majority_service.cpp b/src/mongo/db/repl/wait_for_majority_service.cpp index deb45b3158f..eb288cb6ef5 100644 --- a/src/mongo/db/repl/wait_for_majority_service.cpp +++ b/src/mongo/db/repl/wait_for_majority_service.cpp @@ -86,7 +86,7 @@ void WaitForMajorityService::startup(ServiceContext* ctx) { invariant(_state == State::kNotStarted); _pool = makeThreadPool(); _waitForMajorityClient = ClientStrand::make(ctx->makeClient(kWaitClientName)); - _waitForMajorityCancelationClient = ClientStrand::make(ctx->makeClient(kCancelClientName)); + _waitForMajorityCancellationClient = ClientStrand::make(ctx->makeClient(kCancelClientName)); _backgroundWorkComplete = _periodicallyWaitForMajority(); _pool->startup(); _state = State::kRunning; @@ -102,7 +102,7 @@ void WaitForMajorityService::shutDown() { _state = State::kShutdown; _waitForMajorityClient->getClientPointer()->setKilled(); - _waitForMajorityCancelationClient->getClientPointer()->setKilled(); + _waitForMajorityCancellationClient->getClientPointer()->setKilled(); for (auto&& request : _queuedOpTimes) { if (!request.second->hasBeenProcessed.swap(true)) { @@ -119,11 +119,11 @@ void WaitForMajorityService::shutDown() { // in the thread pool to complete since that work might be using the client // objects. _waitForMajorityClient.reset(); - _waitForMajorityCancelationClient.reset(); + _waitForMajorityCancellationClient.reset(); } SemiFuture<void> WaitForMajorityService::waitUntilMajority(const repl::OpTime& opTime, - const CancelationToken& cancelToken) { + const CancellationToken& cancelToken) { auto [promise, future] = makePromiseFuture<void>(); auto request = std::make_shared<Request>(std::move(promise)); @@ -172,7 +172,7 @@ SemiFuture<void> WaitForMajorityService::waitUntilMajority(const repl::OpTime& o if (!s.isOK()) { return; } - auto clientGuard = _waitForMajorityCancelationClient->bind(); + auto clientGuard = _waitForMajorityCancellationClient->bind(); if (!request->hasBeenProcessed.swap(true)) { request->result.setError(waitUntilMajorityCanceledStatus()); stdx::lock_guard lk(_mutex); @@ -229,7 +229,7 @@ SemiFuture<void> WaitForMajorityService::_periodicallyWaitForMajority() { // TODO (SERVER-53766): Replace with condition-free looping utility. return false; }) - .on(_pool, CancelationToken::uncancelable()) + .on(_pool, CancellationToken::uncancelable()) .semi(); } |