Lines Matching refs:server
7 - Generate server and client code.
8 - Write a simple client and server for your service.
22 updates with the server and other clients.
50 Run the server
52 $ cargo run --bin routeguide-server
68 If you scroll up you should see the output of the other 3 request types: simple rpc, server-side
108 - A *simple RPC* where the client sends a request to the server and waits for a response to come
115 - A *server-side streaming RPC* where the client sends a request to the server and gets a stream
117 no more messages. As you can see in our example, you specify a server-side streaming method by
128 the server. Once the client has finished writing the messages, it waits for the server to read them
139 order they like: for example, the server could wait to receive all the client messages before
164 ## Generating client and server code
208 - A client type we'll use to call the server: `route_guide_client::RouteGuideClient<T>`.
215 ## Creating the server
217 First let's look at how we create a `RouteGuide` server. If you're only interested in creating gRPC
224 - Running a gRPC server to listen for requests from clients.
226 You can find our example `RouteGuide` server in
227 [examples/src/routeguide/server.rs][routeguide-server].
229 [routeguide-server]: https://github.com/hyperium/tonic/blob/master/examples/src/routeguide/server.rs
231 ### Implementing the RouteGuide server trait argument
314 Our service needs access to an immutable list of features. When the server starts, we are going to
361 [examples/src/routeguide/server.rs][in-range-fn].
365 [in-range-fn]: https://github.com/hyperium/tonic/blob/master/examples/src/routeguide/server.rs#L174
394 Now let's look at one of our streaming RPCs. `list_features` is a server-side streaming RPC, so we
528 ### Starting the server argument
530 Once we've implemented all our methods, we also need to start up a gRPC server so that clients can
563 …n-example]: https://github.com/hyperium/tonic/blob/master/examples/src/authentication/server.rs#L56
571 Our crate will have two binary targets: `routeguide-client` and `routeguide-server`. We need to
576 name = "routeguide-server"
577 path = "src/server.rs"
584 Rename `main.rs` to `server.rs` and create a new file `client.rs`.
587 $ mv src/main.rs src/server.rs
591 …methods, we first need to create a gRPC *client* to communicate with the server. Like in the server
611 Same as in the server implementation, we start by bringing our generated code into scope. We then
612 create a client in our main function, passing the server's full URL to `RouteGuideClient::connect`.
644 Here's where we call the server-side streaming method `list_features`, which returns a stream of
682 server's responses to a response protocol buffer object (in this case a `Feature`) until there are
776 the server, printing each value in the stream.
780 ### Run the server
782 $ cargo run --bin routeguide-server
799 - When building a rust client or server (or both) as part of a larger, multi-language project.
824 On `cargo run`, this will generate code for the server only, and place the resulting file in