| 77 | } |
| 78 | |
| 79 | void KeepSyncThread::DoRun() { |
| 80 | if (!impl_->store) { |
| 81 | return; |
| 82 | } |
| 83 | |
| 84 | const int ngroup = impl_->store->GetStoreOption()->ngroup; |
| 85 | impl_->next_make_cp_times.reset(new time_t[ngroup]); |
| 86 | impl_->next_sync_times.reset(new time_t[ngroup]); |
| 87 | for (int i{0}; i < ngroup; ++i) { |
| 88 | impl_->next_make_cp_times[i] = 0; |
| 89 | impl_->next_sync_times[i] = 0; |
| 90 | } |
| 91 | |
| 92 | while (1) { |
| 93 | if (impl_->stop) return; |
| 94 | |
| 95 | sleep(1); |
| 96 | |
| 97 | ClearSyncCtrl(); |
| 98 | |
| 99 | MakeCheckPoint(); |
| 100 | |
| 101 | SyncCursorID(); |
| 102 | |
| 103 | Replay(); |
| 104 | |
| 105 | ReportBacklog(); |
| 106 | |
| 107 | ReportDelayStat(); |
| 108 | } |
| 109 | } |
| 110 | |
| 111 | void KeepSyncThread::ClearSyncCtrl() { |
| 112 | QLVerb("KeepSyncThread::ClearSyncCtrl"); |
nothing calls this directly
no test coverage detected