bullmq | Message Queue and Batch processing | Runtime Evironment library

 by   taskforcesh TypeScript Version: 2.7.8 License: MIT

kandi X-RAY | bullmq Summary

kandi X-RAY | bullmq Summary

bullmq is a TypeScript library typically used in Server, Runtime Evironment, Nodejs, RabbitMQ applications. bullmq has no bugs, it has no vulnerabilities, it has a Permissive License and it has medium support. You can download it from GitHub.

The fastest, most reliable, Redis-based distributed queue for Node. Carefully written for rock solid stability and atomicity.
Support
    Quality
      Security
        License
          Reuse

            kandi-support Support

              bullmq has a medium active ecosystem.
              It has 3851 star(s) with 273 fork(s). There are 24 watchers for this library.
              There were 2 major release(s) in the last 6 months.
              There are 206 open issues and 615 have been closed. On average issues are closed in 97 days. There are 31 open pull requests and 0 closed requests.
              It has a neutral sentiment in the developer community.
              The latest version of bullmq is 2.7.8

            kandi-Quality Quality

              bullmq has 0 bugs and 0 code smells.

            kandi-Security Security

              bullmq has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.
              bullmq code analysis shows 0 unresolved vulnerabilities.
              There are 0 security hotspots that need review.

            kandi-License License

              bullmq is licensed under the MIT License. This license is Permissive.
              Permissive licenses have the least restrictions, and you can use them in most projects.

            kandi-Reuse Reuse

              bullmq releases are available to install and integrate.
              Installation instructions are not available. Examples and code snippets are available.

            Top functions reviewed by kandi - BETA

            kandi's functional review helps you automatically verify the functionalities of the libraries and avoid rework.
            Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of bullmq
            Get all kandi verified functions for this library.

            bullmq Key Features

            No Key Features are available at this moment for bullmq.

            bullmq Examples and Code Snippets

            Getting Started
            TypeScriptdot img1Lines of Code : 132dot img1License : Permissive (MIT)
            copy iconCopy
            $ npm i @nestjs/microservices bullmq bull-mq-transport
            
            import { Module } from '@nestjs/common';
            import { BullMqModule } from 'bull-mq-transport';
            
            @Module({
              imports: [
                BullMqModule.forRoot({
                  connection: { host: 'localhost', port: 6379 },  

            Community Discussions

            QUESTION

            How to gracefully shutdown bullmq when running inside an express server?
            Asked 2022-Feb-18 at 08:11
            • I have an express app which uses bullmq queues, schedulers and workers. Even after pressing Ctrl + C I can still see the node process running inside my Activity manager but my server on the terminal shuts down. I know this because the bullmq task starts outputting console.log statements even after the server is down to the terminal.

            This is what my server.js file looks like

            ...

            ANSWER

            Answered 2022-Feb-18 at 08:11

            You have to call the close() method on the workers:

            Source https://stackoverflow.com/questions/71170075

            QUESTION

            Does MikroORM require a RequestContext when used with background workers like BullMQ?
            Asked 2021-Dec-03 at 13:54

            I'm using MikroORM with BullMQ workers. When MikroORM is used with Express apps, it requires a RequestContext in order to maintain unique identity maps for each request. I suspect the same is required when processing multiple jobs with the same BullMQ worker.

            Has anyone else successfully combined these two libraries? Is it possible to automatically fork the Entity Manager when a worker starts a new job?

            ...

            ANSWER

            Answered 2021-Dec-03 at 13:54

            You can use @UseRequestContext() decorator for such cases. It will basically act as if the method would be executed after a middleware that adds the context. Note that to use it, this.orm needs to be the MikroORM instance.

            Source https://stackoverflow.com/questions/70209851

            QUESTION

            Bull job is not stalled when processor terminated only when getting back up
            Asked 2021-Oct-25 at 14:58

            the code that I'm talking about is the repro code linked below

            I have 2 "states" in the code (both of them are listening to queue global events):

            1. Add a single message
            2. Listen to messages

            For some reason, Bull job is not reported as stalled when the listener worker is terminated only when the worker is back up.

            although it should as stated in the docs:

            ...

            ANSWER

            Answered 2021-Oct-25 at 14:58

            I am afraid this works as designed, since in Bull the workers are also responsible of detecting stalled jobs, while in BullMQ you have the QueueScheduler that takes care of this.

            From Bull Repo - Issue 2141

            Source https://stackoverflow.com/questions/68928264

            QUESTION

            Trigger the execution of a function if any condition is met
            Asked 2021-Oct-08 at 03:03

            I'm writing an HTTP API with expressjs in Node.js and here is what I'm trying to achieve:

            • I have a regular task that I would like to run regularly, approx every minute. This task is implemented with an async function named task.
            • In reaction to a call in my API I would like to have that task called immediately as well
            • Two executions of the task function must not be concurrent. Each execution should run to completion before another execution is started.

            The code looks like this:

            ...

            ANSWER

            Answered 2021-Oct-08 at 02:29

            Here's a version using RxJS#Subject that is almost working. How to finish it depends on your use-case.

            Source https://stackoverflow.com/questions/69488943

            QUESTION

            Heroku Redis gets a wrong version number error in logs
            Asked 2021-Apr-07 at 11:34

            I am using Heroku's Redis add-on. I upgraded yesterday to a higher tier and now I'm getting this when I send requests to my server. Any suggestions on what this error log means?

            ...

            ANSWER

            Answered 2021-Apr-07 at 11:34

            Heroku shipped new updates related to Redis as outlined in their changelog here: https://devcenter.heroku.com/changelog-items/1952.

            The New Redis addons without a version specified will now default to 6.0 version, as it is secured with the self-signed certificate because of its built-in TLS for production plans. You'll need to add ssl_params: { verify_mode: OpenSSL::SSL::VERIFY_NONE } to handle the self-signed certificate. Please refer here for additional details: https://devcenter.heroku.com/articles/securing-heroku-redis

            You may also work around this behavior by downgrading to Redis 5 version. You can do it by running(using --version flag): heroku addons:create heroku-redis:premium-2 --version 5 -a . More details here: https://devcenter.heroku.com/articles/heroku-redis#version-support-and-legacy-infrastructure.

            Source https://stackoverflow.com/questions/66932042

            QUESTION

            BullMQ start Job from file with IIFE
            Asked 2021-Feb-16 at 09:24

            Let's say I have a function1.js (or ts, it doesn't matter in this case),function2.js and any other files which are IIFE with different logic, like that:

            ...

            ANSWER

            Answered 2021-Feb-16 at 09:24

            I have found a relative example in BullMQ docs. Actually, it's called sandbox processors, and only Bull and BullMQ, among any others job queue managers support such feature.

            Other, you'll need to write your own implementation.

            The alternative is using pm2 programmatic API which would manage files manually. In that case, you pass a direct path to file with IIFE, and then it has been executed via pm2.

            Source https://stackoverflow.com/questions/66185655

            Community Discussions, Code Snippets contain sources that include Stack Exchange Network

            Vulnerabilities

            No vulnerabilities reported

            Install bullmq

            You can download it from GitHub.

            Support

            Fork the repo, make some changes, submit a pull-request! Here is the contributing doc that has more details.
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries
            Install
          • PyPI

            pip install bullmq

          • CLONE
          • HTTPS

            https://github.com/taskforcesh/bullmq.git

          • CLI

            gh repo clone taskforcesh/bullmq

          • sshUrl

            git@github.com:taskforcesh/bullmq.git

          • Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link