Skip to content

Commit

Permalink
Fix not unlocking mutex
Browse files Browse the repository at this point in the history
  • Loading branch information
thevindu-w committed May 8, 2024
1 parent f4cabd1 commit ad9c20f
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/scale/scaler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -104,10 +104,11 @@ static void scale_down_thread_fn() {
if (it == removing.end()) break;
removing.erase(it);
}
if (removing.empty()) continue;
if (!removing.empty()) {
K8sWorkerController *k8s = K8sWorkerController::getInstance();
k8s->scaleDown(removing);
};

K8sWorkerController *k8s = K8sWorkerController::getInstance();
k8s->scaleDown(removing);
schedulerMutex.unlock();
}
}

0 comments on commit ad9c20f

Please sign in to comment.