MCPcopy
hub / github.com/amplication/amplication / bootstrap

Function bootstrap

packages/notification-service/src/main.ts:19–32  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

17import { AppModule } from "./app.module";
18
19async function bootstrap() {
20 const app = await NestFactory.create(AppModule, { bufferLogs: true });
21 app.useLogger(app.get(AmplicationLogger));
22
23 app.connectMicroservice<MicroserviceOptions>({
24 strategy: new KafkaCustomTransport(createNestjsKafkaConfig().options),
25 });
26
27 await app.startAllMicroservices();
28
29 const configService: ConfigService = app.get<ConfigService>(ConfigService);
30 const port = configService.get(Env.PORT);
31 await app.listen(port);
32}
33
34bootstrap().catch((error) => {
35 new Logger({ component: Env.SERVICE_NAME, isProduction: true }).error(

Callers 1

main.tsFile · 0.70

Calls 3

createNestjsKafkaConfigFunction · 0.90
getMethod · 0.65
createMethod · 0.45

Tested by

no test coverage detected