This repository has been archived by the owner on Jan 6, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 206
/
checkpoint.clj
66 lines (50 loc) · 1.69 KB
/
checkpoint.clj
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
(ns onyx.checkpoint
"Onyx checkpoint interfaces.")
(defmulti storage :onyx.peer/storage)
; State storage interfaces
(defmulti write-checkpoint
(fn [storage tenancy-id job-id replica-version epoch task-id slot-id checkpoint-type checkpoint]
(type storage)))
(defmulti cancel!
(fn [storage]
(type storage)))
(defmulti stop
(fn [storage]
(type storage)))
(defmulti complete?
(fn [storage]
(type storage)))
(defmulti read-checkpoint
(fn [storage tenancy-id job-id replica-version epoch task-id slot-id checkpoint-type]
(type storage)))
(defmulti gc-checkpoint!
(fn [storage tenancy-id job-id replica-version epoch task-id slot-id checkpoint-type]
(type storage)))
(defmulti write-replica-epoch-low-watermark
(fn [storage tenancy-id job-id replica-version min-epoch]
(type storage)))
(defmulti read-replica-epoch-low-watermark
(fn [storage tenancy-id job-id replica-version]
(type storage)))
(defmulti write-replica-epoch-watermark
(fn [storage tenancy-id job-id replica-version epoch task-data]
(type storage)))
(defmulti read-all-replica-epoch-watermarks
(fn [storage tenancy-id job-id]
(type storage)))
(defmulti gc-replica-epoch-watermark!
(fn [storage tenancy-id job-id replica-version]
(type storage)))
; Consistent coordinate write interfaces
(defmulti write-checkpoint-coordinate
(fn [storage tenancy-id job-id coordinate version]
(type storage)))
(defmulti watch-checkpoint-coordinate
(fn [storage tenancy-id job-id watcher]
(type storage)))
(defmulti read-checkpoint-coordinate
(fn [storage tenancy-id job-id]
(type storage)))
(defmulti assume-checkpoint-coordinate
(fn [storage tenancy-id job-id]
(type storage)))