MCPcopy Create free account
hub / github.com/catboost/catboost / RunSlave

Method RunSlave

library/cpp/par/par_remote.cpp:239–257  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

237 }
238
239 void TRemoteQueryProcessor::RunSlave(int port) {
240 Y_ASSERT(Requester.Get() == nullptr);
241
242 RegisterCmdType("init", InitCmd.Get());
243 RegisterCmdType("ping", PingCmd.Get());
244 RegisterCmdType("run_ping", RunPingCmd.Get());
245 RegisterCmdType("exec_plan", SetExecPlanCmd.Get());
246 RegisterCmdType("stop", StopSlaveCmd.Get());
247 RegisterCmdType("gather_stats", GatherStatsCmd.Get());
248
249 SetRequester(CreateRequester(
250 port,
251 [this](const TGUID& canceledReq) { QueryCancelCallback(canceledReq); },
252 [this](TAutoPtr<TNetworkRequest>& nlReq) { IncomingQueryCallback(nlReq); },
253 [this](TAutoPtr<TNetworkResponse> response) { ReplyCallback(response); }));
254 Y_ABORT_UNLESS(Requester.Get());
255 SlaveFinish.Reset();
256 SlaveFinish.Wait();
257 }
258
259 void TRemoteQueryProcessor::StopSlaves() {
260 TIntrusivePtr<TMetaRequester> mr(new TMetaRequester(this));

Callers 1

RunSlaveFunction · 0.80

Calls 4

CreateRequesterFunction · 0.85
GetMethod · 0.45
ResetMethod · 0.45
WaitMethod · 0.45

Tested by

no test coverage detected