Merge remote-tracking branch 'upstream/master' into docs
diff --git a/BUILD b/BUILD
index 7eb5979..d712053 100644
--- a/BUILD
+++ b/BUILD
@@ -675,7 +675,7 @@
"src/cpp/client/secure_credentials.h",
"src/cpp/common/secure_auth_context.h",
"src/cpp/server/secure_server_credentials.h",
- "src/cpp/client/channel.h",
+ "src/cpp/client/create_channel_internal.h",
"src/cpp/common/create_auth_context.h",
"src/cpp/client/secure_channel_arguments.cc",
"src/cpp/client/secure_credentials.cc",
@@ -687,10 +687,10 @@
"src/cpp/client/channel_arguments.cc",
"src/cpp/client/client_context.cc",
"src/cpp/client/create_channel.cc",
+ "src/cpp/client/create_channel_internal.cc",
"src/cpp/client/credentials.cc",
"src/cpp/client/generic_stub.cc",
"src/cpp/client/insecure_credentials.cc",
- "src/cpp/client/internal_stub.cc",
"src/cpp/common/call.cc",
"src/cpp/common/completion_queue.cc",
"src/cpp/common/rpc_method.cc",
@@ -714,8 +714,8 @@
"include/grpc++/async_unary_call.h",
"include/grpc++/auth_context.h",
"include/grpc++/byte_buffer.h",
+ "include/grpc++/channel.h",
"include/grpc++/channel_arguments.h",
- "include/grpc++/channel_interface.h",
"include/grpc++/client_context.h",
"include/grpc++/completion_queue.h",
"include/grpc++/config.h",
@@ -728,7 +728,6 @@
"include/grpc++/impl/call.h",
"include/grpc++/impl/client_unary_call.h",
"include/grpc++/impl/grpc_library.h",
- "include/grpc++/impl/internal_stub.h",
"include/grpc++/impl/proto_utils.h",
"include/grpc++/impl/rpc_method.h",
"include/grpc++/impl/rpc_service_method.h",
@@ -767,17 +766,17 @@
cc_library(
name = "grpc++_unsecure",
srcs = [
- "src/cpp/client/channel.h",
+ "src/cpp/client/create_channel_internal.h",
"src/cpp/common/create_auth_context.h",
"src/cpp/common/insecure_create_auth_context.cc",
"src/cpp/client/channel.cc",
"src/cpp/client/channel_arguments.cc",
"src/cpp/client/client_context.cc",
"src/cpp/client/create_channel.cc",
+ "src/cpp/client/create_channel_internal.cc",
"src/cpp/client/credentials.cc",
"src/cpp/client/generic_stub.cc",
"src/cpp/client/insecure_credentials.cc",
- "src/cpp/client/internal_stub.cc",
"src/cpp/common/call.cc",
"src/cpp/common/completion_queue.cc",
"src/cpp/common/rpc_method.cc",
@@ -801,8 +800,8 @@
"include/grpc++/async_unary_call.h",
"include/grpc++/auth_context.h",
"include/grpc++/byte_buffer.h",
+ "include/grpc++/channel.h",
"include/grpc++/channel_arguments.h",
- "include/grpc++/channel_interface.h",
"include/grpc++/client_context.h",
"include/grpc++/completion_queue.h",
"include/grpc++/config.h",
@@ -815,7 +814,6 @@
"include/grpc++/impl/call.h",
"include/grpc++/impl/client_unary_call.h",
"include/grpc++/impl/grpc_library.h",
- "include/grpc++/impl/internal_stub.h",
"include/grpc++/impl/proto_utils.h",
"include/grpc++/impl/rpc_method.h",
"include/grpc++/impl/rpc_service_method.h",
diff --git a/Makefile b/Makefile
index 31628b4..5cce835 100644
--- a/Makefile
+++ b/Makefile
@@ -4606,10 +4606,10 @@
src/cpp/client/channel_arguments.cc \
src/cpp/client/client_context.cc \
src/cpp/client/create_channel.cc \
+ src/cpp/client/create_channel_internal.cc \
src/cpp/client/credentials.cc \
src/cpp/client/generic_stub.cc \
src/cpp/client/insecure_credentials.cc \
- src/cpp/client/internal_stub.cc \
src/cpp/common/call.cc \
src/cpp/common/completion_queue.cc \
src/cpp/common/rpc_method.cc \
@@ -4633,8 +4633,8 @@
include/grpc++/async_unary_call.h \
include/grpc++/auth_context.h \
include/grpc++/byte_buffer.h \
+ include/grpc++/channel.h \
include/grpc++/channel_arguments.h \
- include/grpc++/channel_interface.h \
include/grpc++/client_context.h \
include/grpc++/completion_queue.h \
include/grpc++/config.h \
@@ -4647,7 +4647,6 @@
include/grpc++/impl/call.h \
include/grpc++/impl/client_unary_call.h \
include/grpc++/impl/grpc_library.h \
- include/grpc++/impl/internal_stub.h \
include/grpc++/impl/proto_utils.h \
include/grpc++/impl/rpc_method.h \
include/grpc++/impl/rpc_service_method.h \
@@ -4849,10 +4848,10 @@
src/cpp/client/channel_arguments.cc \
src/cpp/client/client_context.cc \
src/cpp/client/create_channel.cc \
+ src/cpp/client/create_channel_internal.cc \
src/cpp/client/credentials.cc \
src/cpp/client/generic_stub.cc \
src/cpp/client/insecure_credentials.cc \
- src/cpp/client/internal_stub.cc \
src/cpp/common/call.cc \
src/cpp/common/completion_queue.cc \
src/cpp/common/rpc_method.cc \
@@ -4876,8 +4875,8 @@
include/grpc++/async_unary_call.h \
include/grpc++/auth_context.h \
include/grpc++/byte_buffer.h \
+ include/grpc++/channel.h \
include/grpc++/channel_arguments.h \
- include/grpc++/channel_interface.h \
include/grpc++/client_context.h \
include/grpc++/completion_queue.h \
include/grpc++/config.h \
@@ -4890,7 +4889,6 @@
include/grpc++/impl/call.h \
include/grpc++/impl/client_unary_call.h \
include/grpc++/impl/grpc_library.h \
- include/grpc++/impl/internal_stub.h \
include/grpc++/impl/proto_utils.h \
include/grpc++/impl/rpc_method.h \
include/grpc++/impl/rpc_service_method.h \
diff --git a/build.json b/build.json
index bd707d2..484502b 100644
--- a/build.json
+++ b/build.json
@@ -34,8 +34,8 @@
"include/grpc++/async_unary_call.h",
"include/grpc++/auth_context.h",
"include/grpc++/byte_buffer.h",
+ "include/grpc++/channel.h",
"include/grpc++/channel_arguments.h",
- "include/grpc++/channel_interface.h",
"include/grpc++/client_context.h",
"include/grpc++/completion_queue.h",
"include/grpc++/config.h",
@@ -48,7 +48,6 @@
"include/grpc++/impl/call.h",
"include/grpc++/impl/client_unary_call.h",
"include/grpc++/impl/grpc_library.h",
- "include/grpc++/impl/internal_stub.h",
"include/grpc++/impl/proto_utils.h",
"include/grpc++/impl/rpc_method.h",
"include/grpc++/impl/rpc_service_method.h",
@@ -73,7 +72,7 @@
"include/grpc++/time.h"
],
"headers": [
- "src/cpp/client/channel.h",
+ "src/cpp/client/create_channel_internal.h",
"src/cpp/common/create_auth_context.h"
],
"src": [
@@ -81,10 +80,10 @@
"src/cpp/client/channel_arguments.cc",
"src/cpp/client/client_context.cc",
"src/cpp/client/create_channel.cc",
+ "src/cpp/client/create_channel_internal.cc",
"src/cpp/client/credentials.cc",
"src/cpp/client/generic_stub.cc",
"src/cpp/client/insecure_credentials.cc",
- "src/cpp/client/internal_stub.cc",
"src/cpp/common/call.cc",
"src/cpp/common/completion_queue.cc",
"src/cpp/common/rpc_method.cc",
diff --git a/examples/pubsub/main.cc b/examples/pubsub/main.cc
index b1898f1..fcee3b3 100644
--- a/examples/pubsub/main.cc
+++ b/examples/pubsub/main.cc
@@ -41,7 +41,7 @@
#include <grpc/support/log.h>
#include <gflags/gflags.h>
#include <grpc++/channel_arguments.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/create_channel.h>
#include <grpc++/credentials.h>
#include <grpc++/status.h>
@@ -72,7 +72,7 @@
ss << FLAGS_server_host << ":" << FLAGS_server_port;
std::shared_ptr<grpc::Credentials> creds = grpc::GoogleDefaultCredentials();
- std::shared_ptr<grpc::ChannelInterface> channel =
+ std::shared_ptr<grpc::Channel> channel =
grpc::CreateChannel(ss.str(), creds, grpc::ChannelArguments());
grpc::examples::pubsub::Publisher publisher(channel);
diff --git a/examples/pubsub/publisher.cc b/examples/pubsub/publisher.cc
index 458050a..fd38ca9 100644
--- a/examples/pubsub/publisher.cc
+++ b/examples/pubsub/publisher.cc
@@ -50,7 +50,7 @@
namespace examples {
namespace pubsub {
-Publisher::Publisher(std::shared_ptr<ChannelInterface> channel)
+Publisher::Publisher(std::shared_ptr<Channel> channel)
: stub_(PublisherService::NewStub(channel)) {}
void Publisher::Shutdown() { stub_.reset(); }
diff --git a/examples/pubsub/publisher.h b/examples/pubsub/publisher.h
index 33bcf98..b98e697 100644
--- a/examples/pubsub/publisher.h
+++ b/examples/pubsub/publisher.h
@@ -34,7 +34,7 @@
#ifndef GRPC_EXAMPLES_PUBSUB_PUBLISHER_H
#define GRPC_EXAMPLES_PUBSUB_PUBLISHER_H
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/status.h>
#include "examples/pubsub/pubsub.grpc.pb.h"
@@ -45,7 +45,7 @@
class Publisher {
public:
- Publisher(std::shared_ptr<ChannelInterface> channel);
+ Publisher(std::shared_ptr<Channel> channel);
void Shutdown();
Status CreateTopic(const grpc::string& topic);
diff --git a/examples/pubsub/publisher_test.cc b/examples/pubsub/publisher_test.cc
index 6b9dcac..972b426 100644
--- a/examples/pubsub/publisher_test.cc
+++ b/examples/pubsub/publisher_test.cc
@@ -32,7 +32,7 @@
*/
#include <grpc++/channel_arguments.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/create_channel.h>
#include <grpc++/server.h>
@@ -46,7 +46,7 @@
#include "test/core/util/port.h"
#include "test/core/util/test_config.h"
-using grpc::ChannelInterface;
+using grpc::Channel;
namespace grpc {
namespace testing {
@@ -124,7 +124,7 @@
std::unique_ptr<Server> server_;
PublisherServiceImpl service_;
- std::shared_ptr<ChannelInterface> channel_;
+ std::shared_ptr<Channel> channel_;
std::unique_ptr<grpc::examples::pubsub::Publisher> publisher_;
};
diff --git a/examples/pubsub/subscriber.cc b/examples/pubsub/subscriber.cc
index d9e0292..0818f50 100644
--- a/examples/pubsub/subscriber.cc
+++ b/examples/pubsub/subscriber.cc
@@ -48,7 +48,7 @@
namespace examples {
namespace pubsub {
-Subscriber::Subscriber(std::shared_ptr<ChannelInterface> channel)
+Subscriber::Subscriber(std::shared_ptr<Channel> channel)
: stub_(SubscriberService::NewStub(channel)) {}
void Subscriber::Shutdown() { stub_.reset(); }
diff --git a/examples/pubsub/subscriber.h b/examples/pubsub/subscriber.h
index 40ab454..87c8331 100644
--- a/examples/pubsub/subscriber.h
+++ b/examples/pubsub/subscriber.h
@@ -34,7 +34,7 @@
#ifndef GRPC_EXAMPLES_PUBSUB_SUBSCRIBER_H
#define GRPC_EXAMPLES_PUBSUB_SUBSCRIBER_H
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/status.h>
#include "examples/pubsub/pubsub.grpc.pb.h"
@@ -45,7 +45,7 @@
class Subscriber {
public:
- Subscriber(std::shared_ptr<ChannelInterface> channel);
+ Subscriber(std::shared_ptr<Channel> channel);
void Shutdown();
Status CreateSubscription(const grpc::string& topic,
diff --git a/examples/pubsub/subscriber_test.cc b/examples/pubsub/subscriber_test.cc
index b0e7fc0..7974ca8 100644
--- a/examples/pubsub/subscriber_test.cc
+++ b/examples/pubsub/subscriber_test.cc
@@ -32,7 +32,7 @@
*/
#include <grpc++/channel_arguments.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/create_channel.h>
#include <grpc++/server.h>
@@ -122,7 +122,7 @@
std::unique_ptr<Server> server_;
SubscriberServiceImpl service_;
- std::shared_ptr<ChannelInterface> channel_;
+ std::shared_ptr<Channel> channel_;
std::unique_ptr<grpc::examples::pubsub::Subscriber> subscriber_;
};
diff --git a/include/grpc++/async_unary_call.h b/include/grpc++/async_unary_call.h
index 3d22df4..4e1dd15 100644
--- a/include/grpc++/async_unary_call.h
+++ b/include/grpc++/async_unary_call.h
@@ -34,7 +34,7 @@
#ifndef GRPCXX_ASYNC_UNARY_CALL_H
#define GRPCXX_ASYNC_UNARY_CALL_H
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/completion_queue.h>
#include <grpc++/server_context.h>
@@ -58,7 +58,7 @@
: public ClientAsyncResponseReaderInterface<R> {
public:
template <class W>
- ClientAsyncResponseReader(ChannelInterface* channel, CompletionQueue* cq,
+ ClientAsyncResponseReader(Channel* channel, CompletionQueue* cq,
const RpcMethod& method, ClientContext* context,
const W& request)
: context_(context), call_(channel->CreateCall(method, context, cq)) {
diff --git a/include/grpc++/channel.h b/include/grpc++/channel.h
new file mode 100644
index 0000000..7d6216e
--- /dev/null
+++ b/include/grpc++/channel.h
@@ -0,0 +1,138 @@
+/*
+ *
+ * Copyright 2015, Google Inc.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above
+ * copyright notice, this list of conditions and the following disclaimer
+ * in the documentation and/or other materials provided with the
+ * distribution.
+ * * Neither the name of Google Inc. nor the names of its
+ * contributors may be used to endorse or promote products derived from
+ * this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ */
+
+#ifndef GRPCXX_CHANNEL_H
+#define GRPCXX_CHANNEL_H
+
+#include <memory>
+
+#include <grpc/grpc.h>
+#include <grpc++/config.h>
+#include <grpc++/impl/call.h>
+#include <grpc++/impl/grpc_library.h>
+
+struct grpc_channel;
+
+namespace grpc {
+class CallOpSetInterface;
+class ChannelArguments;
+class CompletionQueue;
+class Credentials;
+class SecureCredentials;
+
+template <class R>
+class ClientReader;
+template <class W>
+class ClientWriter;
+template <class R, class W>
+class ClientReaderWriter;
+template <class R>
+class ClientAsyncReader;
+template <class W>
+class ClientAsyncWriter;
+template <class R, class W>
+class ClientAsyncReaderWriter;
+template <class R>
+class ClientAsyncResponseReader;
+
+class Channel GRPC_FINAL : public GrpcLibrary,
+ public CallHook,
+ public std::enable_shared_from_this<Channel> {
+ public:
+ ~Channel();
+
+ // Get the current channel state. If the channel is in IDLE and try_to_connect
+ // is set to true, try to connect.
+ grpc_connectivity_state GetState(bool try_to_connect);
+
+ // Return the tag on cq when the channel state is changed or deadline expires.
+ // GetState needs to called to get the current state.
+ template <typename T>
+ void NotifyOnStateChange(grpc_connectivity_state last_observed, T deadline,
+ CompletionQueue* cq, void* tag) {
+ TimePoint<T> deadline_tp(deadline);
+ NotifyOnStateChangeImpl(last_observed, deadline_tp.raw_time(), cq, tag);
+ }
+
+ // Blocking wait for channel state change or deadline expiration.
+ // GetState needs to called to get the current state.
+ template <typename T>
+ bool WaitForStateChange(grpc_connectivity_state last_observed, T deadline) {
+ TimePoint<T> deadline_tp(deadline);
+ return WaitForStateChangeImpl(last_observed, deadline_tp.raw_time());
+ }
+
+ private:
+ template <class R>
+ friend class ::grpc::ClientReader;
+ template <class W>
+ friend class ::grpc::ClientWriter;
+ template <class R, class W>
+ friend class ::grpc::ClientReaderWriter;
+ template <class R>
+ friend class ::grpc::ClientAsyncReader;
+ template <class W>
+ friend class ::grpc::ClientAsyncWriter;
+ template <class R, class W>
+ friend class ::grpc::ClientAsyncReaderWriter;
+ template <class R>
+ friend class ::grpc::ClientAsyncResponseReader;
+ template <class InputMessage, class OutputMessage>
+ friend Status BlockingUnaryCall(Channel* channel, const RpcMethod& method,
+ ClientContext* context,
+ const InputMessage& request,
+ OutputMessage* result);
+ friend class ::grpc::RpcMethod;
+ friend std::shared_ptr<Channel> CreateChannelInternal(
+ const grpc::string& host, grpc_channel* c_channel);
+
+ Channel(const grpc::string& host, grpc_channel* c_channel);
+
+ Call CreateCall(const RpcMethod& method, ClientContext* context,
+ CompletionQueue* cq);
+ void PerformOpsOnCall(CallOpSetInterface* ops, Call* call);
+ void* RegisterMethod(const char* method);
+
+ void NotifyOnStateChangeImpl(grpc_connectivity_state last_observed,
+ gpr_timespec deadline, CompletionQueue* cq,
+ void* tag);
+ bool WaitForStateChangeImpl(grpc_connectivity_state last_observed,
+ gpr_timespec deadline);
+
+ const grpc::string host_;
+ grpc_channel* const c_channel_; // owned
+};
+
+} // namespace grpc
+
+#endif // GRPCXX_CHANNEL_H
diff --git a/include/grpc++/channel_interface.h b/include/grpc++/channel_interface.h
deleted file mode 100644
index 4176cde..0000000
--- a/include/grpc++/channel_interface.h
+++ /dev/null
@@ -1,92 +0,0 @@
-/*
- *
- * Copyright 2015, Google Inc.
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are
- * met:
- *
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above
- * copyright notice, this list of conditions and the following disclaimer
- * in the documentation and/or other materials provided with the
- * distribution.
- * * Neither the name of Google Inc. nor the names of its
- * contributors may be used to endorse or promote products derived from
- * this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
- */
-
-#ifndef GRPCXX_CHANNEL_INTERFACE_H
-#define GRPCXX_CHANNEL_INTERFACE_H
-
-#include <memory>
-
-#include <grpc/grpc.h>
-#include <grpc++/status.h>
-#include <grpc++/impl/call.h>
-
-struct grpc_call;
-
-namespace grpc {
-class Call;
-class CallOpBuffer;
-class ClientContext;
-class CompletionQueue;
-class RpcMethod;
-
-class ChannelInterface : public CallHook,
- public std::enable_shared_from_this<ChannelInterface> {
- public:
- virtual ~ChannelInterface() {}
-
- virtual void* RegisterMethod(const char* method_name) = 0;
- virtual Call CreateCall(const RpcMethod& method, ClientContext* context,
- CompletionQueue* cq) = 0;
-
- // Get the current channel state. If the channel is in IDLE and try_to_connect
- // is set to true, try to connect.
- virtual grpc_connectivity_state GetState(bool try_to_connect) = 0;
-
- // Return the tag on cq when the channel state is changed or deadline expires.
- // GetState needs to called to get the current state.
- template <typename T>
- void NotifyOnStateChange(grpc_connectivity_state last_observed, T deadline,
- CompletionQueue* cq, void* tag) {
- TimePoint<T> deadline_tp(deadline);
- NotifyOnStateChangeImpl(last_observed, deadline_tp.raw_time(), cq, tag);
- }
-
- // Blocking wait for channel state change or deadline expiration.
- // GetState needs to called to get the current state.
- template <typename T>
- bool WaitForStateChange(grpc_connectivity_state last_observed, T deadline) {
- TimePoint<T> deadline_tp(deadline);
- return WaitForStateChangeImpl(last_observed, deadline_tp.raw_time());
- }
-
- private:
- virtual void NotifyOnStateChangeImpl(grpc_connectivity_state last_observed,
- gpr_timespec deadline,
- CompletionQueue* cq, void* tag) = 0;
- virtual bool WaitForStateChangeImpl(grpc_connectivity_state last_observed,
- gpr_timespec deadline) = 0;
-};
-
-} // namespace grpc
-
-#endif // GRPCXX_CHANNEL_INTERFACE_H
diff --git a/include/grpc++/client_context.h b/include/grpc++/client_context.h
index 8de2ba4..55ed175 100644
--- a/include/grpc++/client_context.h
+++ b/include/grpc++/client_context.h
@@ -51,7 +51,7 @@
namespace grpc {
-class ChannelInterface;
+class Channel;
class CompletionQueue;
class Credentials;
class RpcMethod;
@@ -215,20 +215,18 @@
template <class R>
friend class ::grpc::ClientAsyncResponseReader;
template <class InputMessage, class OutputMessage>
- friend Status BlockingUnaryCall(ChannelInterface* channel,
- const RpcMethod& method,
+ friend Status BlockingUnaryCall(Channel* channel, const RpcMethod& method,
ClientContext* context,
const InputMessage& request,
OutputMessage* result);
grpc_call* call() { return call_; }
- void set_call(grpc_call* call,
- const std::shared_ptr<ChannelInterface>& channel);
+ void set_call(grpc_call* call, const std::shared_ptr<Channel>& channel);
grpc::string authority() { return authority_; }
bool initial_metadata_received_;
- std::shared_ptr<ChannelInterface> channel_;
+ std::shared_ptr<Channel> channel_;
grpc_call* call_;
gpr_timespec deadline_;
grpc::string authority_;
diff --git a/include/grpc++/completion_queue.h b/include/grpc++/completion_queue.h
index 2f30211..061f487 100644
--- a/include/grpc++/completion_queue.h
+++ b/include/grpc++/completion_queue.h
@@ -65,7 +65,7 @@
class BidiStreamingHandler;
class UnknownMethodHandler;
-class ChannelInterface;
+class Channel;
class ClientContext;
class CompletionQueue;
class RpcMethod;
@@ -143,8 +143,7 @@
friend class ::grpc::Server;
friend class ::grpc::ServerContext;
template <class InputMessage, class OutputMessage>
- friend Status BlockingUnaryCall(ChannelInterface* channel,
- const RpcMethod& method,
+ friend Status BlockingUnaryCall(Channel* channel, const RpcMethod& method,
ClientContext* context,
const InputMessage& request,
OutputMessage* result);
diff --git a/include/grpc++/create_channel.h b/include/grpc++/create_channel.h
index 424a93a..fe34452 100644
--- a/include/grpc++/create_channel.h
+++ b/include/grpc++/create_channel.h
@@ -41,10 +41,9 @@
namespace grpc {
class ChannelArguments;
-class ChannelInterface;
// If creds does not hold an object or is invalid, a lame channel is returned.
-std::shared_ptr<ChannelInterface> CreateChannel(
+std::shared_ptr<Channel> CreateChannel(
const grpc::string& target, const std::shared_ptr<Credentials>& creds,
const ChannelArguments& args);
diff --git a/include/grpc++/credentials.h b/include/grpc++/credentials.h
index a4f1e73..306dc96 100644
--- a/include/grpc++/credentials.h
+++ b/include/grpc++/credentials.h
@@ -41,7 +41,7 @@
namespace grpc {
class ChannelArguments;
-class ChannelInterface;
+class Channel;
class SecureCredentials;
class Credentials : public GrpcLibrary {
@@ -57,11 +57,11 @@
virtual SecureCredentials* AsSecureCredentials() = 0;
private:
- friend std::shared_ptr<ChannelInterface> CreateChannel(
+ friend std::shared_ptr<Channel> CreateChannel(
const grpc::string& target, const std::shared_ptr<Credentials>& creds,
const ChannelArguments& args);
- virtual std::shared_ptr<ChannelInterface> CreateChannel(
+ virtual std::shared_ptr<Channel> CreateChannel(
const grpc::string& target, const ChannelArguments& args) = 0;
};
diff --git a/include/grpc++/generic_stub.h b/include/grpc++/generic_stub.h
index 172f10e..7344408 100644
--- a/include/grpc++/generic_stub.h
+++ b/include/grpc++/generic_stub.h
@@ -47,8 +47,7 @@
// by name.
class GenericStub GRPC_FINAL {
public:
- explicit GenericStub(std::shared_ptr<ChannelInterface> channel)
- : channel_(channel) {}
+ explicit GenericStub(std::shared_ptr<Channel> channel) : channel_(channel) {}
// begin a call to a named method
std::unique_ptr<GenericClientAsyncReaderWriter> Call(
@@ -56,7 +55,7 @@
void* tag);
private:
- std::shared_ptr<ChannelInterface> channel_;
+ std::shared_ptr<Channel> channel_;
};
} // namespace grpc
diff --git a/include/grpc++/impl/client_unary_call.h b/include/grpc++/impl/client_unary_call.h
index b77ce7d..4aae816 100644
--- a/include/grpc++/impl/client_unary_call.h
+++ b/include/grpc++/impl/client_unary_call.h
@@ -41,14 +41,14 @@
namespace grpc {
-class ChannelInterface;
+class Channel;
class ClientContext;
class CompletionQueue;
class RpcMethod;
// Wrapper that performs a blocking unary call
template <class InputMessage, class OutputMessage>
-Status BlockingUnaryCall(ChannelInterface* channel, const RpcMethod& method,
+Status BlockingUnaryCall(Channel* channel, const RpcMethod& method,
ClientContext* context, const InputMessage& request,
OutputMessage* result) {
CompletionQueue cq;
diff --git a/include/grpc++/impl/rpc_method.h b/include/grpc++/impl/rpc_method.h
index 50a160b..9800268 100644
--- a/include/grpc++/impl/rpc_method.h
+++ b/include/grpc++/impl/rpc_method.h
@@ -34,6 +34,10 @@
#ifndef GRPCXX_IMPL_RPC_METHOD_H
#define GRPCXX_IMPL_RPC_METHOD_H
+#include <memory>
+
+#include <grpc++/channel.h>
+
namespace grpc {
class RpcMethod {
@@ -45,8 +49,14 @@
BIDI_STREAMING
};
- RpcMethod(const char* name, RpcType type, void* channel_tag)
- : name_(name), method_type_(type), channel_tag_(channel_tag) {}
+ RpcMethod(const char* name, RpcType type)
+ : name_(name), method_type_(type), channel_tag_(NULL) {}
+
+ RpcMethod(const char* name, RpcType type,
+ const std::shared_ptr<Channel>& channel)
+ : name_(name),
+ method_type_(type),
+ channel_tag_(channel->RegisterMethod(name)) {}
const char* name() const { return name_; }
RpcType method_type() const { return method_type_; }
diff --git a/include/grpc++/impl/rpc_service_method.h b/include/grpc++/impl/rpc_service_method.h
index 925801e..078c8c4 100644
--- a/include/grpc++/impl/rpc_service_method.h
+++ b/include/grpc++/impl/rpc_service_method.h
@@ -229,7 +229,7 @@
// Takes ownership of the handler
RpcServiceMethod(const char* name, RpcMethod::RpcType type,
MethodHandler* handler)
- : RpcMethod(name, type, nullptr), handler_(handler) {}
+ : RpcMethod(name, type), handler_(handler) {}
MethodHandler* handler() { return handler_.get(); }
diff --git a/include/grpc++/stream.h b/include/grpc++/stream.h
index 45dafcd..577eb4e 100644
--- a/include/grpc++/stream.h
+++ b/include/grpc++/stream.h
@@ -34,7 +34,7 @@
#ifndef GRPCXX_STREAM_H
#define GRPCXX_STREAM_H
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/completion_queue.h>
#include <grpc++/server_context.h>
@@ -100,7 +100,7 @@
public:
// Blocking create a stream and write the first request out.
template <class W>
- ClientReader(ChannelInterface* channel, const RpcMethod& method,
+ ClientReader(Channel* channel, const RpcMethod& method,
ClientContext* context, const W& request)
: context_(context), call_(channel->CreateCall(method, context, &cq_)) {
CallOpSet<CallOpSendInitialMetadata, CallOpSendMessage,
@@ -163,7 +163,7 @@
public:
// Blocking create a stream.
template <class R>
- ClientWriter(ChannelInterface* channel, const RpcMethod& method,
+ ClientWriter(Channel* channel, const RpcMethod& method,
ClientContext* context, R* response)
: context_(context), call_(channel->CreateCall(method, context, &cq_)) {
finish_ops_.RecvMessage(response);
@@ -221,7 +221,7 @@
class ClientReaderWriter GRPC_FINAL : public ClientReaderWriterInterface<W, R> {
public:
// Blocking create a stream.
- ClientReaderWriter(ChannelInterface* channel, const RpcMethod& method,
+ ClientReaderWriter(Channel* channel, const RpcMethod& method,
ClientContext* context)
: context_(context), call_(channel->CreateCall(method, context, &cq_)) {
CallOpSet<CallOpSendInitialMetadata> ops;
@@ -425,7 +425,7 @@
public:
// Create a stream and write the first request out.
template <class W>
- ClientAsyncReader(ChannelInterface* channel, CompletionQueue* cq,
+ ClientAsyncReader(Channel* channel, CompletionQueue* cq,
const RpcMethod& method, ClientContext* context,
const W& request, void* tag)
: context_(context), call_(channel->CreateCall(method, context, cq)) {
@@ -484,7 +484,7 @@
class ClientAsyncWriter GRPC_FINAL : public ClientAsyncWriterInterface<W> {
public:
template <class R>
- ClientAsyncWriter(ChannelInterface* channel, CompletionQueue* cq,
+ ClientAsyncWriter(Channel* channel, CompletionQueue* cq,
const RpcMethod& method, ClientContext* context,
R* response, void* tag)
: context_(context), call_(channel->CreateCall(method, context, cq)) {
@@ -549,7 +549,7 @@
class ClientAsyncReaderWriter GRPC_FINAL
: public ClientAsyncReaderWriterInterface<W, R> {
public:
- ClientAsyncReaderWriter(ChannelInterface* channel, CompletionQueue* cq,
+ ClientAsyncReaderWriter(Channel* channel, CompletionQueue* cq,
const RpcMethod& method, ClientContext* context,
void* tag)
: context_(context), call_(channel->CreateCall(method, context, cq)) {
diff --git a/src/compiler/cpp_generator.cc b/src/compiler/cpp_generator.cc
index ea487bc..b04ac03 100644
--- a/src/compiler/cpp_generator.cc
+++ b/src/compiler/cpp_generator.cc
@@ -112,7 +112,6 @@
grpc::string GetHeaderIncludes(const grpc::protobuf::FileDescriptor *file,
const Parameters ¶ms) {
grpc::string temp =
- "#include <grpc++/impl/internal_stub.h>\n"
"#include <grpc++/impl/rpc_method.h>\n"
"#include <grpc++/impl/proto_utils.h>\n"
"#include <grpc++/impl/service_type.h>\n"
@@ -123,7 +122,7 @@
"\n"
"namespace grpc {\n"
"class CompletionQueue;\n"
- "class ChannelInterface;\n"
+ "class Channel;\n"
"class RpcService;\n"
"class ServerCompletionQueue;\n"
"class ServerContext;\n"
@@ -554,17 +553,17 @@
printer->Outdent();
printer->Print("};\n");
printer->Print(
- "class Stub GRPC_FINAL : public StubInterface,"
- " public ::grpc::InternalStub {\n public:\n");
+ "class Stub GRPC_FINAL : public StubInterface"
+ " {\n public:\n");
printer->Indent();
- printer->Print(
- "Stub(const std::shared_ptr< ::grpc::ChannelInterface>& channel);\n");
+ printer->Print("Stub(const std::shared_ptr< ::grpc::Channel>& channel);\n");
for (int i = 0; i < service->method_count(); ++i) {
PrintHeaderClientMethod(printer, service->method(i), vars, true);
}
printer->Outdent();
printer->Print("\n private:\n");
printer->Indent();
+ printer->Print("std::shared_ptr< ::grpc::Channel> channel_;\n");
for (int i = 0; i < service->method_count(); ++i) {
PrintHeaderClientMethod(printer, service->method(i), vars, false);
}
@@ -575,7 +574,7 @@
printer->Print("};\n");
printer->Print(
"static std::unique_ptr<Stub> NewStub(const std::shared_ptr< "
- "::grpc::ChannelInterface>& channel, "
+ "::grpc::Channel>& channel, "
"const ::grpc::StubOptions& options = ::grpc::StubOptions());\n");
printer->Print("\n");
@@ -703,7 +702,7 @@
std::map<grpc::string, grpc::string> vars;
printer.Print(vars, "#include <grpc++/async_unary_call.h>\n");
- printer.Print(vars, "#include <grpc++/channel_interface.h>\n");
+ printer.Print(vars, "#include <grpc++/channel.h>\n");
printer.Print(vars, "#include <grpc++/impl/client_unary_call.h>\n");
printer.Print(vars, "#include <grpc++/impl/rpc_service_method.h>\n");
printer.Print(vars, "#include <grpc++/impl/service_type.h>\n");
@@ -738,7 +737,7 @@
"::grpc::ClientContext* context, "
"const $Request$& request, $Response$* response) {\n");
printer->Print(*vars,
- " return ::grpc::BlockingUnaryCall(channel(), "
+ " return ::grpc::BlockingUnaryCall(channel_.get(), "
"rpcmethod_$Method$_, "
"context, request, response);\n"
"}\n\n");
@@ -751,7 +750,7 @@
printer->Print(*vars,
" return new "
"::grpc::ClientAsyncResponseReader< $Response$>("
- "channel(), cq, "
+ "channel_.get(), cq, "
"rpcmethod_$Method$_, "
"context, request);\n"
"}\n\n");
@@ -762,7 +761,7 @@
"::grpc::ClientContext* context, $Response$* response) {\n");
printer->Print(*vars,
" return new ::grpc::ClientWriter< $Request$>("
- "channel(), "
+ "channel_.get(), "
"rpcmethod_$Method$_, "
"context, response);\n"
"}\n\n");
@@ -773,7 +772,7 @@
"::grpc::CompletionQueue* cq, void* tag) {\n");
printer->Print(*vars,
" return new ::grpc::ClientAsyncWriter< $Request$>("
- "channel(), cq, "
+ "channel_.get(), cq, "
"rpcmethod_$Method$_, "
"context, response, tag);\n"
"}\n\n");
@@ -785,7 +784,7 @@
"::grpc::ClientContext* context, const $Request$& request) {\n");
printer->Print(*vars,
" return new ::grpc::ClientReader< $Response$>("
- "channel(), "
+ "channel_.get(), "
"rpcmethod_$Method$_, "
"context, request);\n"
"}\n\n");
@@ -796,7 +795,7 @@
"::grpc::CompletionQueue* cq, void* tag) {\n");
printer->Print(*vars,
" return new ::grpc::ClientAsyncReader< $Response$>("
- "channel(), cq, "
+ "channel_.get(), cq, "
"rpcmethod_$Method$_, "
"context, request, tag);\n"
"}\n\n");
@@ -808,7 +807,7 @@
printer->Print(*vars,
" return new ::grpc::ClientReaderWriter< "
"$Request$, $Response$>("
- "channel(), "
+ "channel_.get(), "
"rpcmethod_$Method$_, "
"context);\n"
"}\n\n");
@@ -820,7 +819,7 @@
printer->Print(*vars,
" return new "
"::grpc::ClientAsyncReaderWriter< $Request$, $Response$>("
- "channel(), cq, "
+ "channel_.get(), cq, "
"rpcmethod_$Method$_, "
"context, tag);\n"
"}\n\n");
@@ -964,20 +963,19 @@
}
printer->Print(*vars, "};\n\n");
- printer->Print(
- *vars,
- "std::unique_ptr< $ns$$Service$::Stub> $ns$$Service$::NewStub("
- "const std::shared_ptr< ::grpc::ChannelInterface>& channel, "
- "const ::grpc::StubOptions& options) {\n"
- " std::unique_ptr< $ns$$Service$::Stub> stub(new "
- "$ns$$Service$::Stub(channel));\n"
- " return stub;\n"
- "}\n\n");
+ printer->Print(*vars,
+ "std::unique_ptr< $ns$$Service$::Stub> $ns$$Service$::NewStub("
+ "const std::shared_ptr< ::grpc::Channel>& channel, "
+ "const ::grpc::StubOptions& options) {\n"
+ " std::unique_ptr< $ns$$Service$::Stub> stub(new "
+ "$ns$$Service$::Stub(channel));\n"
+ " return stub;\n"
+ "}\n\n");
printer->Print(*vars,
"$ns$$Service$::Stub::Stub(const std::shared_ptr< "
- "::grpc::ChannelInterface>& channel)\n");
+ "::grpc::Channel>& channel)\n");
printer->Indent();
- printer->Print(": ::grpc::InternalStub(channel)");
+ printer->Print(": channel_(channel)");
for (int i = 0; i < service->method_count(); ++i) {
const grpc::protobuf::MethodDescriptor *method = service->method(i);
(*vars)["Method"] = method->name();
@@ -991,13 +989,12 @@
} else {
(*vars)["StreamingType"] = "BIDI_STREAMING";
}
- printer->Print(
- *vars,
- ", rpcmethod_$Method$_("
- "$prefix$$Service$_method_names[$Idx$], "
- "::grpc::RpcMethod::$StreamingType$, "
- "channel->RegisterMethod($prefix$$Service$_method_names[$Idx$])"
- ")\n");
+ printer->Print(*vars,
+ ", rpcmethod_$Method$_("
+ "$prefix$$Service$_method_names[$Idx$], "
+ "::grpc::RpcMethod::$StreamingType$, "
+ "channel"
+ ")\n");
}
printer->Print("{}\n\n");
printer->Outdent();
diff --git a/src/cpp/client/channel.cc b/src/cpp/client/channel.cc
index 17f31c2..bb4be07 100644
--- a/src/cpp/client/channel.cc
+++ b/src/cpp/client/channel.cc
@@ -31,7 +31,7 @@
*
*/
-#include "src/cpp/client/channel.h"
+#include <grpc++/channel.h>
#include <memory>
@@ -52,8 +52,6 @@
namespace grpc {
-Channel::Channel(grpc_channel* channel) : c_channel_(channel) {}
-
Channel::Channel(const grpc::string& host, grpc_channel* channel)
: host_(host), c_channel_(channel) {}
diff --git a/src/cpp/client/channel.h b/src/cpp/client/channel.h
deleted file mode 100644
index 7e406ad..0000000
--- a/src/cpp/client/channel.h
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- *
- * Copyright 2015, Google Inc.
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are
- * met:
- *
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above
- * copyright notice, this list of conditions and the following disclaimer
- * in the documentation and/or other materials provided with the
- * distribution.
- * * Neither the name of Google Inc. nor the names of its
- * contributors may be used to endorse or promote products derived from
- * this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
- */
-
-#ifndef GRPC_INTERNAL_CPP_CLIENT_CHANNEL_H
-#define GRPC_INTERNAL_CPP_CLIENT_CHANNEL_H
-
-#include <memory>
-
-#include <grpc++/channel_interface.h>
-#include <grpc++/config.h>
-#include <grpc++/impl/grpc_library.h>
-
-struct grpc_channel;
-
-namespace grpc {
-class Call;
-class CallOpSetInterface;
-class ChannelArguments;
-class CompletionQueue;
-class Credentials;
-class StreamContextInterface;
-
-class Channel GRPC_FINAL : public GrpcLibrary, public ChannelInterface {
- public:
- explicit Channel(grpc_channel* c_channel);
- Channel(const grpc::string& host, grpc_channel* c_channel);
- ~Channel() GRPC_OVERRIDE;
-
- void* RegisterMethod(const char* method) GRPC_OVERRIDE;
- Call CreateCall(const RpcMethod& method, ClientContext* context,
- CompletionQueue* cq) GRPC_OVERRIDE;
- void PerformOpsOnCall(CallOpSetInterface* ops, Call* call) GRPC_OVERRIDE;
-
- grpc_connectivity_state GetState(bool try_to_connect) GRPC_OVERRIDE;
-
- private:
- void NotifyOnStateChangeImpl(grpc_connectivity_state last_observed,
- gpr_timespec deadline, CompletionQueue* cq,
- void* tag) GRPC_OVERRIDE;
-
- bool WaitForStateChangeImpl(grpc_connectivity_state last_observed,
- gpr_timespec deadline) GRPC_OVERRIDE;
-
- const grpc::string host_;
- grpc_channel* const c_channel_; // owned
-};
-
-} // namespace grpc
-
-#endif // GRPC_INTERNAL_CPP_CLIENT_CHANNEL_H
diff --git a/src/cpp/client/client_context.cc b/src/cpp/client/client_context.cc
index b8caa1e..a3906fc 100644
--- a/src/cpp/client/client_context.cc
+++ b/src/cpp/client/client_context.cc
@@ -71,7 +71,7 @@
}
void ClientContext::set_call(grpc_call* call,
- const std::shared_ptr<ChannelInterface>& channel) {
+ const std::shared_ptr<Channel>& channel) {
GPR_ASSERT(call_ == nullptr);
call_ = call;
channel_ = channel;
diff --git a/src/cpp/client/create_channel.cc b/src/cpp/client/create_channel.cc
index 5ae772f..70ea7e0 100644
--- a/src/cpp/client/create_channel.cc
+++ b/src/cpp/client/create_channel.cc
@@ -34,15 +34,16 @@
#include <memory>
#include <sstream>
-#include "src/cpp/client/channel.h"
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/channel_arguments.h>
#include <grpc++/create_channel.h>
+#include "src/cpp/client/create_channel_internal.h"
+
namespace grpc {
class ChannelArguments;
-std::shared_ptr<ChannelInterface> CreateChannel(
+std::shared_ptr<Channel> CreateChannel(
const grpc::string& target, const std::shared_ptr<Credentials>& creds,
const ChannelArguments& args) {
ChannelArguments cp_args = args;
@@ -50,10 +51,10 @@
user_agent_prefix << "grpc-c++/" << grpc_version_string();
cp_args.SetString(GRPC_ARG_PRIMARY_USER_AGENT_STRING,
user_agent_prefix.str());
- return creds ? creds->CreateChannel(target, cp_args)
- : std::shared_ptr<ChannelInterface>(
- new Channel(grpc_lame_client_channel_create(
- NULL, GRPC_STATUS_INVALID_ARGUMENT,
- "Invalid credentials.")));
+ return creds
+ ? creds->CreateChannel(target, cp_args)
+ : CreateChannelInternal("", grpc_lame_client_channel_create(
+ NULL, GRPC_STATUS_INVALID_ARGUMENT,
+ "Invalid credentials."));
}
} // namespace grpc
diff --git a/src/cpp/client/internal_stub.cc b/src/cpp/client/create_channel_internal.cc
similarity index 82%
rename from src/cpp/client/internal_stub.cc
rename to src/cpp/client/create_channel_internal.cc
index 91724a4..9c5ab03 100644
--- a/src/cpp/client/internal_stub.cc
+++ b/src/cpp/client/create_channel_internal.cc
@@ -31,6 +31,16 @@
*
*/
-#include <grpc++/impl/internal_stub.h>
+#include <memory>
-namespace grpc {} // namespace grpc
+#include <grpc++/channel.h>
+
+struct grpc_channel;
+
+namespace grpc {
+
+std::shared_ptr<Channel> CreateChannelInternal(const grpc::string& host,
+ grpc_channel* c_channel) {
+ return std::shared_ptr<Channel>(new Channel(host, c_channel));
+}
+} // namespace grpc
diff --git a/include/grpc++/impl/internal_stub.h b/src/cpp/client/create_channel_internal.h
similarity index 78%
rename from include/grpc++/impl/internal_stub.h
rename to src/cpp/client/create_channel_internal.h
index 370a3b8..1692471 100644
--- a/include/grpc++/impl/internal_stub.h
+++ b/src/cpp/client/create_channel_internal.h
@@ -31,27 +31,21 @@
*
*/
-#ifndef GRPCXX_IMPL_INTERNAL_STUB_H
-#define GRPCXX_IMPL_INTERNAL_STUB_H
+#ifndef GRPC_INTERNAL_CPP_CLIENT_CREATE_CHANNEL_INTERNAL_H
+#define GRPC_INTERNAL_CPP_CLIENT_CREATE_CHANNEL_INTERNAL_H
#include <memory>
-#include <grpc++/channel_interface.h>
+#include <grpc++/config.h>
+
+struct grpc_channel;
namespace grpc {
+class Channel;
-class InternalStub {
- public:
- InternalStub(const std::shared_ptr<ChannelInterface>& channel)
- : channel_(channel) {}
- virtual ~InternalStub() {}
-
- ChannelInterface* channel() { return channel_.get(); }
-
- private:
- const std::shared_ptr<ChannelInterface> channel_;
-};
+std::shared_ptr<Channel> CreateChannelInternal(const grpc::string& host,
+ grpc_channel* c_channel);
} // namespace grpc
-#endif // GRPCXX_IMPL_INTERNAL_STUB_H
+#endif // GRPC_INTERNAL_CPP_CLIENT_CREATE_CHANNEL_INTERNAL_H
diff --git a/src/cpp/client/generic_stub.cc b/src/cpp/client/generic_stub.cc
index 0c90578..ee89c02 100644
--- a/src/cpp/client/generic_stub.cc
+++ b/src/cpp/client/generic_stub.cc
@@ -44,8 +44,7 @@
return std::unique_ptr<GenericClientAsyncReaderWriter>(
new GenericClientAsyncReaderWriter(
channel_.get(), cq,
- RpcMethod(method.c_str(), RpcMethod::BIDI_STREAMING, nullptr),
- context, tag));
+ RpcMethod(method.c_str(), RpcMethod::BIDI_STREAMING), context, tag));
}
} // namespace grpc
diff --git a/src/cpp/client/insecure_credentials.cc b/src/cpp/client/insecure_credentials.cc
index 2f9357b..9793140 100644
--- a/src/cpp/client/insecure_credentials.cc
+++ b/src/cpp/client/insecure_credentials.cc
@@ -34,22 +34,24 @@
#include <grpc/grpc.h>
#include <grpc/support/log.h>
+#include <grpc++/channel.h>
#include <grpc++/channel_arguments.h>
#include <grpc++/config.h>
#include <grpc++/credentials.h>
-#include "src/cpp/client/channel.h"
+#include "src/cpp/client/create_channel_internal.h"
namespace grpc {
namespace {
class InsecureCredentialsImpl GRPC_FINAL : public Credentials {
public:
- std::shared_ptr<grpc::ChannelInterface> CreateChannel(
+ std::shared_ptr<grpc::Channel> CreateChannel(
const string& target, const grpc::ChannelArguments& args) GRPC_OVERRIDE {
grpc_channel_args channel_args;
args.SetChannelArgs(&channel_args);
- return std::shared_ptr<ChannelInterface>(new Channel(
- grpc_insecure_channel_create(target.c_str(), &channel_args, nullptr)));
+ return CreateChannelInternal(
+ "",
+ grpc_insecure_channel_create(target.c_str(), &channel_args, nullptr));
}
// InsecureCredentials should not be applied to a call.
diff --git a/src/cpp/client/secure_credentials.cc b/src/cpp/client/secure_credentials.cc
index 6cd6b77..1e912c6 100644
--- a/src/cpp/client/secure_credentials.cc
+++ b/src/cpp/client/secure_credentials.cc
@@ -32,21 +32,21 @@
*/
#include <grpc/support/log.h>
-
+#include <grpc++/channel.h>
#include <grpc++/channel_arguments.h>
#include <grpc++/impl/grpc_library.h>
-#include "src/cpp/client/channel.h"
+#include "src/cpp/client/create_channel_internal.h"
#include "src/cpp/client/secure_credentials.h"
namespace grpc {
-std::shared_ptr<grpc::ChannelInterface> SecureCredentials::CreateChannel(
+std::shared_ptr<grpc::Channel> SecureCredentials::CreateChannel(
const string& target, const grpc::ChannelArguments& args) {
grpc_channel_args channel_args;
args.SetChannelArgs(&channel_args);
- return std::shared_ptr<ChannelInterface>(new Channel(
+ return CreateChannelInternal(
args.GetSslTargetNameOverride(),
- grpc_secure_channel_create(c_creds_, target.c_str(), &channel_args)));
+ grpc_secure_channel_create(c_creds_, target.c_str(), &channel_args));
}
bool SecureCredentials::ApplyToCall(grpc_call* call) {
diff --git a/src/cpp/client/secure_credentials.h b/src/cpp/client/secure_credentials.h
index c2b8d43..974d835 100644
--- a/src/cpp/client/secure_credentials.h
+++ b/src/cpp/client/secure_credentials.h
@@ -48,7 +48,7 @@
grpc_credentials* GetRawCreds() { return c_creds_; }
bool ApplyToCall(grpc_call* call) GRPC_OVERRIDE;
- std::shared_ptr<grpc::ChannelInterface> CreateChannel(
+ std::shared_ptr<grpc::Channel> CreateChannel(
const string& target, const grpc::ChannelArguments& args) GRPC_OVERRIDE;
SecureCredentials* AsSecureCredentials() GRPC_OVERRIDE { return this; }
diff --git a/src/cpp/common/call.cc b/src/cpp/common/call.cc
index 0a5c976..479f14d 100644
--- a/src/cpp/common/call.cc
+++ b/src/cpp/common/call.cc
@@ -36,7 +36,7 @@
#include <grpc/support/alloc.h>
#include <grpc++/byte_buffer.h>
#include <grpc++/client_context.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include "src/core/profiling/timers.h"
diff --git a/test/cpp/end2end/async_end2end_test.cc b/test/cpp/end2end/async_end2end_test.cc
index a30c841..7006ebb 100644
--- a/test/cpp/end2end/async_end2end_test.cc
+++ b/test/cpp/end2end/async_end2end_test.cc
@@ -39,7 +39,7 @@
#include "test/cpp/util/echo.grpc.pb.h"
#include <grpc++/async_unary_call.h>
#include <grpc++/channel_arguments.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/create_channel.h>
#include <grpc++/credentials.h>
@@ -136,7 +136,7 @@
}
void ResetStub() {
- std::shared_ptr<ChannelInterface> channel = CreateChannel(
+ std::shared_ptr<Channel> channel = CreateChannel(
server_address_.str(), InsecureCredentials(), ChannelArguments());
stub_ = std::move(grpc::cpp::test::util::TestService::NewStub(channel));
}
@@ -672,7 +672,7 @@
}
TEST_F(AsyncEnd2endTest, UnimplementedRpc) {
- std::shared_ptr<ChannelInterface> channel = CreateChannel(
+ std::shared_ptr<Channel> channel = CreateChannel(
server_address_.str(), InsecureCredentials(), ChannelArguments());
std::unique_ptr<grpc::cpp::test::util::UnimplementedService::Stub> stub;
stub =
diff --git a/test/cpp/end2end/client_crash_test.cc b/test/cpp/end2end/client_crash_test.cc
index 1c2a5c3..89708a2 100644
--- a/test/cpp/end2end/client_crash_test.cc
+++ b/test/cpp/end2end/client_crash_test.cc
@@ -36,7 +36,7 @@
#include "test/cpp/util/echo_duplicate.grpc.pb.h"
#include "test/cpp/util/echo.grpc.pb.h"
#include <grpc++/channel_arguments.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/create_channel.h>
#include <grpc++/credentials.h>
diff --git a/test/cpp/end2end/end2end_test.cc b/test/cpp/end2end/end2end_test.cc
index 350b107..fc4e88c 100644
--- a/test/cpp/end2end/end2end_test.cc
+++ b/test/cpp/end2end/end2end_test.cc
@@ -41,7 +41,7 @@
#include "test/cpp/util/echo_duplicate.grpc.pb.h"
#include "test/cpp/util/echo.grpc.pb.h"
#include <grpc++/channel_arguments.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/create_channel.h>
#include <grpc++/credentials.h>
@@ -106,7 +106,7 @@
class Proxy : public ::grpc::cpp::test::util::TestService::Service {
public:
- Proxy(std::shared_ptr<ChannelInterface> channel)
+ Proxy(std::shared_ptr<Channel> channel)
: stub_(grpc::cpp::test::util::TestService::NewStub(channel)) {}
Status Echo(ServerContext* server_context, const EchoRequest* request,
@@ -319,7 +319,7 @@
stub_ = std::move(grpc::cpp::test::util::TestService::NewStub(channel_));
}
- std::shared_ptr<ChannelInterface> channel_;
+ std::shared_ptr<Channel> channel_;
std::unique_ptr<grpc::cpp::test::util::TestService::Stub> stub_;
std::unique_ptr<Server> server_;
std::unique_ptr<Server> proxy_server_;
@@ -571,7 +571,7 @@
TEST_F(End2endTest, BadCredentials) {
std::shared_ptr<Credentials> bad_creds = ServiceAccountCredentials("", "", 1);
EXPECT_EQ(static_cast<Credentials*>(nullptr), bad_creds.get());
- std::shared_ptr<ChannelInterface> channel =
+ std::shared_ptr<Channel> channel =
CreateChannel(server_address_.str(), bad_creds, ChannelArguments());
std::unique_ptr<grpc::cpp::test::util::TestService::Stub> stub(
grpc::cpp::test::util::TestService::NewStub(channel));
diff --git a/test/cpp/end2end/generic_end2end_test.cc b/test/cpp/end2end/generic_end2end_test.cc
index 3120cec..b817198 100644
--- a/test/cpp/end2end/generic_end2end_test.cc
+++ b/test/cpp/end2end/generic_end2end_test.cc
@@ -41,7 +41,7 @@
#include <grpc++/async_unary_call.h>
#include <grpc++/byte_buffer.h>
#include <grpc++/channel_arguments.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/create_channel.h>
#include <grpc++/credentials.h>
@@ -127,7 +127,7 @@
}
void ResetStub() {
- std::shared_ptr<ChannelInterface> channel = CreateChannel(
+ std::shared_ptr<Channel> channel = CreateChannel(
server_address_.str(), InsecureCredentials(), ChannelArguments());
generic_stub_.reset(new GenericStub(channel));
}
diff --git a/test/cpp/end2end/mock_test.cc b/test/cpp/end2end/mock_test.cc
index 32130e2..96b6ecb 100644
--- a/test/cpp/end2end/mock_test.cc
+++ b/test/cpp/end2end/mock_test.cc
@@ -38,7 +38,7 @@
#include "test/cpp/util/echo_duplicate.grpc.pb.h"
#include "test/cpp/util/echo.grpc.pb.h"
#include <grpc++/channel_arguments.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/create_channel.h>
#include <grpc++/credentials.h>
@@ -251,7 +251,7 @@
void TearDown() GRPC_OVERRIDE { server_->Shutdown(); }
void ResetStub() {
- std::shared_ptr<ChannelInterface> channel = CreateChannel(
+ std::shared_ptr<Channel> channel = CreateChannel(
server_address_.str(), InsecureCredentials(), ChannelArguments());
stub_ = std::move(grpc::cpp::test::util::TestService::NewStub(channel));
}
diff --git a/test/cpp/end2end/server_crash_test.cc b/test/cpp/end2end/server_crash_test.cc
index 5c7bb4e..2688f2c 100644
--- a/test/cpp/end2end/server_crash_test.cc
+++ b/test/cpp/end2end/server_crash_test.cc
@@ -36,7 +36,7 @@
#include "test/cpp/util/echo_duplicate.grpc.pb.h"
#include "test/cpp/util/echo.grpc.pb.h"
#include <grpc++/channel_arguments.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/create_channel.h>
#include <grpc++/credentials.h>
diff --git a/test/cpp/end2end/server_crash_test_client.cc b/test/cpp/end2end/server_crash_test_client.cc
index 1da4f05..52dce8f 100644
--- a/test/cpp/end2end/server_crash_test_client.cc
+++ b/test/cpp/end2end/server_crash_test_client.cc
@@ -38,7 +38,7 @@
#include <gflags/gflags.h>
#include <grpc++/channel_arguments.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/create_channel.h>
#include <grpc++/credentials.h>
diff --git a/test/cpp/end2end/thread_stress_test.cc b/test/cpp/end2end/thread_stress_test.cc
index ff9c945..e59a77d 100644
--- a/test/cpp/end2end/thread_stress_test.cc
+++ b/test/cpp/end2end/thread_stress_test.cc
@@ -39,7 +39,7 @@
#include "test/cpp/util/echo_duplicate.grpc.pb.h"
#include "test/cpp/util/echo.grpc.pb.h"
#include <grpc++/channel_arguments.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/create_channel.h>
#include <grpc++/credentials.h>
@@ -197,7 +197,7 @@
void TearDown() GRPC_OVERRIDE { server_->Shutdown(); }
void ResetStub() {
- std::shared_ptr<ChannelInterface> channel = CreateChannel(
+ std::shared_ptr<Channel> channel = CreateChannel(
server_address_.str(), InsecureCredentials(), ChannelArguments());
stub_ = std::move(grpc::cpp::test::util::TestService::NewStub(channel));
}
diff --git a/test/cpp/end2end/zookeeper_test.cc b/test/cpp/end2end/zookeeper_test.cc
index f5eba66..d7fac3d 100644
--- a/test/cpp/end2end/zookeeper_test.cc
+++ b/test/cpp/end2end/zookeeper_test.cc
@@ -36,7 +36,7 @@
#include "test/cpp/util/echo.grpc.pb.h"
#include "src/core/support/env.h"
#include <grpc++/channel_arguments.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/create_channel.h>
#include <grpc++/credentials.h>
@@ -170,7 +170,7 @@
return strs.str();
}
- std::shared_ptr<ChannelInterface> channel_;
+ std::shared_ptr<Channel> channel_;
std::unique_ptr<grpc::cpp::test::util::TestService::Stub> stub_;
std::unique_ptr<Server> server1_;
std::unique_ptr<Server> server2_;
diff --git a/test/cpp/interop/client.cc b/test/cpp/interop/client.cc
index 48143b2..d9e4f1b 100644
--- a/test/cpp/interop/client.cc
+++ b/test/cpp/interop/client.cc
@@ -38,7 +38,7 @@
#include <grpc/grpc.h>
#include <grpc/support/log.h>
#include <gflags/gflags.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/status.h>
#include <grpc++/stream.h>
diff --git a/test/cpp/interop/client_helper.cc b/test/cpp/interop/client_helper.cc
index da5627d..be652a4 100644
--- a/test/cpp/interop/client_helper.cc
+++ b/test/cpp/interop/client_helper.cc
@@ -44,7 +44,7 @@
#include <grpc/support/log.h>
#include <gflags/gflags.h>
#include <grpc++/channel_arguments.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/create_channel.h>
#include <grpc++/credentials.h>
#include <grpc++/stream.h>
@@ -102,7 +102,7 @@
return access_token;
}
-std::shared_ptr<ChannelInterface> CreateChannelForTestCase(
+std::shared_ptr<Channel> CreateChannelForTestCase(
const grpc::string& test_case) {
GPR_ASSERT(FLAGS_server_port);
const int host_port_buf_size = 1024;
diff --git a/test/cpp/interop/client_helper.h b/test/cpp/interop/client_helper.h
index edc69e9..d4c1443 100644
--- a/test/cpp/interop/client_helper.h
+++ b/test/cpp/interop/client_helper.h
@@ -37,7 +37,7 @@
#include <memory>
#include <grpc++/config.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include "src/core/surface/call.h"
@@ -48,7 +48,7 @@
grpc::string GetOauth2AccessToken();
-std::shared_ptr<ChannelInterface> CreateChannelForTestCase(
+std::shared_ptr<Channel> CreateChannelForTestCase(
const grpc::string& test_case);
class InteropClientContextInspector {
diff --git a/test/cpp/interop/interop_client.cc b/test/cpp/interop/interop_client.cc
index 5ed14d5..c73505c 100644
--- a/test/cpp/interop/interop_client.cc
+++ b/test/cpp/interop/interop_client.cc
@@ -42,7 +42,7 @@
#include <grpc/support/log.h>
#include <grpc/support/string_util.h>
#include <grpc/support/useful.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/credentials.h>
#include <grpc++/status.h>
@@ -84,7 +84,7 @@
}
} // namespace
-InteropClient::InteropClient(std::shared_ptr<ChannelInterface> channel)
+InteropClient::InteropClient(std::shared_ptr<Channel> channel)
: channel_(channel) {}
void InteropClient::AssertOkOrPrintErrorStatus(const Status& s) {
diff --git a/test/cpp/interop/interop_client.h b/test/cpp/interop/interop_client.h
index d6fb9bf..354c2c6 100644
--- a/test/cpp/interop/interop_client.h
+++ b/test/cpp/interop/interop_client.h
@@ -36,7 +36,7 @@
#include <memory>
#include <grpc/grpc.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/status.h>
#include "test/proto/messages.grpc.pb.h"
@@ -45,10 +45,10 @@
class InteropClient {
public:
- explicit InteropClient(std::shared_ptr<ChannelInterface> channel);
+ explicit InteropClient(std::shared_ptr<Channel> channel);
~InteropClient() {}
- void Reset(std::shared_ptr<ChannelInterface> channel) { channel_ = channel; }
+ void Reset(std::shared_ptr<Channel> channel) { channel_ = channel; }
void DoEmpty();
void DoLargeUnary();
@@ -82,7 +82,7 @@
void PerformLargeUnary(SimpleRequest* request, SimpleResponse* response);
void AssertOkOrPrintErrorStatus(const Status& s);
- std::shared_ptr<ChannelInterface> channel_;
+ std::shared_ptr<Channel> channel_;
};
} // namespace testing
diff --git a/test/cpp/interop/reconnect_interop_client.cc b/test/cpp/interop/reconnect_interop_client.cc
index 65f0980..675c6ff 100644
--- a/test/cpp/interop/reconnect_interop_client.cc
+++ b/test/cpp/interop/reconnect_interop_client.cc
@@ -37,7 +37,7 @@
#include <grpc/grpc.h>
#include <grpc/support/log.h>
#include <gflags/gflags.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/status.h>
#include "test/cpp/util/create_test_channel.h"
@@ -50,7 +50,7 @@
DEFINE_int32(server_retry_port, 0, "Server port for testing reconnection.");
DEFINE_string(server_host, "127.0.0.1", "Server host to connect to");
-using grpc::ChannelInterface;
+using grpc::Channel;
using grpc::ClientContext;
using grpc::CreateTestChannel;
using grpc::Status;
@@ -78,7 +78,7 @@
gpr_log(GPR_INFO, "Starting connections with retries.");
server_address.str("");
server_address << FLAGS_server_host << ':' << FLAGS_server_retry_port;
- std::shared_ptr<ChannelInterface> retry_channel =
+ std::shared_ptr<Channel> retry_channel =
CreateTestChannel(server_address.str(), true);
// About 13 retries.
const int kDeadlineSeconds = 540;
diff --git a/test/cpp/qps/client.h b/test/cpp/qps/client.h
index 1c4f463..5395d02 100644
--- a/test/cpp/qps/client.h
+++ b/test/cpp/qps/client.h
@@ -125,11 +125,11 @@
channel_ = CreateTestChannel(target, config.enable_ssl());
stub_ = TestService::NewStub(channel_);
}
- ChannelInterface* get_channel() { return channel_.get(); }
+ Channel* get_channel() { return channel_.get(); }
TestService::Stub* get_stub() { return stub_.get(); }
private:
- std::shared_ptr<ChannelInterface> channel_;
+ std::shared_ptr<Channel> channel_;
std::unique_ptr<TestService::Stub> stub_;
};
std::vector<ClientChannelInfo> channels_;
diff --git a/test/cpp/qps/perf_db_client.h b/test/cpp/qps/perf_db_client.h
index 7a9d86d..3433cd8 100644
--- a/test/cpp/qps/perf_db_client.h
+++ b/test/cpp/qps/perf_db_client.h
@@ -38,7 +38,7 @@
#include <grpc/grpc.h>
#include <grpc++/channel_arguments.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/create_channel.h>
#include <grpc++/credentials.h>
@@ -65,7 +65,7 @@
client_user_time_ = DBL_MIN;
}
- void init(std::shared_ptr<ChannelInterface> channel) {
+ void init(std::shared_ptr<Channel> channel) {
stub_ = PerfDbTransfer::NewStub(channel);
}
diff --git a/test/cpp/util/cli_call.cc b/test/cpp/util/cli_call.cc
index ac88910..d0a300f 100644
--- a/test/cpp/util/cli_call.cc
+++ b/test/cpp/util/cli_call.cc
@@ -36,7 +36,7 @@
#include <iostream>
#include <grpc++/byte_buffer.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/generic_stub.h>
#include <grpc++/status.h>
@@ -52,7 +52,7 @@
void* tag(int i) { return (void*)(gpr_intptr)i; }
} // namespace
-Status CliCall::Call(std::shared_ptr<grpc::ChannelInterface> channel,
+Status CliCall::Call(std::shared_ptr<grpc::Channel> channel,
const grpc::string& method, const grpc::string& request,
grpc::string* response, const MetadataContainer& metadata,
MetadataContainer* server_initial_metadata,
diff --git a/test/cpp/util/cli_call.h b/test/cpp/util/cli_call.h
index 8d114c9..46b5dd3 100644
--- a/test/cpp/util/cli_call.h
+++ b/test/cpp/util/cli_call.h
@@ -36,7 +36,7 @@
#include <map>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/config.h>
#include <grpc++/status.h>
@@ -46,7 +46,7 @@
class CliCall GRPC_FINAL {
public:
typedef std::multimap<grpc::string, grpc::string> MetadataContainer;
- static Status Call(std::shared_ptr<grpc::ChannelInterface> channel,
+ static Status Call(std::shared_ptr<grpc::Channel> channel,
const grpc::string& method, const grpc::string& request,
grpc::string* response, const MetadataContainer& metadata,
MetadataContainer* server_initial_metadata,
diff --git a/test/cpp/util/cli_call_test.cc b/test/cpp/util/cli_call_test.cc
index 848a3ae..146e967 100644
--- a/test/cpp/util/cli_call_test.cc
+++ b/test/cpp/util/cli_call_test.cc
@@ -35,7 +35,7 @@
#include "test/cpp/util/cli_call.h"
#include "test/cpp/util/echo.grpc.pb.h"
#include <grpc++/channel_arguments.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/create_channel.h>
#include <grpc++/credentials.h>
@@ -97,7 +97,7 @@
stub_ = std::move(grpc::cpp::test::util::TestService::NewStub(channel_));
}
- std::shared_ptr<ChannelInterface> channel_;
+ std::shared_ptr<Channel> channel_;
std::unique_ptr<grpc::cpp::test::util::TestService::Stub> stub_;
std::unique_ptr<Server> server_;
std::ostringstream server_address_;
diff --git a/test/cpp/util/create_test_channel.cc b/test/cpp/util/create_test_channel.cc
index dc48fa2..43e719e 100644
--- a/test/cpp/util/create_test_channel.cc
+++ b/test/cpp/util/create_test_channel.cc
@@ -55,7 +55,7 @@
// CreateTestChannel("test.google.com:443", "", true, true, creds);
// same as above
// CreateTestChannel("", "test.google.com:443", true, true, creds);
-std::shared_ptr<ChannelInterface> CreateTestChannel(
+std::shared_ptr<Channel> CreateTestChannel(
const grpc::string& server, const grpc::string& override_hostname,
bool enable_ssl, bool use_prod_roots,
const std::shared_ptr<Credentials>& creds) {
@@ -80,7 +80,7 @@
}
}
-std::shared_ptr<ChannelInterface> CreateTestChannel(
+std::shared_ptr<Channel> CreateTestChannel(
const grpc::string& server, const grpc::string& override_hostname,
bool enable_ssl, bool use_prod_roots) {
return CreateTestChannel(server, override_hostname, enable_ssl,
@@ -88,8 +88,8 @@
}
// Shortcut for end2end and interop tests.
-std::shared_ptr<ChannelInterface> CreateTestChannel(const grpc::string& server,
- bool enable_ssl) {
+std::shared_ptr<Channel> CreateTestChannel(const grpc::string& server,
+ bool enable_ssl) {
return CreateTestChannel(server, "foo.test.google.fr", enable_ssl, false);
}
diff --git a/test/cpp/util/create_test_channel.h b/test/cpp/util/create_test_channel.h
index 5f2609d..129cc74 100644
--- a/test/cpp/util/create_test_channel.h
+++ b/test/cpp/util/create_test_channel.h
@@ -40,16 +40,16 @@
#include <grpc++/credentials.h>
namespace grpc {
-class ChannelInterface;
+class Channel;
-std::shared_ptr<ChannelInterface> CreateTestChannel(const grpc::string& server,
- bool enable_ssl);
+std::shared_ptr<Channel> CreateTestChannel(const grpc::string& server,
+ bool enable_ssl);
-std::shared_ptr<ChannelInterface> CreateTestChannel(
+std::shared_ptr<Channel> CreateTestChannel(
const grpc::string& server, const grpc::string& override_hostname,
bool enable_ssl, bool use_prod_roots);
-std::shared_ptr<ChannelInterface> CreateTestChannel(
+std::shared_ptr<Channel> CreateTestChannel(
const grpc::string& server, const grpc::string& override_hostname,
bool enable_ssl, bool use_prod_roots,
const std::shared_ptr<Credentials>& creds);
diff --git a/test/cpp/util/grpc_cli.cc b/test/cpp/util/grpc_cli.cc
index 3c3baeb..15c56a3 100644
--- a/test/cpp/util/grpc_cli.cc
+++ b/test/cpp/util/grpc_cli.cc
@@ -67,7 +67,7 @@
#include "test/cpp/util/cli_call.h"
#include "test/cpp/util/test_config.h"
#include <grpc++/channel_arguments.h>
-#include <grpc++/channel_interface.h>
+#include <grpc++/channel.h>
#include <grpc++/create_channel.h>
#include <grpc++/credentials.h>
@@ -154,7 +154,7 @@
creds = grpc::SslCredentials(grpc::SslCredentialsOptions());
}
}
- std::shared_ptr<grpc::ChannelInterface> channel =
+ std::shared_ptr<grpc::Channel> channel =
grpc::CreateChannel(server_address, creds, grpc::ChannelArguments());
grpc::string response;
diff --git a/tools/doxygen/Doxyfile.c++ b/tools/doxygen/Doxyfile.c++
index 790e637..8daeb13 100644
--- a/tools/doxygen/Doxyfile.c++
+++ b/tools/doxygen/Doxyfile.c++
@@ -764,8 +764,8 @@
include/grpc++/async_unary_call.h \
include/grpc++/auth_context.h \
include/grpc++/byte_buffer.h \
+include/grpc++/channel.h \
include/grpc++/channel_arguments.h \
-include/grpc++/channel_interface.h \
include/grpc++/client_context.h \
include/grpc++/completion_queue.h \
include/grpc++/config.h \
@@ -778,7 +778,6 @@
include/grpc++/impl/call.h \
include/grpc++/impl/client_unary_call.h \
include/grpc++/impl/grpc_library.h \
-include/grpc++/impl/internal_stub.h \
include/grpc++/impl/proto_utils.h \
include/grpc++/impl/rpc_method.h \
include/grpc++/impl/rpc_service_method.h \
diff --git a/tools/doxygen/Doxyfile.c++.internal b/tools/doxygen/Doxyfile.c++.internal
index cd1279e..23ff05f 100644
--- a/tools/doxygen/Doxyfile.c++.internal
+++ b/tools/doxygen/Doxyfile.c++.internal
@@ -764,8 +764,8 @@
include/grpc++/async_unary_call.h \
include/grpc++/auth_context.h \
include/grpc++/byte_buffer.h \
+include/grpc++/channel.h \
include/grpc++/channel_arguments.h \
-include/grpc++/channel_interface.h \
include/grpc++/client_context.h \
include/grpc++/completion_queue.h \
include/grpc++/config.h \
@@ -778,7 +778,6 @@
include/grpc++/impl/call.h \
include/grpc++/impl/client_unary_call.h \
include/grpc++/impl/grpc_library.h \
-include/grpc++/impl/internal_stub.h \
include/grpc++/impl/proto_utils.h \
include/grpc++/impl/rpc_method.h \
include/grpc++/impl/rpc_service_method.h \
@@ -804,7 +803,7 @@
src/cpp/client/secure_credentials.h \
src/cpp/common/secure_auth_context.h \
src/cpp/server/secure_server_credentials.h \
-src/cpp/client/channel.h \
+src/cpp/client/create_channel_internal.h \
src/cpp/common/create_auth_context.h \
src/cpp/client/secure_channel_arguments.cc \
src/cpp/client/secure_credentials.cc \
@@ -816,10 +815,10 @@
src/cpp/client/channel_arguments.cc \
src/cpp/client/client_context.cc \
src/cpp/client/create_channel.cc \
+src/cpp/client/create_channel_internal.cc \
src/cpp/client/credentials.cc \
src/cpp/client/generic_stub.cc \
src/cpp/client/insecure_credentials.cc \
-src/cpp/client/internal_stub.cc \
src/cpp/common/call.cc \
src/cpp/common/completion_queue.cc \
src/cpp/common/rpc_method.cc \
diff --git a/tools/run_tests/sources_and_headers.json b/tools/run_tests/sources_and_headers.json
index 50f0785..9446368 100644
--- a/tools/run_tests/sources_and_headers.json
+++ b/tools/run_tests/sources_and_headers.json
@@ -13122,8 +13122,8 @@
"include/grpc++/async_unary_call.h",
"include/grpc++/auth_context.h",
"include/grpc++/byte_buffer.h",
+ "include/grpc++/channel.h",
"include/grpc++/channel_arguments.h",
- "include/grpc++/channel_interface.h",
"include/grpc++/client_context.h",
"include/grpc++/completion_queue.h",
"include/grpc++/config.h",
@@ -13136,7 +13136,6 @@
"include/grpc++/impl/call.h",
"include/grpc++/impl/client_unary_call.h",
"include/grpc++/impl/grpc_library.h",
- "include/grpc++/impl/internal_stub.h",
"include/grpc++/impl/proto_utils.h",
"include/grpc++/impl/rpc_method.h",
"include/grpc++/impl/rpc_service_method.h",
@@ -13159,7 +13158,7 @@
"include/grpc++/stub_options.h",
"include/grpc++/thread_pool_interface.h",
"include/grpc++/time.h",
- "src/cpp/client/channel.h",
+ "src/cpp/client/create_channel_internal.h",
"src/cpp/client/secure_credentials.h",
"src/cpp/common/create_auth_context.h",
"src/cpp/common/secure_auth_context.h",
@@ -13172,8 +13171,8 @@
"include/grpc++/async_unary_call.h",
"include/grpc++/auth_context.h",
"include/grpc++/byte_buffer.h",
+ "include/grpc++/channel.h",
"include/grpc++/channel_arguments.h",
- "include/grpc++/channel_interface.h",
"include/grpc++/client_context.h",
"include/grpc++/completion_queue.h",
"include/grpc++/config.h",
@@ -13186,7 +13185,6 @@
"include/grpc++/impl/call.h",
"include/grpc++/impl/client_unary_call.h",
"include/grpc++/impl/grpc_library.h",
- "include/grpc++/impl/internal_stub.h",
"include/grpc++/impl/proto_utils.h",
"include/grpc++/impl/rpc_method.h",
"include/grpc++/impl/rpc_service_method.h",
@@ -13210,14 +13208,14 @@
"include/grpc++/thread_pool_interface.h",
"include/grpc++/time.h",
"src/cpp/client/channel.cc",
- "src/cpp/client/channel.h",
"src/cpp/client/channel_arguments.cc",
"src/cpp/client/client_context.cc",
"src/cpp/client/create_channel.cc",
+ "src/cpp/client/create_channel_internal.cc",
+ "src/cpp/client/create_channel_internal.h",
"src/cpp/client/credentials.cc",
"src/cpp/client/generic_stub.cc",
"src/cpp/client/insecure_credentials.cc",
- "src/cpp/client/internal_stub.cc",
"src/cpp/client/secure_channel_arguments.cc",
"src/cpp/client/secure_credentials.cc",
"src/cpp/client/secure_credentials.h",
@@ -13296,8 +13294,8 @@
"include/grpc++/async_unary_call.h",
"include/grpc++/auth_context.h",
"include/grpc++/byte_buffer.h",
+ "include/grpc++/channel.h",
"include/grpc++/channel_arguments.h",
- "include/grpc++/channel_interface.h",
"include/grpc++/client_context.h",
"include/grpc++/completion_queue.h",
"include/grpc++/config.h",
@@ -13310,7 +13308,6 @@
"include/grpc++/impl/call.h",
"include/grpc++/impl/client_unary_call.h",
"include/grpc++/impl/grpc_library.h",
- "include/grpc++/impl/internal_stub.h",
"include/grpc++/impl/proto_utils.h",
"include/grpc++/impl/rpc_method.h",
"include/grpc++/impl/rpc_service_method.h",
@@ -13333,7 +13330,7 @@
"include/grpc++/stub_options.h",
"include/grpc++/thread_pool_interface.h",
"include/grpc++/time.h",
- "src/cpp/client/channel.h",
+ "src/cpp/client/create_channel_internal.h",
"src/cpp/common/create_auth_context.h"
],
"language": "c++",
@@ -13343,8 +13340,8 @@
"include/grpc++/async_unary_call.h",
"include/grpc++/auth_context.h",
"include/grpc++/byte_buffer.h",
+ "include/grpc++/channel.h",
"include/grpc++/channel_arguments.h",
- "include/grpc++/channel_interface.h",
"include/grpc++/client_context.h",
"include/grpc++/completion_queue.h",
"include/grpc++/config.h",
@@ -13357,7 +13354,6 @@
"include/grpc++/impl/call.h",
"include/grpc++/impl/client_unary_call.h",
"include/grpc++/impl/grpc_library.h",
- "include/grpc++/impl/internal_stub.h",
"include/grpc++/impl/proto_utils.h",
"include/grpc++/impl/rpc_method.h",
"include/grpc++/impl/rpc_service_method.h",
@@ -13381,14 +13377,14 @@
"include/grpc++/thread_pool_interface.h",
"include/grpc++/time.h",
"src/cpp/client/channel.cc",
- "src/cpp/client/channel.h",
"src/cpp/client/channel_arguments.cc",
"src/cpp/client/client_context.cc",
"src/cpp/client/create_channel.cc",
+ "src/cpp/client/create_channel_internal.cc",
+ "src/cpp/client/create_channel_internal.h",
"src/cpp/client/credentials.cc",
"src/cpp/client/generic_stub.cc",
"src/cpp/client/insecure_credentials.cc",
- "src/cpp/client/internal_stub.cc",
"src/cpp/common/call.cc",
"src/cpp/common/completion_queue.cc",
"src/cpp/common/create_auth_context.h",
diff --git a/vsprojects/grpc++/grpc++.vcxproj b/vsprojects/grpc++/grpc++.vcxproj
index 929bc15..e2e17d4 100644
--- a/vsprojects/grpc++/grpc++.vcxproj
+++ b/vsprojects/grpc++/grpc++.vcxproj
@@ -217,8 +217,8 @@
<ClInclude Include="..\..\include\grpc++\async_unary_call.h" />
<ClInclude Include="..\..\include\grpc++\auth_context.h" />
<ClInclude Include="..\..\include\grpc++\byte_buffer.h" />
+ <ClInclude Include="..\..\include\grpc++\channel.h" />
<ClInclude Include="..\..\include\grpc++\channel_arguments.h" />
- <ClInclude Include="..\..\include\grpc++\channel_interface.h" />
<ClInclude Include="..\..\include\grpc++\client_context.h" />
<ClInclude Include="..\..\include\grpc++\completion_queue.h" />
<ClInclude Include="..\..\include\grpc++\config.h" />
@@ -231,7 +231,6 @@
<ClInclude Include="..\..\include\grpc++\impl\call.h" />
<ClInclude Include="..\..\include\grpc++\impl\client_unary_call.h" />
<ClInclude Include="..\..\include\grpc++\impl\grpc_library.h" />
- <ClInclude Include="..\..\include\grpc++\impl\internal_stub.h" />
<ClInclude Include="..\..\include\grpc++\impl\proto_utils.h" />
<ClInclude Include="..\..\include\grpc++\impl\rpc_method.h" />
<ClInclude Include="..\..\include\grpc++\impl\rpc_service_method.h" />
@@ -259,7 +258,7 @@
<ClInclude Include="..\..\src\cpp\client\secure_credentials.h" />
<ClInclude Include="..\..\src\cpp\common\secure_auth_context.h" />
<ClInclude Include="..\..\src\cpp\server\secure_server_credentials.h" />
- <ClInclude Include="..\..\src\cpp\client\channel.h" />
+ <ClInclude Include="..\..\src\cpp\client\create_channel_internal.h" />
<ClInclude Include="..\..\src\cpp\common\create_auth_context.h" />
</ItemGroup>
<ItemGroup>
@@ -283,14 +282,14 @@
</ClCompile>
<ClCompile Include="..\..\src\cpp\client\create_channel.cc">
</ClCompile>
+ <ClCompile Include="..\..\src\cpp\client\create_channel_internal.cc">
+ </ClCompile>
<ClCompile Include="..\..\src\cpp\client\credentials.cc">
</ClCompile>
<ClCompile Include="..\..\src\cpp\client\generic_stub.cc">
</ClCompile>
<ClCompile Include="..\..\src\cpp\client\insecure_credentials.cc">
</ClCompile>
- <ClCompile Include="..\..\src\cpp\client\internal_stub.cc">
- </ClCompile>
<ClCompile Include="..\..\src\cpp\common\call.cc">
</ClCompile>
<ClCompile Include="..\..\src\cpp\common\completion_queue.cc">
diff --git a/vsprojects/grpc++/grpc++.vcxproj.filters b/vsprojects/grpc++/grpc++.vcxproj.filters
index 0408fb4..6f308d1 100644
--- a/vsprojects/grpc++/grpc++.vcxproj.filters
+++ b/vsprojects/grpc++/grpc++.vcxproj.filters
@@ -31,6 +31,9 @@
<ClCompile Include="..\..\src\cpp\client\create_channel.cc">
<Filter>src\cpp\client</Filter>
</ClCompile>
+ <ClCompile Include="..\..\src\cpp\client\create_channel_internal.cc">
+ <Filter>src\cpp\client</Filter>
+ </ClCompile>
<ClCompile Include="..\..\src\cpp\client\credentials.cc">
<Filter>src\cpp\client</Filter>
</ClCompile>
@@ -40,9 +43,6 @@
<ClCompile Include="..\..\src\cpp\client\insecure_credentials.cc">
<Filter>src\cpp\client</Filter>
</ClCompile>
- <ClCompile Include="..\..\src\cpp\client\internal_stub.cc">
- <Filter>src\cpp\client</Filter>
- </ClCompile>
<ClCompile Include="..\..\src\cpp\common\call.cc">
<Filter>src\cpp\common</Filter>
</ClCompile>
@@ -108,10 +108,10 @@
<ClInclude Include="..\..\include\grpc++\byte_buffer.h">
<Filter>include\grpc++</Filter>
</ClInclude>
- <ClInclude Include="..\..\include\grpc++\channel_arguments.h">
+ <ClInclude Include="..\..\include\grpc++\channel.h">
<Filter>include\grpc++</Filter>
</ClInclude>
- <ClInclude Include="..\..\include\grpc++\channel_interface.h">
+ <ClInclude Include="..\..\include\grpc++\channel_arguments.h">
<Filter>include\grpc++</Filter>
</ClInclude>
<ClInclude Include="..\..\include\grpc++\client_context.h">
@@ -150,9 +150,6 @@
<ClInclude Include="..\..\include\grpc++\impl\grpc_library.h">
<Filter>include\grpc++\impl</Filter>
</ClInclude>
- <ClInclude Include="..\..\include\grpc++\impl\internal_stub.h">
- <Filter>include\grpc++\impl</Filter>
- </ClInclude>
<ClInclude Include="..\..\include\grpc++\impl\proto_utils.h">
<Filter>include\grpc++\impl</Filter>
</ClInclude>
@@ -230,7 +227,7 @@
<ClInclude Include="..\..\src\cpp\server\secure_server_credentials.h">
<Filter>src\cpp\server</Filter>
</ClInclude>
- <ClInclude Include="..\..\src\cpp\client\channel.h">
+ <ClInclude Include="..\..\src\cpp\client\create_channel_internal.h">
<Filter>src\cpp\client</Filter>
</ClInclude>
<ClInclude Include="..\..\src\cpp\common\create_auth_context.h">
diff --git a/vsprojects/grpc++_unsecure/grpc++_unsecure.vcxproj b/vsprojects/grpc++_unsecure/grpc++_unsecure.vcxproj
index 2ff252e..4be468c 100644
--- a/vsprojects/grpc++_unsecure/grpc++_unsecure.vcxproj
+++ b/vsprojects/grpc++_unsecure/grpc++_unsecure.vcxproj
@@ -217,8 +217,8 @@
<ClInclude Include="..\..\include\grpc++\async_unary_call.h" />
<ClInclude Include="..\..\include\grpc++\auth_context.h" />
<ClInclude Include="..\..\include\grpc++\byte_buffer.h" />
+ <ClInclude Include="..\..\include\grpc++\channel.h" />
<ClInclude Include="..\..\include\grpc++\channel_arguments.h" />
- <ClInclude Include="..\..\include\grpc++\channel_interface.h" />
<ClInclude Include="..\..\include\grpc++\client_context.h" />
<ClInclude Include="..\..\include\grpc++\completion_queue.h" />
<ClInclude Include="..\..\include\grpc++\config.h" />
@@ -231,7 +231,6 @@
<ClInclude Include="..\..\include\grpc++\impl\call.h" />
<ClInclude Include="..\..\include\grpc++\impl\client_unary_call.h" />
<ClInclude Include="..\..\include\grpc++\impl\grpc_library.h" />
- <ClInclude Include="..\..\include\grpc++\impl\internal_stub.h" />
<ClInclude Include="..\..\include\grpc++\impl\proto_utils.h" />
<ClInclude Include="..\..\include\grpc++\impl\rpc_method.h" />
<ClInclude Include="..\..\include\grpc++\impl\rpc_service_method.h" />
@@ -256,7 +255,7 @@
<ClInclude Include="..\..\include\grpc++\time.h" />
</ItemGroup>
<ItemGroup>
- <ClInclude Include="..\..\src\cpp\client\channel.h" />
+ <ClInclude Include="..\..\src\cpp\client\create_channel_internal.h" />
<ClInclude Include="..\..\src\cpp\common\create_auth_context.h" />
</ItemGroup>
<ItemGroup>
@@ -270,14 +269,14 @@
</ClCompile>
<ClCompile Include="..\..\src\cpp\client\create_channel.cc">
</ClCompile>
+ <ClCompile Include="..\..\src\cpp\client\create_channel_internal.cc">
+ </ClCompile>
<ClCompile Include="..\..\src\cpp\client\credentials.cc">
</ClCompile>
<ClCompile Include="..\..\src\cpp\client\generic_stub.cc">
</ClCompile>
<ClCompile Include="..\..\src\cpp\client\insecure_credentials.cc">
</ClCompile>
- <ClCompile Include="..\..\src\cpp\client\internal_stub.cc">
- </ClCompile>
<ClCompile Include="..\..\src\cpp\common\call.cc">
</ClCompile>
<ClCompile Include="..\..\src\cpp\common\completion_queue.cc">
diff --git a/vsprojects/grpc++_unsecure/grpc++_unsecure.vcxproj.filters b/vsprojects/grpc++_unsecure/grpc++_unsecure.vcxproj.filters
index b4fae77..bd51d1f 100644
--- a/vsprojects/grpc++_unsecure/grpc++_unsecure.vcxproj.filters
+++ b/vsprojects/grpc++_unsecure/grpc++_unsecure.vcxproj.filters
@@ -16,6 +16,9 @@
<ClCompile Include="..\..\src\cpp\client\create_channel.cc">
<Filter>src\cpp\client</Filter>
</ClCompile>
+ <ClCompile Include="..\..\src\cpp\client\create_channel_internal.cc">
+ <Filter>src\cpp\client</Filter>
+ </ClCompile>
<ClCompile Include="..\..\src\cpp\client\credentials.cc">
<Filter>src\cpp\client</Filter>
</ClCompile>
@@ -25,9 +28,6 @@
<ClCompile Include="..\..\src\cpp\client\insecure_credentials.cc">
<Filter>src\cpp\client</Filter>
</ClCompile>
- <ClCompile Include="..\..\src\cpp\client\internal_stub.cc">
- <Filter>src\cpp\client</Filter>
- </ClCompile>
<ClCompile Include="..\..\src\cpp\common\call.cc">
<Filter>src\cpp\common</Filter>
</ClCompile>
@@ -93,10 +93,10 @@
<ClInclude Include="..\..\include\grpc++\byte_buffer.h">
<Filter>include\grpc++</Filter>
</ClInclude>
- <ClInclude Include="..\..\include\grpc++\channel_arguments.h">
+ <ClInclude Include="..\..\include\grpc++\channel.h">
<Filter>include\grpc++</Filter>
</ClInclude>
- <ClInclude Include="..\..\include\grpc++\channel_interface.h">
+ <ClInclude Include="..\..\include\grpc++\channel_arguments.h">
<Filter>include\grpc++</Filter>
</ClInclude>
<ClInclude Include="..\..\include\grpc++\client_context.h">
@@ -135,9 +135,6 @@
<ClInclude Include="..\..\include\grpc++\impl\grpc_library.h">
<Filter>include\grpc++\impl</Filter>
</ClInclude>
- <ClInclude Include="..\..\include\grpc++\impl\internal_stub.h">
- <Filter>include\grpc++\impl</Filter>
- </ClInclude>
<ClInclude Include="..\..\include\grpc++\impl\proto_utils.h">
<Filter>include\grpc++\impl</Filter>
</ClInclude>
@@ -206,7 +203,7 @@
</ClInclude>
</ItemGroup>
<ItemGroup>
- <ClInclude Include="..\..\src\cpp\client\channel.h">
+ <ClInclude Include="..\..\src\cpp\client\create_channel_internal.h">
<Filter>src\cpp\client</Filter>
</ClInclude>
<ClInclude Include="..\..\src\cpp\common\create_auth_context.h">