Skip to content

graceful tiering stop #1632

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ydb/core/tx/columnshard/columnshard.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ void TColumnShard::CleanupActors(const TActorContext& ctx) {

StoragesManager->Stop();
if (Tiers) {
Tiers->Stop();
Tiers->Stop(true);
}
}

Expand Down
6 changes: 3 additions & 3 deletions ydb/core/tx/tiering/manager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class TTiersManager::TActor: public TActorBootstrapped<TTiersManager::TActor> {

}
~TActor() {
Owner->Stop();
Owner->Stop(false);
}

STATEFN(StateMain) {
Expand Down Expand Up @@ -162,11 +162,11 @@ TTiersManager& TTiersManager::Start(std::shared_ptr<TTiersManager> ownerPtr) {
return *this;
}

TTiersManager& TTiersManager::Stop() {
TTiersManager& TTiersManager::Stop(const bool needStopActor) {
if (!Actor) {
return *this;
}
if (TlsActivationContext) {
if (TlsActivationContext && needStopActor) {
TActivationContext::AsActorContext().Send(Actor->SelfId(), new NActors::TEvents::TEvPoison);
}
Actor = nullptr;
Expand Down
2 changes: 1 addition & 1 deletion ydb/core/tx/tiering/manager.h
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ class TTiersManager {
}

TTiersManager& Start(std::shared_ptr<TTiersManager> ownerPtr);
TTiersManager& Stop();
TTiersManager& Stop(const bool needStopActor);
const NTiers::TManager& GetManagerVerified(const TString& tierId) const;
const NTiers::TManager* GetManagerOptional(const TString& tierId) const;
NMetadata::NFetcher::ISnapshotsFetcher::TPtr GetExternalDataManipulation() const;
Expand Down