fix(all): Fix search on others bots than boot.
This commit is contained in:
parent
2c0d8a84e8
commit
19ae7e1cae
1 changed files with 7 additions and 7 deletions
|
@ -717,9 +717,9 @@ export class GBDeployer implements IGBDeployer {
|
||||||
// Prepares search.
|
// Prepares search.
|
||||||
let release;
|
let release;
|
||||||
try {
|
try {
|
||||||
GBLogEx.info(instance.instanceId, `Acquiring rebuildIndex mutex...`);
|
// GBLogEx.info(instance.instanceId, `Acquiring rebuildIndex mutex...`);
|
||||||
release = await GBServer.globals.indexSemaphore.acquire();
|
// release = await GBServer.globals.indexSemaphore.acquire();
|
||||||
GBLogEx.info(instance.instanceId, `Acquire rebuildIndex done.`);
|
// GBLogEx.info(instance.instanceId, `Acquire rebuildIndex done.`);
|
||||||
|
|
||||||
const key = instance.searchKey ? instance.searchKey : GBServer.globals.minBoot.instance.searchKey;
|
const key = instance.searchKey ? instance.searchKey : GBServer.globals.minBoot.instance.searchKey;
|
||||||
const searchIndex = instance.searchIndex ? instance.searchIndex : GBServer.globals.minBoot.instance.searchIndex;
|
const searchIndex = instance.searchIndex ? instance.searchIndex : GBServer.globals.minBoot.instance.searchIndex;
|
||||||
|
@ -773,12 +773,12 @@ export class GBDeployer implements IGBDeployer {
|
||||||
}
|
}
|
||||||
await search.createIndex(searchSchema, dsName);
|
await search.createIndex(searchSchema, dsName);
|
||||||
|
|
||||||
release();
|
// release();
|
||||||
GBLogEx.info(instance.instanceId, `Released rebuildIndex mutex.`);
|
GBLogEx.info(instance.instanceId, `Released rebuildIndex mutex.`);
|
||||||
} catch {
|
} catch {
|
||||||
if (release) {
|
// if (release) {
|
||||||
release();
|
// release();
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue