[api-fuzzer] Remove ping support

pull/36146/head
Yash Tibrewal 8 months ago
parent 15d64cf9c9
commit e9a783aecb
  1. 16
      test/core/end2end/fuzzers/fuzzing_common.cc
  2. 3
      test/core/end2end/fuzzers/fuzzing_common.h

@ -547,16 +547,6 @@ BasicFuzzer::Result BasicFuzzer::CancelActiveCall() {
return Result::kComplete;
}
BasicFuzzer::Result BasicFuzzer::SendPingOnChannel() {
if (channel() != nullptr) {
pending_pings_++;
grpc_channel_ping(channel(), cq_, Decrement(&pending_pings_), nullptr);
} else {
return Result::kFailed;
}
return Result::kComplete;
}
BasicFuzzer::Result BasicFuzzer::Pause(Duration duration) {
++paused_;
engine()->RunAfterExactly(duration, [this]() { --paused_; });
@ -642,8 +632,7 @@ void BasicFuzzer::ShutdownCalls() {
bool BasicFuzzer::Continue() {
return channel() != nullptr || server() != nullptr ||
pending_channel_watches_ > 0 || pending_pings_ > 0 ||
ActiveCall() != nullptr || paused_;
pending_channel_watches_ > 0 || ActiveCall() != nullptr || paused_;
}
BasicFuzzer::Result BasicFuzzer::ExecuteAction(
@ -699,7 +688,8 @@ BasicFuzzer::Result BasicFuzzer::ExecuteAction(
return ValidateChannelTarget();
// send a ping on a channel
case api_fuzzer::Action::kPing:
return SendPingOnChannel();
// Ping is no longer a part of the API
return BasicFuzzer::Result::kNotSupported;
// enable a tracer
case api_fuzzer::Action::kEnableTracer: {
grpc_tracer_set_enabled(action.enable_tracer().c_str(), 1);

@ -135,8 +135,6 @@ class BasicFuzzer {
Result WatchConnectivity(uint32_t duration_us);
// Verify that the channel target can be reliably queried.
Result ValidateChannelTarget();
// Send a http ping on the channel.
Result SendPingOnChannel();
// Server specific actions
// Create an active server.
@ -183,7 +181,6 @@ class BasicFuzzer {
bool server_shutdown_ = false;
int pending_server_shutdowns_ = 0;
int pending_channel_watches_ = 0;
int pending_pings_ = 0;
int paused_ = 0;
std::vector<std::shared_ptr<Call>> calls_;
RefCountedPtr<ResourceQuota> resource_quota_;

Loading…
Cancel
Save