| 464 | } |
| 465 | |
| 466 | Future<bool> recover(const Metadata::Status& status) |
| 467 | { |
| 468 | LOG(INFO) << "Replica is in " << status << " status"; |
| 469 | |
| 470 | if (status == Metadata::VOTING) { |
| 471 | // No need to do recovery. |
| 472 | return true; |
| 473 | } else { |
| 474 | return runRecoverProtocol(quorum, network, status, autoInitialize) |
| 475 | .then(defer(self(), &Self::_recover, lambda::_1)); |
| 476 | } |
| 477 | } |
| 478 | |
| 479 | Future<bool> _recover(const Option<RecoverResponse>& result) |
| 480 | { |
nothing calls this directly
no test coverage detected