Skip to content

Commit

Permalink
Maybe this could help ? (#30)
Browse files Browse the repository at this point in the history
add EventStoreHealthIndicator & EventStoreSubscriptionHealthIndicator, in registerAsync
  • Loading branch information
xGouley authored Sep 15, 2020
1 parent 7b8681b commit e4cceec
Showing 1 changed file with 20 additions and 1 deletion.
21 changes: 20 additions & 1 deletion src/event-store.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,27 @@ export class EventStoreModule {
},
inject: [...options.inject, Logger],
},
{
provide: EventStoreHealthIndicator,
useFactory: eventStore => {
return new EventStoreHealthIndicator(eventStore);
},
inject: [EventStore],
},
{
provide: EventStoreSubscriptionHealthIndicator,
useFactory: eventStore => {
return new EventStoreSubscriptionHealthIndicator(eventStore);
},
inject: [EventStore],
},
],
exports: [
EventStore,
EventStoreModule,
EventStoreHealthIndicator,
EventStoreSubscriptionHealthIndicator,
],
exports: [EventStoreModule],
};
}
}

0 comments on commit e4cceec

Please sign in to comment.