Skip to content

Releases: hibiken/asynq

v0.24.1

01 May 13:50
Compare
Choose a tag to compare

Changed

  • Updated package version dependency for go-redis

v0.24.0

02 Jan 22:57
Compare
Choose a tag to compare

Added

  • PreEnqueueFunc, PostEnqueueFunc is added in Scheduler and deprecated EnqueueErrorHandler (PR: #476)

Changed

  • Removed error log when Scheduler failed to enqueue a task. Use PostEnqueueFunc to check for errors and task actions if needed.
  • Changed log level from ERROR to WARNINING when Scheduler failed to record SchedulerEnqueueEvent.

v0.23.0

12 Apr 00:03
Compare
Choose a tag to compare

This version adds Task Aggregation feature and includes a few improvements and fixes.

Task Aggregation

This is a new feature which allows you to enqueue multiple tasks successively, and have them passed to the Handler together rather than individually. The feature allows you to batch multiple successive operations into one, in order to save on costs, optimize caching, or batch notifications, for example. See the Wiki page for details.


Added

  • Group option is introduced to enqueue task in a group.
  • GroupAggregator and related types are introduced for task aggregation feature.
  • GroupGracePeriod, GroupMaxSize, GroupMaxDelay, and GroupAggregator fields are added to Config.
  • Inspector has new methods related to "aggregating tasks".
  • Group field is added to TaskInfo.
  • (CLI): group ls command is added
  • (CLI): task ls supports listing aggregating tasks via --state=aggregating --group=<GROUP> flags
  • Enable rediss url parsing support: Thanks to @eleboucher

Fixed

  • Fixed overflow issue with 32-bit systems (For details, see #426): Thanks to @assimon!

v0.22.1

20 Feb 14:24
Compare
Choose a tag to compare

Fixed

  • Fixed Redis version compatibility: Keep support for redis v4.0+ (See issue #401 for details).

v0.22.0

19 Feb 14:28
Compare
Choose a tag to compare

This version improves worker crash recovery by introducing a concept of worker lease for an active task.
It also adds an optional field to Config to customize the context passed to the Handler.

Important Note:
Since this version changes the logic of crash recovery, update of the library version should be done with a clean restart of the process.
In other words, please make sure that the process running asynq.Server shutdown cleanly before restarting the process with this new version.

Added

  • BaseContext is introduced in Config to specify callback hook to provide a base context from which Handler context is derived
  • IsOrphaned field is added to TaskInfo to describe a task left in active state with no worker processing it.

Changed

  • Server now recovers tasks with an expired lease. Recovered tasks are retried/archived with ErrLeaseExpired error.

v0.21.0

22 Jan 14:20
Compare
Choose a tag to compare

Added

  • PeriodicTaskManager is added. Prefer using this over Scheduler as it has better support for dynamic periodic tasks. See the wiki page for an example of using PeriodicTaskManager
  • The asynq stats command now supports a --json option, making its output a JSON object
  • Introduced new configuration for DelayedTaskCheckInterval. See godoc for more details.

v0.20.0

19 Dec 15:05
Compare
Choose a tag to compare

This release includes changes to support Prometheus integration in the Web UI. The integration is optional, there shouldn't be any changes in performance or behavior of the library in this release.

Added

  • Package x/metrics is added.
  • Tool tools/metrics_exporter binary is added.
  • ProcessedTotal and FailedTotal fields were added to QueueInfo struct.

v0.19.1

12 Dec 14:18
Compare
Choose a tag to compare

This release includes a few additions and one fix.

Added

  • Latency field is added to QueueInfo.
  • EnqueueContext method is added to Client.

Fixed

  • Fixed an error when user pass a duration less than 1s to Unique option

v0.19.0

06 Nov 22:27
Compare
Choose a tag to compare

This release includes an introduction of task retention after successful processing. With Retention option, you can specify how long the task should be retained in the queue as a completed task.

Changed

  • NewTask takes Option as variadic argument
  • Bumped minimum supported go version to 1.14 (i.e. go1.14 or higher is required).

Added

  • Retention option is added to allow user to specify task retention duration after completion.
  • TaskID option is added to allow user to specify task ID.
  • ErrTaskIDConflict sentinel error value is added.
  • ResultWriter type is added and provided through Task.ResultWriter method.
  • TaskInfo has new fields CompletedAt, Result and Retention.

Removed

  • Client.SetDefaultOptions is removed. Use NewTask instead to pass default options for tasks.

v0.18.6

03 Oct 12:57
Compare
Choose a tag to compare

This release fixes CLI import issue

Changed

  • Updated github.com/go-redis/redis version to v8

Fixes

  • Fixes tool import issue described in #325