MCPcopy Create free account
hub / github.com/apache/impala / Run

Method Run

be/src/kudu/rpc/rpc-bench.cc:157–174  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

155 }
156
157 void Run() {
158 shared_ptr<Messenger> client_messenger;
159 CHECK_OK(bench_->CreateMessenger("Client", &client_messenger));
160
161 CalculatorServiceProxy p(client_messenger, bench_->server_addr_, "localhost");
162
163 AddRequestPB req;
164 AddResponsePB resp;
165 while (Acquire_Load(&bench_->should_run_)) {
166 req.set_x(request_count_);
167 req.set_y(request_count_);
168 RpcController controller;
169 controller.set_timeout(MonoDelta::FromSeconds(10));
170 CHECK_OK(p.Add(req, &resp, &controller));
171 CHECK_EQ(req.x() + req.y(), resp.result());
172 request_count_++;
173 }
174 }
175
176 unique_ptr<thread> thread_;
177 RpcBench *bench_;

Callers

nothing calls this directly

Calls 5

CreateMessengerMethod · 0.80
Acquire_LoadFunction · 0.50
set_timeoutMethod · 0.45
AddMethod · 0.45
resultMethod · 0.45

Tested by

no test coverage detected