Download Latest Version v0.24.0 source code.tar.gz (502.7 kB)
Email in envelope

Get an email when there's a new version of River SQL

Home / v0.24.0
Name Modified Size InfoDownloads / Week
Parent folder
README.md 2025-08-16 5.6 kB
v0.24.0 source code.tar.gz 2025-08-16 502.7 kB
v0.24.0 source code.zip 2025-08-16 692.2 kB
Totals: 3 Items   1.2 MB 5

⚠️ Version 0.24.0 has a breaking change in HookWorkEnd.WorkEnd in that a new JobRow parameter has been added to the function's signature. Any intergration defining a custom HookWorkEnd hook should update its implementation so the hook continues to be called correctly.

⚠️ Internal APIs used for communication between River and River Pro have changed. If using River Pro, make sure to update River and River Pro to latest at the same time to get compatible versions. River v0.24.0 is compatible with River Pro v0.16.0.

Added

  • The project now tests against libSQL, a popular SQLite fork. It's used through the same riversqlite driver that SQLite uses. PR [#957]
  • Added JobDeleteMany operations that remove many jobs in a single operation according to input criteria. PR [#962]
  • Added Client.Schema() method to return a client's configured schema. PR [#983].
  • Integrated riverui queries into the driver system to pave the way for multi-driver UI support. PR [#983].
  • Added QueueConfig level FetchCooldown and FetchPollInterval settings to enable queue-specific job fetch intervals. For example, a queue of high-priority jobs could be checked more often to improve responsiveness, while one with slow or time-insensitive tasks could be checked infrequently to reduce database load. PR [#994].

Changed

  • Remove unecessary transactions where a single database operation will do. This reduces the number of subtransactions created which can be an operational benefit it many cases. PR [#950]
  • Bring all driver tests into separate package so they don't leak dependencies. This removes dependencies from the top level river package that most River installations won't need, thereby reducing the transitive dependency load of most River installations. PR [#955].
  • The reindexer maintenance service now reindexes all river_job indexes, including its primary key. This is expected to help in situations where the jobs table has in the past expanded to a very large size (which makes most indexes larger), is now a much more modest size, but has left the indexes in their expanded state. PR [#963].
  • The River CLI now accepts a --target-version of 0 with river migrate-down to run all down migrations and remove all River tables (previously, -1 was used for this; -1 still works, but now 0 also works). PR [#966].
  • Breaking change: The HookWorkEnd interface's WorkEnd function now receives a JobRow parameter in addition to the error it received before. Having a JobRow to work with is fairly crucial to most functionality that a hook would implement, and its previous omission was entirely an error. PR [#970].
  • Add maximum bound to each job's attempted_by array so that in degenerate cases where a job is run many, many times (say it's snoozed hundreds of times), it doesn't grow to unlimited bounds. PR [#974].
  • A logger passed in via river.Config now overrides the default test-based logger when using rivertest.NewWorker. PR [#980].
  • Cleaner retention periods (CancelledJobRetentionPeriod, CompletedJobRetentionPeriod, DiscardedJobRetentionPeriod) can be configured to -1 to disable them so that the corresponding type of job is retained indefinitely. PR [#990].
  • Jobs inserted from periodic jobs with IDs now have metadata river:periodic_job_id set so they can be traced back to the periodic job that inserted them. PR [#992].
  • The unused function WorkerDefaults.Hooks has been removed. This is technically a breaking change, but this function was a vestigal refactoring artifact that was never used by anything, so in practice it shouldn't be breaking. PR [#997].
  • Periodic job records are upserted immediately through a pilot when a client is started rather than the first time their associated job would run. This doesn't mean they're run immediately (they'll only run if RunOnStart is enabled), but rather just tracked immediately. PR [#998].
  • The job scheduler still schedules jobs in batches of up to 10,000, but when it encounters a series of consecutive timeouts it assumes that the database is in a degraded state and switches to doing work in a smaller batch size of 1,000 jobs. PR [#1013].
  • Other maintenance services including the job cleaner, job rescuer, and queue cleaner also prefer a batch size of 10,000, but will fall back to smaller batches of 1,000 on consecutive database timeouts. PR [#1016].

Fixed

  • Cleanly error on invalid schema names in Config.Schema. PR [#952].
  • Jobs rescued by JobRescuer no longer have their trace set to "TODO". This becomes an empty string instead. PR [#1010].
Source: README.md, updated 2025-08-16