Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(616)

Unified Diff: third_party/grpc/examples/cpp/README.md

Issue 1932353002: Initial checkin of gRPC to third_party/ Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/grpc/examples/README.md ('k') | third_party/grpc/examples/cpp/cpptutorial.md » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/grpc/examples/cpp/README.md
diff --git a/third_party/grpc/examples/cpp/README.md b/third_party/grpc/examples/cpp/README.md
new file mode 100644
index 0000000000000000000000000000000000000000..d93cbacf7b276c673f17595e62b64821c22b4236
--- /dev/null
+++ b/third_party/grpc/examples/cpp/README.md
@@ -0,0 +1,49 @@
+#gRPC in 3 minutes (C++)
+
+## Installation
+
+To install gRPC on your system, follow the instructions to build from source [here](../../INSTALL.md). This also installs the protocol buffer compiler `protoc` (if you don't have it already), and the C++ gRPC plugin for `protoc`.
+
+## Hello C++ gRPC!
+
+Here's how to build and run the C++ implementation of the [Hello World](../protos/helloworld.proto) example used in [Getting started](..).
+
+The example code for this and our other examples lives in the `examples`
+directory. Clone this repository to your local machine by running the
+following command:
+
+
+```sh
+$ git clone https://github.com/grpc/grpc.git
+```
+
+Change your current directory to examples/cpp/helloworld
+
+```sh
+$ cd examples/cpp/helloworld/
+```
+
+### Client and server implementations
+
+The client implementation is at [greeter_client.cc](helloworld/greeter_client.cc).
+
+The server implementation is at [greeter_server.cc](helloworld/greeter_server.cc).
+
+### Try it!
+Build client and server:
+```sh
+$ make
+```
+Run the server, which will listen on port 50051:
+```sh
+$ ./greeter_server
+```
+Run the client (in a different terminal):
+```sh
+$ ./greeter_client
+```
+If things go smoothly, you will see the "Greeter received: Hello world" in the client side output.
+
+## Tutorial
+
+You can find a more detailed tutorial in [gRPC Basics: C++](cpptutorial.md)
« no previous file with comments | « third_party/grpc/examples/README.md ('k') | third_party/grpc/examples/cpp/cpptutorial.md » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698