Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Weiko committed Oct 16, 2024
1 parent 9112b6c commit 68c8612
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 11 deletions.
Original file line number Diff line number Diff line change
@@ -1,12 +1,6 @@
import { OnModuleDestroy } from '@nestjs/common';

import {
ConnectionOptions,
JobsOptions,
Queue,
QueueOptions,
Worker,
} from 'bullmq';
import { JobsOptions, Queue, QueueOptions, Worker } from 'bullmq';
import omitBy from 'lodash.omitby';

import {
Expand All @@ -19,9 +13,7 @@ import { MessageQueueWorkerOptions } from 'src/engine/core-modules/message-queue

import { MessageQueue } from 'src/engine/core-modules/message-queue/message-queue.constants';

export type BullMQDriverOptions = QueueOptions & {
connection?: ConnectionOptions | string;
};
export type BullMQDriverOptions = QueueOptions;

export class BullMQDriver implements MessageQueueDriver, OnModuleDestroy {
private queueMap: Record<MessageQueue, Queue> = {} as Record<
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import { ConnectionOptions } from 'tls';

import { EnvironmentService } from 'src/engine/core-modules/environment/environment.service';
import {
BullMQDriverFactoryOptions,
Expand Down Expand Up @@ -46,7 +48,7 @@ export const messageQueueModuleFactory = async (
return {
type: MessageQueueDriverType.BullMQ,
options: {
connection: connectionString,
connection: connectionString as ConnectionOptions,
},
} satisfies BullMQDriverFactoryOptions;
}
Expand Down

0 comments on commit 68c8612

Please sign in to comment.