diff --git a/services/backup/docker-server/contents/server/src/Reactors/server/CreateNewBackupReactor.h b/services/backup/docker-server/contents/server/src/Reactors/server/CreateNewBackupReactor.h --- a/services/backup/docker-server/contents/server/src/Reactors/server/CreateNewBackupReactor.h +++ b/services/backup/docker-server/contents/server/src/Reactors/server/CreateNewBackupReactor.h @@ -35,7 +35,7 @@ std::string backupID; std::shared_ptr putReactor; ServiceBlobClient blobClient; - std::mutex blobPutClientReactorMutex; + std::mutex reactorStateMutex; std::condition_variable waitingForBlobClientCV; std::mutex waitingForBlobClientCVMutex; @@ -49,7 +49,7 @@ }; std::string CreateNewBackupReactor::generateBackupID() { - // mock + // TODO replace mock return generateRandomString(); } @@ -58,7 +58,7 @@ backup::CreateNewBackupResponse *response) { // we make sure that the blob client's state is flushed to the main memory // as there may be multiple threads from the pool taking over here - const std::lock_guard lock(this->blobPutClientReactorMutex); + const std::lock_guard lock(this->reactorStateMutex); switch (this->state) { case State::USER_ID: { if (!request.has_userid()) { @@ -103,7 +103,7 @@ } void CreateNewBackupReactor::terminateCallback() { - const std::lock_guard lock(this->blobPutClientReactorMutex); + const std::lock_guard lock(this->reactorStateMutex); if (this->putReactor == nullptr) { return; }