refactor(server): event names (#12084)
This commit is contained in:
@@ -121,8 +121,8 @@ export class MetadataService {
|
||||
);
|
||||
}
|
||||
|
||||
@OnEmit({ event: 'onBootstrap' })
|
||||
async onBootstrap(app: ArgOf<'onBootstrap'>) {
|
||||
@OnEmit({ event: 'app.bootstrap' })
|
||||
async onBootstrap(app: ArgOf<'app.bootstrap'>) {
|
||||
if (app !== 'microservices') {
|
||||
return;
|
||||
}
|
||||
@@ -130,8 +130,8 @@ export class MetadataService {
|
||||
await this.init(config);
|
||||
}
|
||||
|
||||
@OnEmit({ event: 'onConfigUpdate' })
|
||||
async onConfigUpdate({ newConfig }: ArgOf<'onConfigUpdate'>) {
|
||||
@OnEmit({ event: 'config.update' })
|
||||
async onConfigUpdate({ newConfig }: ArgOf<'config.update'>) {
|
||||
await this.init(newConfig);
|
||||
}
|
||||
|
||||
@@ -153,7 +153,7 @@ export class MetadataService {
|
||||
}
|
||||
}
|
||||
|
||||
@OnEmit({ event: 'onShutdown' })
|
||||
@OnEmit({ event: 'app.shutdown' })
|
||||
async onShutdown() {
|
||||
await this.repository.teardown();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user