Nestjs Shutdown hooks

This tutorial explains about NestJS Shutdown Hooks and

Every Component Such as Application, Module etc has life cycle hooks to listen events and write a custom code.

This tutorials shows you multiple ways about shutown hooks in NestJS

NestJS Shutdown Hooks


async function bootstrap() {
  const app = await NestFactory.create(AppModule);

  // Starts listening for shutdown hooks

  await app.listen(3000);

How To Gracefully Shutdown A Nestjs Application