aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/grpcpp/impl/codegen/interceptor_common.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/grpcpp/impl/codegen/interceptor_common.h')
-rw-r--r--include/grpcpp/impl/codegen/interceptor_common.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/include/grpcpp/impl/codegen/interceptor_common.h b/include/grpcpp/impl/codegen/interceptor_common.h
index 601a929afe..21326df73b 100644
--- a/include/grpcpp/impl/codegen/interceptor_common.h
+++ b/include/grpcpp/impl/codegen/interceptor_common.h
@@ -81,6 +81,8 @@ class InterceptorBatchMethodsImpl
ByteBuffer* GetSendMessage() override { return send_message_; }
+ bool GetSendMessageStatus() override { return !*fail_send_message_; }
+
std::multimap<grpc::string, grpc::string>* GetSendInitialMetadata() override {
return send_initial_metadata_;
}
@@ -113,6 +115,7 @@ class InterceptorBatchMethodsImpl
void FailHijackedSendMessage() override {
GPR_CODEGEN_ASSERT(hooks_[static_cast<size_t>(
experimental::InterceptionHookPoints::PRE_SEND_MESSAGE)]);
+ gpr_log(GPR_ERROR, "failing");
*fail_send_message_ = true;
}
@@ -396,6 +399,13 @@ class CancelInterceptorBatchMethods
return nullptr;
}
+ bool GetSendMessageStatus() override {
+ GPR_CODEGEN_ASSERT(
+ false &&
+ "It is illegal to call GetSendMessageStatus on a method which "
+ "has a Cancel notification");
+ }
+
std::multimap<grpc::string, grpc::string>* GetSendInitialMetadata() override {
GPR_CODEGEN_ASSERT(false &&
"It is illegal to call GetSendInitialMetadata on a "