mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Prevent initializing clusters multiple times (#1950)
* Prevent initializing clusters multiple times Signed-off-by: Lauri Nevala <lauri.nevala@gmail.com> * Do not expose intializing to cluster state Signed-off-by: Lauri Nevala <lauri.nevala@gmail.com> * Convert initializing to observable and ensure it is set to false after init Signed-off-by: Lauri Nevala <lauri.nevala@gmail.com>
This commit is contained in:
1 parent
83ed44f670
commit
0117cecc33
2 files changed
+12
-1
No files matched your search
@@ -14,7 +14,7 @@ export class ClusterManager extends Singleton {
|
||||
// auto-init clusters
|
||||
autorun(() => {
|
||||
clusterStore.enabledClustersList.forEach(cluster => {
|
||||
if (!cluster.initialized) {
|
||||
if (!cluster.initialized && !cluster.initializing) {
|
||||
logger.info(`[CLUSTER-MANAGER]: init cluster`, cluster.getMeta());
|
||||
cluster.init(port);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user