Changelog
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog and this project adheres to Semantic Versioning.
Unreleased
[0.3.0] — 2018-10-28
Added
- Expiring Job support. Expiring jobs won’t be ran after a configurable amount
of time. The expiration period is set with the
expires_in
option, which accepts millisecond values identically to theunique_for
option. - Connection pooling. Recently added benchmarks quickly identified a bottleneck in the single Client/Redis connection. A simple random-order pool was introduced that allowed the client, queues and reporters to rotate through a set of connections. This change alone doubled the enqueue/dequeue throughput.
- Reliable push support. Enqueued jobs are now buffered in memory and periodically flushed to Redis. If there are any connection errors or Redis is down the jobs are retained and flushing is retried with backoff.
- Sandbox test mode. When
test_mode
is set to:sandbox
jobs will never be flushed to Redis. Each locally buffered job is associated with the process that enqueued it, enabling concurrent testing with isolation between test runs. - Leadership election. Useful when coordinating work that should only happen on a single node. Internally used to prevent duplicate job resurrection, and in the future will be used for periodic jobs.
- Private queues. Ensure terminated jobs are resurrected when the application starts up. Unlike the previous job backup mechanism this guarantees that only jobs from dead processors are resurrected; in-process jobs will never be duplicated.
Changed
- Upgrade from Redix 0.7.X to 0.8.X, which introduced the
noreply_
variant of commands. - Renamed
poll_interval
option toflush_interval
, and the default changed from1000
to500
.
Fixed
- Failing unique jobs would never be retried.
[0.2.0] — 2018-09-17
Added
- Unique Job support. Workers, and their corresponding jobs, can now be made
unique within for a period of time. Until the initial job has succeeded it is
considered “locked” and all subsequent attempts to enqueue a job with the same
class, queue and args will be ignored. The unique period is specified with the
unique_for
option, which accepts millisecond values for easy interaction with the:timer
module’sminutes/1
andseconds/1
functions.
Fixed
- Correctly convert nested modules binaries into the correct worker, i.e.
convert
"Kiq.Workers.Business"
into the moduleKiq.Workers.Business
. - Correctly serialize pid and job payloads when recording a worker’s running jobs for heartbeats. Incorrectly formatted hashes in Redis will cause the Sidekiq “busy” dashboard to crash.
- Retain the original
ran_at
value for reported jobs. Running jobs are now encoded when they are started, preventing repeated JSON encodings and allowing the initialran_at
value to be used when reporting. Prior to this change the job was always reported as being started “Just Now”. - Skip serializing
retry_count
when the value is 0. Sidekiq doesn’t include aretry_count
when there hasn’t been a retry, which prevents the job serialized by Kiq from matching up. If the serialized job doesn’t match up then the job can’t be removed from the backup queue, leading to a buildup of duplicate jobs.
0.1.0 - 2018-07-31
Added
Initial release, everything was added!
- Job creation
- Worker definition
- Running and configuring queues
- Retries
- Scheduled jobs
- Statistics
- Custom reporters
- Testing support
- Heartbeat reporting