diff --git a/src/event/dto/heartbeat.dto.ts b/src/event/dto/heartbeat.dto.ts index c2bfd8a..c744278 100644 --- a/src/event/dto/heartbeat.dto.ts +++ b/src/event/dto/heartbeat.dto.ts @@ -2,12 +2,12 @@ import { IsString } from 'class-validator'; /** * DTO for a service replica heartbeat. - * @property service - The unique name of the service. - * @property replica - The unique ID of the replica. + * @property ServiceName - The unique name of the service. + * @property ReplicaId - The unique ID of the replica. */ export class HeartbeatDto { @IsString() - service: string; + ServiceName: string; @IsString() - replica: string; + ReplicaId: string; } diff --git a/src/event/event.controller.ts b/src/event/event.controller.ts index 9ce2e1a..a85e581 100644 --- a/src/event/event.controller.ts +++ b/src/event/event.controller.ts @@ -37,11 +37,11 @@ export class EventController { @Post('heartbeat') async processHeartbeat(@Body() event: HeartbeatDto): Promise { // Extract the order context from the event - const { service, replica } = event; + const { ServiceName, ReplicaId } = event; this.logger.debug( - `Received heartbeat for replica "${replica}" of service "${service}"`, + `Received heartbeat for replica "${ReplicaId}" of service "${ServiceName}"`, ); - this.eventService.heartbeat(service, replica); + this.eventService.heartbeat(ServiceName, ReplicaId); } }