fix: clean up registry shutdown

This commit is contained in:
2026-04-29 01:29:53 +00:00
parent 5cb6895a14
commit 2b51178016
2 changed files with 11 additions and 1 deletions
+10
View File
@@ -317,6 +317,15 @@ export class RegistryManager {
* Stop the registry and smartstorage server
*/
async stop(): Promise<void> {
if (this.registry) {
try {
this.registry.destroy?.();
} catch (error) {
logger.error(`Error destroying smartregistry: ${getErrorMessage(error)}`);
}
this.registry = null;
}
if (this.s3Server) {
try {
await this.s3Server.stop();
@@ -324,6 +333,7 @@ export class RegistryManager {
} catch (error) {
logger.error(`Error stopping smartstorage: ${getErrorMessage(error)}`);
}
this.s3Server = null;
}
this.isInitialized = false;
+1 -1
View File
File diff suppressed because one or more lines are too long