| 30 | } |
| 31 | |
| 32 | void HeartBeatThread::run() { |
| 33 | static int count = 0; |
| 34 | while (true) { |
| 35 | std::shared_ptr<PhxBinlogClient> client = PhxBinlogClientPlatformInfo::GetDefault()->GetClientFactory() |
| 36 | ->CreateClient(); |
| 37 | int ret = client->HeartBeat(); |
| 38 | if ((count++) % 60 == 0) { |
| 39 | phxsql::LogWarning("%s:%d heartbeat ret %d", __func__, __LINE__, ret); |
| 40 | count = 1; |
| 41 | } |
| 42 | poll(0, 0, 1000); |
| 43 | } |
| 44 | } |
| 45 | |
| 46 | } |
nothing calls this directly
no test coverage detected