ad crit logger
This commit is contained in:
parent
4667185a91
commit
72fda86dc9
|
@ -95,6 +95,10 @@ import { MatcherController } from './logger/adapters/primaries/matcher.controlle
|
||||||
exchange: configService.get<string>('RMQ_EXCHANGE'),
|
exchange: configService.get<string>('RMQ_EXCHANGE'),
|
||||||
routingKey: 'logging.configuration.health.crit',
|
routingKey: 'logging.configuration.health.crit',
|
||||||
},
|
},
|
||||||
|
loggingMatcherAdCrit: {
|
||||||
|
exchange: configService.get<string>('RMQ_EXCHANGE'),
|
||||||
|
routingKey: 'logging.matcher.ad.crit',
|
||||||
|
},
|
||||||
loggingMatcherMatchCrit: {
|
loggingMatcherMatchCrit: {
|
||||||
exchange: configService.get<string>('RMQ_EXCHANGE'),
|
exchange: configService.get<string>('RMQ_EXCHANGE'),
|
||||||
routingKey: 'logging.matcher.match.crit',
|
routingKey: 'logging.matcher.match.crit',
|
||||||
|
|
|
@ -11,6 +11,16 @@ export class MatcherController {
|
||||||
@Inject(WINSTON_MODULE_PROVIDER) private readonly logger: Logger,
|
@Inject(WINSTON_MODULE_PROVIDER) private readonly logger: Logger,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
|
@RabbitSubscribe({
|
||||||
|
name: 'loggingMatcherAdCrit',
|
||||||
|
})
|
||||||
|
public async matcherAdCriticalHandler(message: string) {
|
||||||
|
this.logger.configure(
|
||||||
|
loggerOptions('matcher', level.crit, 'critical', 'ad'),
|
||||||
|
);
|
||||||
|
this.logger.crit(JSON.parse(message));
|
||||||
|
}
|
||||||
|
|
||||||
@RabbitSubscribe({
|
@RabbitSubscribe({
|
||||||
name: 'loggingMatcherMatchCrit',
|
name: 'loggingMatcherMatchCrit',
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in New Issue