Go to the documentation of this file.
38 const vector<pair<TestCaseType, int>>&
tests)
57 weight_sofar +=
it->second;
58 if (random < weight_sofar) {
59 selected_test =
it->first;
73 long sleep_duration_ms,
bool do_not_abort_on_transient_failures)
76 channel_creation_func_(
std::
move(channel_creation_func)),
78 do_not_abort_on_transient_failures)),
79 test_selector_(test_selector),
80 test_duration_secs_(test_duration_secs),
81 sleep_duration_ms_(sleep_duration_ms) {}
84 const std::shared_ptr<QpsGauge>& qps_gauge) {
118 bool is_success =
false;
TestCaseType GetNextTest() const
@ SERVER_COMPRESSED_STREAMING
GPRAPI gpr_timespec gpr_inf_future(gpr_clock_type type)
@ CLIENT_COMPRESSED_UNARY
@ TIMEOUT_ON_SLEEPING_SERVER
const WeightedRandomTestSelector & test_selector_
std::string server_address("0.0.0.0:10000")
constexpr absl::remove_reference_t< T > && move(T &&t) noexcept
GPRAPI int gpr_time_cmp(gpr_timespec a, gpr_timespec b)
std::unique_ptr< InteropClient > interop_client_
GPRAPI void gpr_log(const char *file, int line, gpr_log_severity severity, const char *format,...) GPR_PRINT_FORMAT_CHECK(4
GPRAPI void gpr_sleep_until(gpr_timespec until)
StressTestInteropClient(int test_id, const std::string &server_address, ChannelCreationFunc channel_creation_func, const WeightedRandomTestSelector &test_selector, long test_duration_secs, long sleep_duration_ms, bool do_not_abort_on_transient_failures)
void MainLoop(const std::shared_ptr< QpsGauge > &qps_gauge)
@ SERVER_COMPRESSED_UNARY
GPRAPI gpr_timespec gpr_now(gpr_clock_type clock)
bool RunTest(TestCaseType test_case)
std::function< std::shared_ptr< Channel >void)> ChannelCreationFunc
@ STATUS_CODE_AND_MESSAGE
WeightedRandomTestSelector(const vector< pair< TestCaseType, int >> &tests)
GPRAPI gpr_timespec gpr_time_add(gpr_timespec a, gpr_timespec b)
const char * server_address_
GPRAPI gpr_timespec gpr_time_from_millis(int64_t ms, gpr_clock_type clock_type)
const vector< pair< TestCaseType, int > > tests_
@ CLIENT_COMPRESSED_STREAMING
std::pair< std::string, std::string > pair
@ CANCEL_AFTER_FIRST_RESPONSE
const std::string & server_address_
GPRAPI gpr_timespec gpr_time_from_seconds(int64_t s, gpr_clock_type clock_type)
grpc
Author(s):
autogenerated on Fri May 16 2025 03:00:21