MCPcopy Create free account
hub / github.com/Tencent/phxqueue / RawGetLockInfo

Method RawGetLockInfo

phxqueue/scheduler/scheduler.cpp:188–209  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

186}
187
188comm::RetCode Scheduler::RawGetLockInfo(comm::proto::GetLockInfoRequest &req,
189 comm::proto::GetLockInfoResponse &resp) {
190 lock::LockMasterClient<comm::proto::GetLockInfoRequest, comm::proto::GetLockInfoResponse>
191 lock_master_client;
192 comm::RetCode ret{lock_master_client.ClientCall(req, resp,
193 bind(&Scheduler::GetLockInfo, this, placeholders::_1, placeholders::_2))};
194 if (comm::RetCode::RET_OK != ret) {
195 comm::SchedulerBP::GetThreadInstance()->OnGetLockInfoFail(req);
196 QLErr("SchedulerMasterClient::ClientCall ret %d", as_integer(ret));
197 }
198
199 if (comm::RetCode::RET_OK != ret) {
200 QLErr("Add ret %d", as_integer(ret));
201 return ret;
202 }
203
204 comm::SchedulerBP::GetThreadInstance()->OnGetLockInfoSucc(req, resp);
205
206 QLVerb("RawGetLockInfo succ");
207
208 return comm::RetCode::RET_OK;
209}
210
211comm::RetCode Scheduler::RawAcquireLock(comm::proto::AcquireLockRequest &req,
212 comm::proto::AcquireLockResponse &resp) {

Callers 1

KeepMasterMethod · 0.80

Calls 4

as_integerFunction · 0.85
ClientCallMethod · 0.80
OnGetLockInfoFailMethod · 0.80
OnGetLockInfoSuccMethod · 0.80

Tested by

no test coverage detected