| 47 | } |
| 48 | |
| 49 | int DataManager::SendEvent(const string &oldgtid, const string &newgtid, const string &event_buffer) { |
| 50 | STATISTICS(MySqlBinlogSend()); |
| 51 | PhxTimer timer; |
| 52 | if (event_buffer.size() == 0) { |
| 53 | ColorLogWarning("send event value empty fail"); |
| 54 | return BUFFER_FAIL; |
| 55 | } |
| 56 | int ret = event_agent_->SendValue(oldgtid, newgtid, event_buffer); |
| 57 | if (ret != OK) { |
| 58 | STATISTICS(MySqlBinlogSendFail()); |
| 59 | ColorLogError("send value fail %d", ret); |
| 60 | } |
| 61 | STATISTICS(MySqlSendEventTime(timer.GetTime())); |
| 62 | return ret; |
| 63 | } |
| 64 | |
| 65 | int DataManager::GetLastSendGTID(const string &uuid, string *gtid) { |
| 66 | STATISTICS(MySqlGetLastGTID()); |
nothing calls this directly
no test coverage detected