# fast-job-queue

> Create And Manage Your jobs fast in queue.

Latest version **1.0.6** (published 2019-07-31) · ISC license · 0 weekly downloads

## Install

```sh
npm install fast-job-queue
pnpm add fast-job-queue
yarn add fast-job-queue
bun add fast-job-queue
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.6 |
| Published | 2019-07-31 |
| First published | 2019-07-21 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 5.1 KB |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Madhav Palshikar |
| Maintainers | madhavwrite |
| Keywords | Fast, Job, Queue |

## Links

- npm: https://www.npmjs.com/package/fast-job-queue
- Repository: https://github.com/madhavpalshikar/fast-job-queue
- Homepage: https://github.com/madhavpalshikar/fast-job-queue#readme
- Issues: https://github.com/madhavpalshikar/fast-job-queue/issues
- npm.io page: https://npm.io/package/fast-job-queue

## Dependencies (1)

- [redis](https://npm.io/package/redis.md) ^2.8.0

## Alternatives

- [cron](https://npm.io/package/cron.md) — 4.9M weekly downloads
- [@vercel/queue](https://npm.io/package/@vercel/queue.md) — 731.6K weekly downloads
- [create-sonicjs](https://npm.io/package/create-sonicjs.md) — 1.6K weekly downloads
- [@exellix/jobs-api](https://npm.io/package/@exellix/jobs-api.md) — 941 weekly downloads
- [@forwardimpact/libskill](https://npm.io/package/@forwardimpact/libskill.md) — 575 weekly downloads

## Recent versions

- 1.0.6 (latest) — 2019-07-31
- 1.0.5 — 2019-07-22
- 1.0.4 — 2019-07-22
- 1.0.3 — 2019-07-22
- 1.0.2 — 2019-07-21
- 1.0.1 — 2019-07-21
- 1.0.0 — 2019-07-21

## README

# fast-job-queue
Fast and simple create and manage your jobs/task in queue for NodeJs with redis.

## Adding and initializing fast-job-queue
1. Download with npm

    ```js 
    npm install fast-job-queue 
    ```

2. then, initialize it..

    ```js
    const fastQueue = require('fast-job-queue');
    const job = new fastQueue({retry: 3});
    ```
## Adding new Job or Task to queue
3. then, create job
    ```js
    job.createJob({title: "my Job", value: 1});
    ```

## Receiving Job to process
4. then, 
    ```js
    job.on("process", (jobdata, done, failed) => {
        
        // do your task here
        // once job is completed call done method on job
        if(success){
            done();
        }
        else{
            // failed job will got to queue again for retry 
            // if retry limit is set in settings.
            failed();
        }

    })
    ```

## On Job complete 
5. you can catch completed job here
    ```js
    job.on("complete", (data) => {
        console.log("Job completed!", data);
    })
    ```

---
_Source: https://npm.io/package/fast-job-queue · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
