@@ -190,65 +190,6 @@ class OplogApplier {
190
190
StatusWith<OpTime> multiApply (OperationContext* opCtx, Operations ops);
191
191
192
192
const Options& getOptions () const ;
193
- /* *
194
- * Step-up
195
- * =======
196
- * On stepup, repl coord enters catch-up mode. It's the same as the secondary mode from
197
- * the perspective of producer and applier, so there's nothing to do with them.
198
- * When a node enters drain mode, producer state = Stopped, applier state = Draining.
199
- *
200
- * If the applier state is Draining, it will signal repl coord when there's nothing to apply.
201
- * The applier goes into Stopped state at the same time.
202
- *
203
- * The states go like the following:
204
- * - secondary and during catchup mode
205
- * (producer: Running, applier: Running)
206
- * |
207
- * | finish catch-up, enter drain mode
208
- * V
209
- * - drain mode
210
- * (producer: Stopped, applier: Draining)
211
- * |
212
- * | applier signals drain is complete
213
- * V
214
- * - primary is in master mode
215
- * (producer: Stopped, applier: Stopped)
216
- *
217
- *
218
- * Step-down
219
- * =========
220
- * The state transitions become:
221
- * - primary is in master mode
222
- * (producer: Stopped, applier: Stopped)
223
- * |
224
- * | step down
225
- * V
226
- * - secondary mode, starting bgsync
227
- * (producer: Starting, applier: Running)
228
- * |
229
- * | bgsync runs start()
230
- * V
231
- * - secondary mode, normal
232
- * (producer: Running, applier: Running)
233
- *
234
- * When a node steps down during draining mode, it's OK to change from (producer: Stopped,
235
- * applier: Draining) to (producer: Starting, applier: Running).
236
- *
237
- * When a node steps down during catchup mode, the states remain the same (producer: Running,
238
- * applier: Running).
239
- */
240
- enum class ApplierState { Running, Draining, Stopped };
241
-
242
- /* *
243
- * In normal cases: Running -> Draining -> Stopped -> Running.
244
- * Draining -> Running is also possible if a node steps down during drain mode.
245
- *
246
- * Only the applier can make the transition from Draining to Stopped by calling
247
- * signalDrainComplete().
248
- */
249
- virtual ApplierState getApplierState () const ;
250
-
251
- virtual void setApplierState (ApplierState st);
252
193
253
194
private:
254
195
/* *
@@ -287,8 +228,6 @@ class OplogApplier {
287
228
288
229
// Configures this OplogApplier.
289
230
const Options _options;
290
-
291
- ApplierState _applierState = ApplierState::Running;
292
231
};
293
232
294
233
/* *
0 commit comments