storj/satellite/nodeevents
Cameron 08c9d745f1 satellite/nodeevents: take last_attempted into account when selecting
Previously, the node events chore would select based on the earliest
created_at. However, if for some reason this batch fails, it would still
be the next item to select. If there is a consistent error, the chore
would be stuck retrying the same batch over and over. Now instead
GetNextBatch orders by `last_attempted NULLS FIRST ASC, created_at ASC`.
If a batch fails during Notify, last_attempted is updated so we can move
on to a new batch if one exists.

Change-Id: Ia8458e05ac358d85b2f2c6d690f3d607d631be61
2022-12-01 20:08:38 +00:00
..
chore_test.go satellite/nodeevents: take last_attempted into account when selecting 2022-12-01 20:08:38 +00:00
chore.go satellite/nodeevents: take last_attempted into account when selecting 2022-12-01 20:08:38 +00:00
db.go satellite/nodeevents: add method UpdateLastAttempted 2022-12-01 19:38:54 +00:00
mocknotifier.go satellite/nodeevents: add method Name to Type 2022-11-18 12:31:02 +00:00
types.go satellite/nodeevents: add method Name to Type 2022-11-18 12:31:02 +00:00