| 194 | |
| 195 | protected: |
| 196 | void initialize() override |
| 197 | { |
| 198 | // Stop when no one cares. |
| 199 | promise.future().onDiscard(lambda::bind( |
| 200 | static_cast<void(*)(const UPID&, bool)>(terminate), self(), true)); |
| 201 | |
| 202 | // Catch-up sequentially. |
| 203 | current = positions.lower(); |
| 204 | |
| 205 | catchup(); |
| 206 | } |
| 207 | |
| 208 | void finalize() override |
| 209 | { |