Jan Tattermusch | 7897ae9 | 2017-06-07 22:57:36 +0200 | [diff] [blame] | 1 | # Copyright 2017 gRPC authors. |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 2 | # |
Jan Tattermusch | 7897ae9 | 2017-06-07 22:57:36 +0200 | [diff] [blame] | 3 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 | # you may not use this file except in compliance with the License. |
| 5 | # You may obtain a copy of the License at |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 6 | # |
Jan Tattermusch | 7897ae9 | 2017-06-07 22:57:36 +0200 | [diff] [blame] | 7 | # http://www.apache.org/licenses/LICENSE-2.0 |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 8 | # |
Jan Tattermusch | 7897ae9 | 2017-06-07 22:57:36 +0200 | [diff] [blame] | 9 | # Unless required by applicable law or agreed to in writing, software |
| 10 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 11 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 | # See the License for the specific language governing permissions and |
| 13 | # limitations under the License. |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 14 | |
Jan Tattermusch | 4d5c310 | 2017-06-07 10:23:56 +0200 | [diff] [blame] | 15 | licenses(["notice"]) # Apache v2 |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 16 | |
Nicolas "Pixel" Noble | 2bc5e3a | 2017-08-15 22:32:52 +0200 | [diff] [blame] | 17 | load("//bazel:grpc_build_system.bzl", "grpc_cc_test", "grpc_cc_library", "grpc_cc_binary", "grpc_package") |
Nicolas "Pixel" Noble | 7c26eed | 2017-04-13 01:40:54 +0200 | [diff] [blame] | 18 | |
Nicolas "Pixel" Noble | 2bc5e3a | 2017-08-15 22:32:52 +0200 | [diff] [blame] | 19 | grpc_package(name = "test/cpp/qps") |
Nicolas "Pixel" Noble | af6c83f | 2017-05-19 00:38:10 +0200 | [diff] [blame] | 20 | |
Nicolas "Pixel" Noble | 7c26eed | 2017-04-13 01:40:54 +0200 | [diff] [blame] | 21 | grpc_cc_library( |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 22 | name = "parse_json", |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 23 | srcs = ["parse_json.cc"], |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 24 | hdrs = ["parse_json.h"], |
Nicolas "Pixel" Noble | 78f8ce3 | 2017-05-11 00:42:55 +0200 | [diff] [blame] | 25 | external_deps = ["protobuf"], |
Bill Feng | 373c5b3 | 2018-08-20 10:55:49 -0700 | [diff] [blame] | 26 | deps = ["//:grpc++"], |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 27 | ) |
| 28 | |
Nicolas "Pixel" Noble | 7c26eed | 2017-04-13 01:40:54 +0200 | [diff] [blame] | 29 | grpc_cc_library( |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 30 | name = "qps_worker_impl", |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 31 | srcs = [ |
| 32 | "client_async.cc", |
| 33 | "client_sync.cc", |
Bill Feng | 373c5b3 | 2018-08-20 10:55:49 -0700 | [diff] [blame] | 34 | "qps_server_builder.cc", |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 35 | "qps_worker.cc", |
| 36 | "server_async.cc", |
| 37 | "server_sync.cc", |
| 38 | ], |
| 39 | hdrs = [ |
| 40 | "client.h", |
Bill Feng | 373c5b3 | 2018-08-20 10:55:49 -0700 | [diff] [blame] | 41 | "qps_server_builder.h", |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 42 | "qps_worker.h", |
| 43 | "server.h", |
Bill Feng | 373c5b3 | 2018-08-20 10:55:49 -0700 | [diff] [blame] | 44 | ], |
| 45 | external_deps = [ |
| 46 | "gflags", |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 47 | ], |
| 48 | deps = [ |
Nicolas "Pixel" Noble | b02dd01 | 2017-03-24 18:45:22 +0100 | [diff] [blame] | 49 | ":histogram", |
| 50 | ":interarrival", |
| 51 | ":usage_timer", |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 52 | "//:grpc", |
| 53 | "//:grpc++", |
Craig Tiller | e1101cf | 2017-09-06 09:42:20 -0700 | [diff] [blame] | 54 | "//:grpc++_core_stats", |
kpayson64 | 7a20c96 | 2018-04-18 15:19:55 -0700 | [diff] [blame] | 55 | "//src/proto/grpc/testing:benchmark_service_proto", |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 56 | "//src/proto/grpc/testing:control_proto", |
| 57 | "//src/proto/grpc/testing:payloads_proto", |
kpayson64 | 7a20c96 | 2018-04-18 15:19:55 -0700 | [diff] [blame] | 58 | "//src/proto/grpc/testing:worker_service_proto", |
Nicolas "Pixel" Noble | b02dd01 | 2017-03-24 18:45:22 +0100 | [diff] [blame] | 59 | "//test/core/end2end:ssl_test_data", |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 60 | "//test/core/util:gpr_test_util", |
| 61 | "//test/core/util:grpc_test_util", |
Alex Polcyn | 92e0a70 | 2018-07-21 07:38:34 +0000 | [diff] [blame] | 62 | "//test/cpp/util:test_config", |
Bill Feng | 373c5b3 | 2018-08-20 10:55:49 -0700 | [diff] [blame] | 63 | "//test/cpp/util:test_util", |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 64 | ], |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 65 | ) |
| 66 | |
Nicolas "Pixel" Noble | 7c26eed | 2017-04-13 01:40:54 +0200 | [diff] [blame] | 67 | grpc_cc_library( |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 68 | name = "driver_impl", |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 69 | srcs = [ |
| 70 | "driver.cc", |
| 71 | "report.cc", |
| 72 | ], |
| 73 | hdrs = [ |
| 74 | "driver.h", |
| 75 | "report.h", |
| 76 | ], |
| 77 | deps = [ |
Nicolas "Pixel" Noble | b02dd01 | 2017-03-24 18:45:22 +0100 | [diff] [blame] | 78 | ":histogram", |
| 79 | ":parse_json", |
| 80 | ":qps_worker_impl", |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 81 | "//:grpc++", |
| 82 | "//src/proto/grpc/testing:control_proto", |
Nicolas "Pixel" Noble | b02dd01 | 2017-03-24 18:45:22 +0100 | [diff] [blame] | 83 | "//src/proto/grpc/testing:messages_proto", |
kpayson64 | 7a20c96 | 2018-04-18 15:19:55 -0700 | [diff] [blame] | 84 | "//src/proto/grpc/testing:report_qps_scenario_service_proto", |
| 85 | "//src/proto/grpc/testing:worker_service_proto", |
Nicolas "Pixel" Noble | b02dd01 | 2017-03-24 18:45:22 +0100 | [diff] [blame] | 86 | "//test/core/util:gpr_test_util", |
| 87 | "//test/core/util:grpc_test_util", |
Guantao Liu | abe3cf5 | 2017-07-12 17:36:30 -0700 | [diff] [blame] | 88 | "//test/cpp/util:test_util", |
Nicolas "Pixel" Noble | b02dd01 | 2017-03-24 18:45:22 +0100 | [diff] [blame] | 89 | ], |
| 90 | ) |
| 91 | |
Nicolas "Pixel" Noble | 7c26eed | 2017-04-13 01:40:54 +0200 | [diff] [blame] | 92 | grpc_cc_library( |
Nicolas "Pixel" Noble | b02dd01 | 2017-03-24 18:45:22 +0100 | [diff] [blame] | 93 | name = "benchmark_config", |
| 94 | srcs = [ |
| 95 | "benchmark_config.cc", |
| 96 | ], |
| 97 | hdrs = [ |
| 98 | "benchmark_config.h", |
| 99 | ], |
Bill Feng | 373c5b3 | 2018-08-20 10:55:49 -0700 | [diff] [blame] | 100 | external_deps = [ |
| 101 | "gflags", |
| 102 | ], |
Nicolas "Pixel" Noble | b02dd01 | 2017-03-24 18:45:22 +0100 | [diff] [blame] | 103 | deps = [ |
| 104 | ":driver_impl", |
| 105 | ":histogram", |
| 106 | "//:grpc++", |
Nicolas "Pixel" Noble | b02dd01 | 2017-03-24 18:45:22 +0100 | [diff] [blame] | 107 | "//src/proto/grpc/testing:control_proto", |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 108 | ], |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 109 | ) |
| 110 | |
Nicolas "Pixel" Noble | 7c26eed | 2017-04-13 01:40:54 +0200 | [diff] [blame] | 111 | grpc_cc_library( |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 112 | name = "histogram", |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 113 | hdrs = [ |
| 114 | "histogram.h", |
| 115 | "stats.h", |
| 116 | ], |
Vijay Pai | 195cf1e | 2017-11-30 10:56:06 -0800 | [diff] [blame] | 117 | deps = ["//test/core/util:grpc_test_util"], |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 118 | ) |
| 119 | |
Vijay Pai | 088112f | 2017-08-24 10:42:27 -0700 | [diff] [blame] | 120 | grpc_cc_test( |
| 121 | name = "inproc_sync_unary_ping_pong_test", |
| 122 | srcs = ["inproc_sync_unary_ping_pong_test.cc"], |
| 123 | deps = [ |
| 124 | ":benchmark_config", |
| 125 | ":driver_impl", |
| 126 | "//:grpc++", |
| 127 | "//test/cpp/util:test_config", |
| 128 | "//test/cpp/util:test_util", |
| 129 | ], |
| 130 | ) |
| 131 | |
Nicolas "Pixel" Noble | 7c26eed | 2017-04-13 01:40:54 +0200 | [diff] [blame] | 132 | grpc_cc_library( |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 133 | name = "interarrival", |
| 134 | hdrs = ["interarrival.h"], |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 135 | deps = ["//:grpc++"], |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 136 | ) |
| 137 | |
Bill Feng | 5be7304 | 2018-08-24 09:46:39 -0700 | [diff] [blame^] | 138 | filegroup( |
| 139 | name = "json_run_localhost_scenarios", |
| 140 | srcs = [ |
| 141 | ":json_run_localhost_scenarios.json", |
| 142 | ], |
| 143 | ) |
| 144 | |
Bill Feng | 373c5b3 | 2018-08-20 10:55:49 -0700 | [diff] [blame] | 145 | grpc_cc_test( |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 146 | name = "json_run_localhost", |
| 147 | srcs = ["json_run_localhost.cc"], |
Bill Feng | 373c5b3 | 2018-08-20 10:55:49 -0700 | [diff] [blame] | 148 | args = [ |
Bill Feng | 5be7304 | 2018-08-24 09:46:39 -0700 | [diff] [blame^] | 149 | "--scenarios_file", |
| 150 | "$(location //test/cpp/qps:json_run_localhost_scenarios)", |
| 151 | ], |
| 152 | data = [ |
| 153 | "//test/cpp/qps:json_run_localhost_scenarios", |
| 154 | "//test/cpp/qps:qps_json_driver", |
| 155 | "//test/cpp/qps:qps_worker", |
Bill Feng | 373c5b3 | 2018-08-20 10:55:49 -0700 | [diff] [blame] | 156 | ], |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 157 | deps = [ |
| 158 | "//:gpr", |
| 159 | "//test/core/util:gpr_test_util", |
| 160 | "//test/core/util:grpc_test_util", |
yang-g | b575a34 | 2017-07-13 09:47:27 -0700 | [diff] [blame] | 161 | "//test/cpp/util:test_config", |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 162 | "//test/cpp/util:test_util", |
| 163 | ], |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 164 | ) |
| 165 | |
Nicolas "Pixel" Noble | 7c26eed | 2017-04-13 01:40:54 +0200 | [diff] [blame] | 166 | grpc_cc_test( |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 167 | name = "qps_interarrival_test", |
| 168 | srcs = ["qps_interarrival_test.cc"], |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 169 | deps = [ |
| 170 | ":histogram", |
| 171 | ":interarrival", |
yang-g | b575a34 | 2017-07-13 09:47:27 -0700 | [diff] [blame] | 172 | "//test/cpp/util:test_config", |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 173 | ], |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 174 | ) |
| 175 | |
Bill Feng | 5be7304 | 2018-08-24 09:46:39 -0700 | [diff] [blame^] | 176 | filegroup( |
| 177 | name = "qps_json_driver_scenarios", |
| 178 | srcs = [ |
| 179 | ":qps_json_driver_scenarios.json", |
| 180 | ], |
| 181 | ) |
| 182 | |
Bill Feng | 373c5b3 | 2018-08-20 10:55:49 -0700 | [diff] [blame] | 183 | grpc_cc_test( |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 184 | name = "qps_json_driver", |
| 185 | srcs = ["qps_json_driver.cc"], |
Bill Feng | 373c5b3 | 2018-08-20 10:55:49 -0700 | [diff] [blame] | 186 | args = [ |
| 187 | "--run_inproc", |
Bill Feng | 5be7304 | 2018-08-24 09:46:39 -0700 | [diff] [blame^] | 188 | "--scenarios_file", |
| 189 | "$(location //test/cpp/qps:qps_json_driver_scenarios)", |
| 190 | ], |
| 191 | data = [ |
| 192 | "//test/cpp/qps:qps_json_driver_scenarios", |
Bill Feng | 373c5b3 | 2018-08-20 10:55:49 -0700 | [diff] [blame] | 193 | ], |
| 194 | external_deps = [ |
| 195 | "gflags", |
| 196 | ], |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 197 | deps = [ |
Nicolas "Pixel" Noble | b02dd01 | 2017-03-24 18:45:22 +0100 | [diff] [blame] | 198 | ":benchmark_config", |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 199 | ":driver_impl", |
| 200 | "//:grpc++", |
Guantao Liu | abe3cf5 | 2017-07-12 17:36:30 -0700 | [diff] [blame] | 201 | "//test/cpp/util:test_config", |
Guantao Liu | ac9fdfb | 2017-07-14 17:33:19 -0700 | [diff] [blame] | 202 | "//test/cpp/util:test_util", |
Nicolas "Pixel" Noble | 7c26eed | 2017-04-13 01:40:54 +0200 | [diff] [blame] | 203 | ], |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 204 | ) |
| 205 | |
Nicolas "Pixel" Noble | 7c26eed | 2017-04-13 01:40:54 +0200 | [diff] [blame] | 206 | grpc_cc_test( |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 207 | name = "qps_openloop_test", |
| 208 | srcs = ["qps_openloop_test.cc"], |
Bill Feng | 373c5b3 | 2018-08-20 10:55:49 -0700 | [diff] [blame] | 209 | data = ["//third_party/toolchains:RBE_USE_MACHINE_TYPE_LARGE"], |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 210 | deps = [ |
Nicolas "Pixel" Noble | b02dd01 | 2017-03-24 18:45:22 +0100 | [diff] [blame] | 211 | ":benchmark_config", |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 212 | ":driver_impl", |
| 213 | ":qps_worker_impl", |
yang-g | b575a34 | 2017-07-13 09:47:27 -0700 | [diff] [blame] | 214 | "//test/cpp/util:test_config", |
Guantao Liu | ac9fdfb | 2017-07-14 17:33:19 -0700 | [diff] [blame] | 215 | "//test/cpp/util:test_util", |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 216 | ], |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 217 | ) |
| 218 | |
Nicolas "Pixel" Noble | 7c26eed | 2017-04-13 01:40:54 +0200 | [diff] [blame] | 219 | grpc_cc_test( |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 220 | name = "secure_sync_unary_ping_pong_test", |
| 221 | srcs = ["secure_sync_unary_ping_pong_test.cc"], |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 222 | deps = [ |
Nicolas "Pixel" Noble | b02dd01 | 2017-03-24 18:45:22 +0100 | [diff] [blame] | 223 | ":benchmark_config", |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 224 | ":driver_impl", |
| 225 | "//:grpc++", |
yang-g | b575a34 | 2017-07-13 09:47:27 -0700 | [diff] [blame] | 226 | "//test/cpp/util:test_config", |
Guantao Liu | ac9fdfb | 2017-07-14 17:33:19 -0700 | [diff] [blame] | 227 | "//test/cpp/util:test_util", |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 228 | ], |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 229 | ) |
| 230 | |
Nicolas "Pixel" Noble | 7c26eed | 2017-04-13 01:40:54 +0200 | [diff] [blame] | 231 | grpc_cc_library( |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 232 | name = "usage_timer", |
| 233 | srcs = ["usage_timer.cc"], |
| 234 | hdrs = ["usage_timer.h"], |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 235 | deps = ["//:gpr"], |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 236 | ) |
| 237 | |
Nicolas "Pixel" Noble | 7c26eed | 2017-04-13 01:40:54 +0200 | [diff] [blame] | 238 | grpc_cc_binary( |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 239 | name = "qps_worker", |
| 240 | srcs = ["worker.cc"], |
Nicolas "Pixel" Noble | 0a6d30b | 2017-03-22 00:51:51 +0100 | [diff] [blame] | 241 | deps = [ |
| 242 | ":qps_worker_impl", |
| 243 | "//:grpc++", |
| 244 | "//test/core/util:gpr_test_util", |
| 245 | "//test/core/util:grpc_test_util", |
| 246 | "//test/cpp/util:test_config", |
| 247 | "//test/cpp/util:test_util", |
| 248 | ], |
Craig Tiller | 3a48847 | 2017-02-17 14:35:26 -0800 | [diff] [blame] | 249 | ) |