mirror of
https://github.com/versia-pub/server.git
synced 2025-12-06 16:38:19 +01:00
17 lines
372 B
TypeScript
17 lines
372 B
TypeScript
import { Queue } from "bullmq";
|
|
import { connection } from "~/utils/redis.ts";
|
|
|
|
export enum MediaJobType {
|
|
ConvertMedia = "convertMedia",
|
|
CalculateMetadata = "calculateMetadata",
|
|
}
|
|
|
|
export type MediaJobData = {
|
|
attachmentId: string;
|
|
filename: string;
|
|
};
|
|
|
|
export const mediaQueue = new Queue<MediaJobData, void, MediaJobType>("media", {
|
|
connection,
|
|
});
|