From 56f371dba16f8acdefa484f0c60a80d741ea0b50 Mon Sep 17 00:00:00 2001 From: David Ludwig Date: Sat, 1 May 2021 23:42:44 -0500 Subject: [PATCH] Update microservice package to make microservice internal services event emitters --- packages/microservice/src/InternalService.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/microservice/src/InternalService.ts b/packages/microservice/src/InternalService.ts index 6136313..e94bd28 100644 --- a/packages/microservice/src/InternalService.ts +++ b/packages/microservice/src/InternalService.ts @@ -1,9 +1,10 @@ import { Microservice } from "./Microservice"; +import EventEmitter from "events"; /** * A generic service */ -export abstract class InternalService +export abstract class InternalService extends EventEmitter { /** * The application instance @@ -19,6 +20,7 @@ export abstract class InternalService * Create a new service */ public constructor(app: T) { + super(); this.app = app; }