From 80555984b2662c878b1495f1c610f79e361c66cb Mon Sep 17 00:00:00 2001 From: Manuel Astudillo Date: Thu, 16 Nov 2023 15:35:07 +0000 Subject: [PATCH] GITBOOK-182: change request with no subject merged in GitBook --- docs/gitbook/SUMMARY.md | 2 ++ docs/gitbook/guide/redis-tm-compatibility/README.md | 4 ++++ .../guide/redis-tm-compatibility/dragonfly.md | 13 +++++++++++++ 3 files changed, 19 insertions(+) create mode 100644 docs/gitbook/guide/redis-tm-compatibility/README.md create mode 100644 docs/gitbook/guide/redis-tm-compatibility/dragonfly.md diff --git a/docs/gitbook/SUMMARY.md b/docs/gitbook/SUMMARY.md index d8fcbf3d49..3b353011fe 100644 --- a/docs/gitbook/SUMMARY.md +++ b/docs/gitbook/SUMMARY.md @@ -40,6 +40,8 @@ * [Returning job data](guide/returning-job-data.md) * [Events](guide/events.md) * [QueueScheduler](guide/queuescheduler.md) +* [Redis™ Compatibility](guide/redis-tm-compatibility/README.md) + * [Dragonfly](guide/redis-tm-compatibility/dragonfly.md) * [Architecture](guide/architecture.md) * [NestJs](guide/nestjs/README.md) * [Producers](guide/nestjs/producers.md) diff --git a/docs/gitbook/guide/redis-tm-compatibility/README.md b/docs/gitbook/guide/redis-tm-compatibility/README.md new file mode 100644 index 0000000000..4c64f8522c --- /dev/null +++ b/docs/gitbook/guide/redis-tm-compatibility/README.md @@ -0,0 +1,4 @@ +# Redis™ Compatibility + +There are several alternatives for Redis and even though BullMQ is full Redis™ compliant, not all the alternatives are going to work properly. In this section we present the vendors that officially support BullMQ and that we regularly test to verify they keep staying compatible. + diff --git a/docs/gitbook/guide/redis-tm-compatibility/dragonfly.md b/docs/gitbook/guide/redis-tm-compatibility/dragonfly.md new file mode 100644 index 0000000000..47e5cc3fc0 --- /dev/null +++ b/docs/gitbook/guide/redis-tm-compatibility/dragonfly.md @@ -0,0 +1,13 @@ +# Dragonfly + +[Dragonfly](https://www.dragonflydb.io/) offers a drop-in replacement for Redis™, boasting a much faster and more memory-efficient implementation of several data structures used by BullMQ. It also enables the utilization of all available cores in your CPUs. Check [this article](https://bullmq.io/news/101023/dragonfly-compatibility/) for some performance results. + +To fully leverage Dragonfly's capabilities, specific steps are necessary. Primarily, you should name your queues using curly braces. This naming convention allows Dragonfly to assign a thread to each queue. For instance, if your queue is named `myqueue,`rename it to `{myqueue}`. + +If you manage multiple queues, this approach enables you to allocate different CPU cores to each queue, significantly enhancing performance. Even with a single queue, you can still exploit multi-core advantages in some cases. Consider splitting your queue into multiple ones, like`{myqueue-1}`, `{myqueue-2}`, etc., and distribute jobs randomly or using a round-robin method. + +{% hint style="info" %} +Be aware that certain features like priorities and rate-limiting might not function across multiple queues. Your specific requirements will determine whether you can divide a single queue in this manner. +{% endhint %} + +For comprehensive instructions and the necessary flags to optimize your Dragonfly instance for BullMQ, please consult the [official integration guide](https://www.dragonflydb.io/docs/integrations/bullmq).