Skip to content

Commit

Permalink
fix(core): Fix init for AuditEventRelay (n8n-io#9839)
Browse files Browse the repository at this point in the history
  • Loading branch information
ivov authored Jun 24, 2024
1 parent b807e67 commit 16d3083
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 2 additions & 0 deletions packages/cli/src/Server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ import '@/ExternalSecrets/ExternalSecrets.controller.ee';
import '@/license/license.controller';
import '@/workflows/workflowHistory/workflowHistory.controller.ee';
import '@/workflows/workflows.controller';
import { AuditEventRelay } from './eventbus/audit-event-relay.service';

const exec = promisify(callbackExec);

Expand Down Expand Up @@ -252,6 +253,7 @@ export class Server extends AbstractServer {
// ----------------------------------------
const eventBus = Container.get(MessageEventBus);
await eventBus.initialize();
Container.get(AuditEventRelay).init();

if (this.endpointPresetCredentials !== '') {
// POST endpoint to set preset credentials
Expand Down
4 changes: 3 additions & 1 deletion packages/cli/src/eventbus/audit-event-relay.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@ export class AuditEventRelay {
constructor(
private readonly eventRelay: EventRelay,
private readonly eventBus: MessageEventBus,
) {
) {}

init() {
this.setupHandlers();
}

Expand Down

0 comments on commit 16d3083

Please sign in to comment.