Features
Get started with Prisma x Terminus:
- Install Prisma
- Install this release (unstable)
npm install @nestjs/terminus@10.0.0-beta.0
- Update your
health.controller.ts
:
@Controller()
export class HealthController {
constructor(
private readonly health: HealthCheckService,
private readonly prisma: PrismaHealthIndicator,
private readonly prismaService: PrismaService,
) {}
@Get('/health')
healthCheck() {
return this.health.check([
() => this.prisma.pingCheck('prisma', this.prismaService),
]);
}
}
Checkout the Prisma sample app here
BREAKING CHANGES
- drop support for Node v12