|
|
|
@ -124,7 +124,7 @@ UserDataClient userDataClient(grpc::CreateChannel("localhost:50052", grpc::Insec |
|
|
|
|
|
|
|
|
|
//Leaderboard Reported implementation.
|
|
|
|
|
void UserDatabaseReporter::ReportQPS(const ScenarioResult& result) const { |
|
|
|
|
double qps = result.latencies.Count() / |
|
|
|
|
auto qps = result.latencies.Count() / |
|
|
|
|
average(result.client_resources, |
|
|
|
|
[](ResourceUsage u) { return u.wall_time; }); |
|
|
|
|
|
|
|
|
@ -132,13 +132,12 @@ void UserDatabaseReporter::ReportQPS(const ScenarioResult& result) const { |
|
|
|
|
userDataClient.setConfigs(result.client_config, result.server_config); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
void UserDatabaseReporter::ReportQPSPerCore(const ScenarioResult& result, |
|
|
|
|
const ServerConfig& server_config) const { |
|
|
|
|
double qps = result.latencies.Count() / |
|
|
|
|
average(result.client_resources, |
|
|
|
|
[](ResourceUsage u) { return u.wall_time; }); |
|
|
|
|
void UserDatabaseReporter::ReportQPSPerCore(const ScenarioResult& result) const { |
|
|
|
|
auto qps = result.latencies.Count() / |
|
|
|
|
average(result.client_resources, |
|
|
|
|
[](ResourceUsage u) { return u.wall_time; }); |
|
|
|
|
|
|
|
|
|
double qpsPerCore = qps / server_config.threads(); |
|
|
|
|
auto qpsPerCore = qps / result.server_config.threads(); |
|
|
|
|
|
|
|
|
|
userDataClient.setQPSPerCore(qpsPerCore); |
|
|
|
|
userDataClient.setConfigs(result.client_config, result.server_config); |
|
|
|
|