Skip to content

Commit

Permalink
fix(meta): expired RiseCtl worker causes meta panics (#5212)
Browse files Browse the repository at this point in the history
* fix ctl ttl causes meta panic

* refactor

Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
  • Loading branch information
chenzl25 and mergify[bot] authored Sep 8, 2022
1 parent 828fa0d commit 761b1ba
Showing 1 changed file with 12 additions and 5 deletions.
17 changes: 12 additions & 5 deletions src/meta/src/manager/cluster.rs
Original file line number Diff line number Diff line change
Expand Up @@ -276,11 +276,18 @@ where
for (worker_id, key) in workers_to_delete {
match cluster_manager.delete_worker_node(key.clone()).await {
Ok(worker_type) => {
cluster_manager
.env
.notification_manager()
.delete_sender(worker_type, WorkerKey(key.clone()))
.await;
match worker_type {
WorkerType::Frontend
| WorkerType::ComputeNode
| WorkerType::Compactor => {
cluster_manager
.env
.notification_manager()
.delete_sender(worker_type, WorkerKey(key.clone()))
.await
}
_ => {}
};
tracing::warn!(
"Deleted expired worker {} {:#?}, current timestamp {}",
worker_id,
Expand Down

0 comments on commit 761b1ba

Please sign in to comment.