anbaric 1.56.6 → 1.56.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -348,6 +348,13 @@ Storage comes from `JobRunSchedulePersistenceFactory` — in memory locally, the
|
|
|
348
348
|
platform database when deployed, where claiming a due run is atomic so several
|
|
349
349
|
instances can schedule the same machines safely.
|
|
350
350
|
|
|
351
|
+
Claiming coalesces: when more than one of a machine's runs has come due — the
|
|
352
|
+
scheduler was down, a deploy took a while — only the most recent is claimed
|
|
353
|
+
and started, and the earlier ones are recorded as **superseded** by it
|
|
354
|
+
(`superseded_at` and `superseded_by` on the stored run). The consumer is sent
|
|
355
|
+
one catch-up job, never one per missed tick. Runs of different machines, or
|
|
356
|
+
of the same machine in different apps, are never coalesced with each other.
|
|
357
|
+
|
|
351
358
|
---
|
|
352
359
|
|
|
353
360
|
## `Actor`
|
|
@@ -53,10 +53,14 @@ runs as they come due. Two things follow from that, both deliberate:
|
|
|
53
53
|
|
|
54
54
|
- **A restart doesn't lose the timetable.** The plan is already stored, so the
|
|
55
55
|
scheduler picks up where it left off.
|
|
56
|
-
- **Downtime doesn't silently skip runs
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
56
|
+
- **Downtime doesn't silently skip runs — and doesn't replay them either.** A
|
|
57
|
+
scheduler that was down for two days starts **one** catch-up run as soon as
|
|
58
|
+
it comes back: the most recent run it missed. The earlier missed runs are
|
|
59
|
+
recorded as superseded by it, so the timetable shows what was skipped and
|
|
60
|
+
why, but an hourly sync that missed a day never becomes twenty-four syncs
|
|
61
|
+
fired in the same second. The job's `scheduledFor` tells you which run it
|
|
62
|
+
is; if a machine must not catch up at all, make its action check that and
|
|
63
|
+
return early.
|
|
60
64
|
|
|
61
65
|
Every scheduled job carries the run it belongs to:
|
|
62
66
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "anbaric",
|
|
3
|
-
"version": "1.56.
|
|
3
|
+
"version": "1.56.7",
|
|
4
4
|
"description": "Everything needed to write an Anbaric app: state machines, jobs, document and secret stores, local in-memory implementations and the Anbaric Cloud clients",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -24,9 +24,9 @@
|
|
|
24
24
|
"prepublishOnly": "npm run build"
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
|
-
"anbaric-impl-cloud": "^1.56.
|
|
28
|
-
"anbaric-data-store": "^1.56.
|
|
29
|
-
"anbaric-state-machine": "^1.56.
|
|
30
|
-
"anbaric-tsapi": "^1.56.
|
|
27
|
+
"anbaric-impl-cloud": "^1.56.7",
|
|
28
|
+
"anbaric-data-store": "^1.56.7",
|
|
29
|
+
"anbaric-state-machine": "^1.56.7",
|
|
30
|
+
"anbaric-tsapi": "^1.56.7"
|
|
31
31
|
}
|
|
32
32
|
}
|