diff --git a/CMakeLists.txt b/CMakeLists.txt index 5b024707214..3e5f9099879 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -14926,7 +14926,7 @@ target_link_libraries(xds_interop_client ${_gRPC_PROTOBUF_LIBRARIES} ${_gRPC_ALLTARGETS_LIBRARIES} absl::flags - grpc++ + grpcpp_channelz grpc_test_util grpc++_test_config ) @@ -14981,7 +14981,7 @@ target_link_libraries(xds_interop_server ${_gRPC_PROTOBUF_LIBRARIES} ${_gRPC_ALLTARGETS_LIBRARIES} absl::flags - grpc++ + grpcpp_channelz grpc_test_util grpc++_test_config ) diff --git a/build_autogenerated.yaml b/build_autogenerated.yaml index 839478eba9a..6880c9a54c0 100644 --- a/build_autogenerated.yaml +++ b/build_autogenerated.yaml @@ -6674,7 +6674,7 @@ targets: - test/cpp/interop/xds_interop_client.cc deps: - absl/flags:flag - - grpc++ + - grpcpp_channelz - grpc_test_util - grpc++_test_config - name: xds_interop_server @@ -6692,7 +6692,7 @@ targets: - test/cpp/interop/xds_interop_server.cc deps: - absl/flags:flag - - grpc++ + - grpcpp_channelz - grpc_test_util - grpc++_test_config tests: [] diff --git a/test/cpp/interop/BUILD b/test/cpp/interop/BUILD index e92c3270a74..11d2a486a8f 100644 --- a/test/cpp/interop/BUILD +++ b/test/cpp/interop/BUILD @@ -229,6 +229,7 @@ grpc_cc_binary( ], deps = [ "//:grpc++", + "//:grpcpp_channelz", "//src/proto/grpc/testing:empty_proto", "//src/proto/grpc/testing:messages_proto", "//src/proto/grpc/testing:test_proto", @@ -248,6 +249,7 @@ grpc_cc_binary( ], deps = [ "//:grpc++", + "//:grpcpp_channelz", "//src/proto/grpc/testing:empty_proto", "//src/proto/grpc/testing:messages_proto", "//src/proto/grpc/testing:test_proto", diff --git a/test/cpp/interop/xds_interop_client.cc b/test/cpp/interop/xds_interop_client.cc index 7344905373a..bfb5c60e616 100644 --- a/test/cpp/interop/xds_interop_client.cc +++ b/test/cpp/interop/xds_interop_client.cc @@ -16,6 +16,7 @@ * */ +#include #include #include #include @@ -574,6 +575,7 @@ void BuildRpcConfigsFromFlags(RpcConfigurationsQueue* rpc_configs_queue) { int main(int argc, char** argv) { grpc::testing::TestEnvironment env(argc, argv); grpc::testing::InitTest(&argc, &argv, true); + grpc::channelz::experimental::InitChannelzService(); // Validate the expect_status flag. grpc_status_code code; GPR_ASSERT(grpc_status_code_from_string( diff --git a/test/cpp/interop/xds_interop_server.cc b/test/cpp/interop/xds_interop_server.cc index 0dfef79aae9..40767c869ce 100644 --- a/test/cpp/interop/xds_interop_server.cc +++ b/test/cpp/interop/xds_interop_server.cc @@ -19,6 +19,7 @@ #include #include #include +#include #include #include #include @@ -155,7 +156,7 @@ void RunServer(bool secure_mode, const int port, const int maintenance_port, int main(int argc, char** argv) { grpc::testing::TestEnvironment env(argc, argv); grpc::testing::InitTest(&argc, &argv, true); - + grpc::channelz::experimental::InitChannelzService(); char* hostname = grpc_gethostname(); if (hostname == nullptr) { std::cout << "Failed to get hostname, terminating" << std::endl;