diff --git a/ReleaseNotes.md b/ReleaseNotes.md index 7f677882888ceff5d09d63c4239c41181c49be76..6ee41ce62e888f5d5f94b3965a5b4472f43b17a2 100644 --- a/ReleaseNotes.md +++ b/ReleaseNotes.md @@ -7,6 +7,7 @@ ### Bug Fixes - cta/CTA#485 - Check disk file metadata on delete requests - cta/CTA#634 - Fix crash of ctafrontend in initialisation for missing config values +- cta/CTA#666 - Fix drive status activity field not being properly reset ### Continuous Integration - cta/CTA#615 - Going to xrdfs xattr API for EOS5 extended attribute tests (EOS >= 5.2.17) diff --git a/catalogue/TapeDrivesCatalogueState.cpp b/catalogue/TapeDrivesCatalogueState.cpp index 6996f1eec3781e68f9ef49bd0d81d6936282b059..8285d0f5cb40c87b71bd9c44e9b267181ece37ab 100644 --- a/catalogue/TapeDrivesCatalogueState.cpp +++ b/catalogue/TapeDrivesCatalogueState.cpp @@ -198,7 +198,7 @@ void TapeDrivesCatalogueState::setDriveDown(common::dataStructures::TapeDrive & driveState.currentVid = ""; driveState.currentTapePool = ""; driveState.currentVo = ""; - driveState.currentActivity = std::nullopt; + driveState.currentActivity = ""; if (inputs.reason) driveState.reasonUpDown = inputs.reason; } @@ -228,7 +228,7 @@ void TapeDrivesCatalogueState::setDriveUpOrMaybeDown(common::dataStructures::Tap driveState.currentVid = ""; driveState.currentTapePool = ""; driveState.currentVo = ""; - driveState.currentActivity = std::nullopt; + driveState.currentActivity = ""; if (inputs.reason) driveState.reasonUpDown = inputs.reason; } @@ -257,7 +257,7 @@ void TapeDrivesCatalogueState::setDriveProbing(common::dataStructures::TapeDrive driveState.currentVid = ""; driveState.currentTapePool = ""; driveState.currentVo = ""; - driveState.currentActivity = std::nullopt; + driveState.currentActivity = ""; } void TapeDrivesCatalogueState::setDriveStarting(common::dataStructures::TapeDrive & driveState, @@ -440,7 +440,7 @@ void TapeDrivesCatalogueState::setDriveCleaningUp(common::dataStructures::TapeDr driveState.driveStatus = common::dataStructures::DriveStatus::CleaningUp; driveState.currentVid = inputs.vid.empty() ? std::nullopt : std::optional<std::string>(inputs.vid); driveState.currentTapePool = inputs.tapepool.empty() ? std::nullopt : std::optional<std::string>(inputs.tapepool); - driveState.currentActivity = std::nullopt; + driveState.currentActivity = ""; driveState.currentVo = inputs.vo.empty() ? std::nullopt : std::optional<std::string>(inputs.vo); } @@ -468,7 +468,7 @@ void TapeDrivesCatalogueState::setDriveShutdown(common::dataStructures::TapeDriv driveState.driveStatus = common::dataStructures::DriveStatus::Shutdown; driveState.currentVid = inputs.vid.empty() ? std::nullopt : std::optional<std::string>(inputs.vid); driveState.currentTapePool = inputs.tapepool.empty() ? std::nullopt : std::optional<std::string>(inputs.tapepool); - driveState.currentActivity = std::nullopt; + driveState.currentActivity = ""; driveState.currentVo = inputs.vo.empty() ? std::nullopt : std::optional<std::string>(inputs.vo); }