You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We have been using bull in nestjs for 7 months now and are very happy with it, but wanted to migrate to Bullmq to take advantage of globalconcurrency, dynamic rate limiting, and whatever improvements are under the hood.
The majority of this migration was pretty seamless as most of the features port over quite easily. However I wanted to share tips on specific changes that need to be made that caused a fair amount of debugging.
Redis connection
In bull we defined our redis connection at the module level with BullModule.registerQueue. However when you switch over to bullmq, you need to define the redis connection anywhere that a queue, worker, or queueevents is declared. I read over the docs and maybe just misunderstood as this wasn't totally clear.
Part of the confusion also came from the fact that internally I believe bullmq defaults to localhostredis:6789 and since I had that running locally to test, didn't receive any connect errors until deploying to the cloud.
Ultimately had to switch my local redis port to uncover where I wasn't declaring the redis connection (a couple queue declarations and a queueevents).
In case anyone else is making the switch over and is bad at reading docs, hope this helps. Great product overall and we are excited to take advantage of the new features in bullmq.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
We have been using bull in nestjs for 7 months now and are very happy with it, but wanted to migrate to Bullmq to take advantage of globalconcurrency, dynamic rate limiting, and whatever improvements are under the hood.
The majority of this migration was pretty seamless as most of the features port over quite easily. However I wanted to share tips on specific changes that need to be made that caused a fair amount of debugging.
Redis connection
In bull we defined our redis connection at the module level with
BullModule.registerQueue. However when you switch over to bullmq, you need to define the redis connection anywhere that a queue, worker, or queueevents is declared. I read over the docs and maybe just misunderstood as this wasn't totally clear.Part of the confusion also came from the fact that internally I believe bullmq defaults to localhostredis:6789 and since I had that running locally to test, didn't receive any connect errors until deploying to the cloud.
Ultimately had to switch my local redis port to uncover where I wasn't declaring the redis connection (a couple queue declarations and a queueevents).
In case anyone else is making the switch over and is bad at reading docs, hope this helps. Great product overall and we are excited to take advantage of the new features in bullmq.
Beta Was this translation helpful? Give feedback.
All reactions