From b75b4f1b0d63a83f93870c539201aae486782756 Mon Sep 17 00:00:00 2001 From: semantic-release-bot Date: Mon, 3 May 2021 10:58:29 +0000 Subject: [PATCH] chore(release): 1.24.0 [skip ci] # [1.24.0](https://github.com/taskforcesh/bullmq/compare/v1.23.1...v1.24.0) (2021-05-03) ### Features * add option for non-blocking getNextJob ([13ce2cf](https://github.com/taskforcesh/bullmq/commit/13ce2cfd4ccd64f45567df31de11af95b0fe67d9)) --- docs/gitbook/CHANGELOG.md | 7 +++++++ .../api/bullmq.getnextjoboptions.block.md | 11 +++++++++++ docs/gitbook/api/bullmq.getnextjoboptions.md | 18 ++++++++++++++++++ docs/gitbook/api/bullmq.md | 1 + docs/gitbook/api/bullmq.worker.getnextjob.md | 3 ++- docs/gitbook/api/bullmq.worker.md | 2 +- package.json | 2 +- 7 files changed, 41 insertions(+), 3 deletions(-) create mode 100644 docs/gitbook/api/bullmq.getnextjoboptions.block.md create mode 100644 docs/gitbook/api/bullmq.getnextjoboptions.md diff --git a/docs/gitbook/CHANGELOG.md b/docs/gitbook/CHANGELOG.md index cb3f66235d..7354738da3 100644 --- a/docs/gitbook/CHANGELOG.md +++ b/docs/gitbook/CHANGELOG.md @@ -1,3 +1,10 @@ +# [1.24.0](https://github.com/taskforcesh/bullmq/compare/v1.23.1...v1.24.0) (2021-05-03) + + +### Features + +* add option for non-blocking getNextJob ([13ce2cf](https://github.com/taskforcesh/bullmq/commit/13ce2cfd4ccd64f45567df31de11af95b0fe67d9)) + ## [1.23.1](https://github.com/taskforcesh/bullmq/compare/v1.23.0...v1.23.1) (2021-05-03) diff --git a/docs/gitbook/api/bullmq.getnextjoboptions.block.md b/docs/gitbook/api/bullmq.getnextjoboptions.block.md new file mode 100644 index 0000000000..b3042f3e88 --- /dev/null +++ b/docs/gitbook/api/bullmq.getnextjoboptions.block.md @@ -0,0 +1,11 @@ + + +[Home](./index.md) > [bullmq](./bullmq.md) > [GetNextJobOptions](./bullmq.getnextjoboptions.md) > [block](./bullmq.getnextjoboptions.block.md) + +## GetNextJobOptions.block property + +Signature: + +```typescript +block?: boolean; +``` diff --git a/docs/gitbook/api/bullmq.getnextjoboptions.md b/docs/gitbook/api/bullmq.getnextjoboptions.md new file mode 100644 index 0000000000..b0e86fba7b --- /dev/null +++ b/docs/gitbook/api/bullmq.getnextjoboptions.md @@ -0,0 +1,18 @@ + + +[Home](./index.md) > [bullmq](./bullmq.md) > [GetNextJobOptions](./bullmq.getnextjoboptions.md) + +## GetNextJobOptions interface + +Signature: + +```typescript +export interface GetNextJobOptions +``` + +## Properties + +| Property | Type | Description | +| --- | --- | --- | +| [block?](./bullmq.getnextjoboptions.block.md) | boolean | (Optional) | + diff --git a/docs/gitbook/api/bullmq.md b/docs/gitbook/api/bullmq.md index 2acc777993..dbb9fb8213 100644 --- a/docs/gitbook/api/bullmq.md +++ b/docs/gitbook/api/bullmq.md @@ -43,6 +43,7 @@ | [BackoffOptions](./bullmq.backoffoptions.md) | Settings for backing off failed jobs. | | [ChildProcessExt](./bullmq.childprocessext.md) | | | [FlowJob](./bullmq.flowjob.md) | | +| [GetNextJobOptions](./bullmq.getnextjoboptions.md) | | | [JobJson](./bullmq.jobjson.md) | | | [JobJsonRaw](./bullmq.jobjsonraw.md) | | | [JobNode](./bullmq.jobnode.md) | | diff --git a/docs/gitbook/api/bullmq.worker.getnextjob.md b/docs/gitbook/api/bullmq.worker.getnextjob.md index b3d22c06b2..36e829ee30 100644 --- a/docs/gitbook/api/bullmq.worker.getnextjob.md +++ b/docs/gitbook/api/bullmq.worker.getnextjob.md @@ -9,7 +9,7 @@ Returns a promise that resolves to the next job in queue. Signature: ```typescript -getNextJob(token: string): Promise>; +getNextJob(token: string, { block }?: GetNextJobOptions): Promise>; ``` ## Parameters @@ -17,6 +17,7 @@ getNextJob(token: string): Promise>; | Parameter | Type | Description | | --- | --- | --- | | token | string | worker token to be assigned to retrieved job | +| { block } | [GetNextJobOptions](./bullmq.getnextjoboptions.md) | | Returns: diff --git a/docs/gitbook/api/bullmq.worker.md b/docs/gitbook/api/bullmq.worker.md index 6473717352..25ad37e9e7 100644 --- a/docs/gitbook/api/bullmq.worker.md +++ b/docs/gitbook/api/bullmq.worker.md @@ -29,7 +29,7 @@ export declare class Worker extends | Method | Modifiers | Description | | --- | --- | --- | | [close(force)](./bullmq.worker.close.md) | | | -| [getNextJob(token)](./bullmq.worker.getnextjob.md) | | Returns a promise that resolves to the next job in queue. | +| [getNextJob(token, { block })](./bullmq.worker.getnextjob.md) | | Returns a promise that resolves to the next job in queue. | | [isPaused()](./bullmq.worker.ispaused.md) | | | | [pause(doNotWaitActive)](./bullmq.worker.pause.md) | | Pauses the processing of this queue only for this worker. | | [processJob(job, token)](./bullmq.worker.processjob.md) | | | diff --git a/package.json b/package.json index 3529767255..f9533daf58 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "bullmq", - "version": "1.23.1", + "version": "1.24.0", "description": "Queue for messages and jobs based on Redis", "main": "dist/index.js", "types": "dist/index.d.ts",