Skip to content

Commit

Permalink
Release v2.15.3
Browse files Browse the repository at this point in the history
  • Loading branch information
sorentwo committed Aug 4, 2023
1 parent a11497a commit 6e12c98
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 2 deletions.
30 changes: 30 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,36 @@ other databases. There's even an [open issue for MySQL support][mysql]...

[mysql]: https://github.com/sorentwo/oban/issues/836

## v2.15.3 — 2023-08-04

### Enhancements

- [Pruner] Prune jobs using the `scheduled_at` timestamp regardless of state.

The previous pruning query checked a different timestamp field for each prunable state, e.g.
`cancelled` used `cancelled_at`. There aren't any indexes for those timestamps, let alone the
combination of each state and timestamp, which led to slow pruning queries in larger databases.

In a database with a mixture of ~1.2m prunable jobs the updated query is 130x faster, reducing
the query time from 177ms down to 1.3ms.

- [Lite] Avoid unnecessary transactions during staging and pruning operations

Contention between SQLite3 transactions causes deadlocks that lead to period errors. Avoiding
transactions when there isn't anything to write minimizes contention.

### Bug Fixes

- [Foreman] Explicitly pause queues when shutdown begins.

A call to `Producer.shutdown/1` was erroneously removed during the `DynamicSupervisor` queue
refactor.

- [Job] Preserve explicit state set along with `scheduled_in` time.

The presence of a `scheduled_in` timestamp would always set the state to `scheduled`, even when
an explicit state was passed.

## v2.15.2 — 2023-06-22

### Enhancements
Expand Down
2 changes: 1 addition & 1 deletion guides/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ dependencies in `mix.exs`:
# mix.exs
def deps do
[
{:oban, "~> 2.14"}
{:oban, "~> 2.15"}
]
end
```
Expand Down
2 changes: 1 addition & 1 deletion mix.exs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ defmodule Oban.MixProject do
use Mix.Project

@source_url "https://github.com/sorentwo/oban"
@version "2.15.2"
@version "2.15.3"

def project do
[
Expand Down

0 comments on commit 6e12c98

Please sign in to comment.