Releases: nestjs/terminus
Release 11.1.1
11.1.1 (2026-02-18)
Bug Fixes
- use dependency injection to provide custom loggers (8d7226b), closes #2694, @flovouin @BrunnerLivio
Release 11.1.0
Release 11.0.0
11.0.0 (2025-01-25)
Features
- simplify custom health indicator creation (9f10a9b)
- upgrade to nestjs v11 (c2569df), closes #2570
- update dependencies
BREAKING CHANGES
- Drop support for Node 16 / 18
For users who have implemented a custom health indicator, an enhanced API is now available. However, the existing API will continue to function as-is without requiring any changes.
The new and improved HealthIndicatorService provides a streamlined way to indicate whether a health indicator is up or down.
Please note that the HealthIndicator and HealthCheckError classes have been marked as deprecated and are scheduled for removal in the next major release, version 12.0.0.
@Injectable()
export class DogHealthIndicator {
constructor(
private readonly dogService: DogService,
private readonly healthIndicatorService: HealthIndicatorService,
) {}
async isHealthy(key: string) {
const indicator = this.healthIndicatorService.check(key);
const dogs = await this.dogService.getDogs();
const badboys = dogs.filter((dog) => dog.state === DogState.BAD_BOY);
const isHealthy = badboys.length === 0;
if (!isHealthy) {
return indicator.down({
badboys: badboys.length,
});
}
return indicator.up();
}
}Release 11.0.0-beta.1
Release 11.0.0-beta.0
11.0.0-beta.0 (2025-01-23)
Features
BREAKING CHANGES
- Drop support for Node 16 / 18
Installaion
# npm
npm install @nestjs/[email protected]
# pnpm
pnpm add @nestjs/[email protected]
# yarn
yarn add @nestjs/[email protected]For users who have implemented a custom health indicator, an enhanced API is now available. However, the existing API will continue to function as-is without requiring any changes.
The new and improved HealthIndicatorService provides a streamlined way to indicate whether a health indicator is up or down.
Please note that the HealthIndicator and HealthCheckError classes have been marked as deprecated and are scheduled for removal in the next major release, version 12.0.0.
@Injectable()
export class DogHealthIndicator {
constructor(
private readonly dogService: DogService,
private readonly healthIndicatorService: HealthIndicatorService,
) {}
async isHealthy(key: string) {
const indicator = this.healthIndicatorService.check(key);
const dogs = await this.dogService.getDogs();
const badboys = dogs.filter((dog) => dog.state === DogState.BAD_BOY);
const isHealthy = badboys.length === 0;
if (!isHealthy) {
return indicator.down({
badboys: badboys.length,
});
}
return indicator.up();
}
}Release 10.3.0
Release 10.2.3
Release 10.2.2
10.2.2 (2024-02-07)
Bug Fixes
MikroOrmHealthIndicatorsindicates as up even when disconnected (#2509) (#2511) (069b998), closes #2460- Swagger schema for health check result additional props set to
type: 'object'instead oftype: 'string', (44c06f6), closes #2516 - mark
resultas required in the Swagger Schema for the health check result (01ce13b), @srdanielillo
Dependencies
- deps: update dependency reflect-metadata to v0.2.1 (e2420bd)
- deps: update prisma monorepo to v5.9.1 (d88770c)
- deps: update dependency class-validator to v0.14.1 (#2479) (a8585ce)
- deps: update dependency typeorm to v0.3.20 (#2480) (72e7f7a)
- deps: update mikro-orm monorepo to v5.9.7 (#2481) (1eaa605)
- deps: update nest monorepo (#2482) (3c555e0)
Release 10.2.2-beta.0
10.2.2-beta.0 (2024-01-31)
Bug Fixes
- deps: update dependency class-validator to v0.14.1 (#2479) (a8585ce)
- deps: update dependency typeorm to v0.3.20 (#2480) (72e7f7a)
- deps: update mikro-orm monorepo to v5.9.7 (#2481) (1eaa605)
- deps: update nest monorepo (#2482) (3c555e0)
- mikroorm is indicated as up even when disconnected (#2509) (#2511) (069b998), closes #2460
