George Barnett b143369c7b Update examples (#2163) 10 mēneši atpakaļ
..
Protos 07e38e9756 Migrate CI to use swiftlang / SwiftNIO common GitHub Actions. (#2105) 1 gadu atpakaļ
Sources b143369c7b Update examples (#2163) 10 mēneši atpakaļ
.gitignore cf29048827 Make examples standalone packages (#2067) 1 gadu atpakaļ
Package.swift b143369c7b Update examples (#2163) 10 mēneši atpakaļ
README.md cf29048827 Make examples standalone packages (#2067) 1 gadu atpakaļ

README.md

Hello World

This example demonstrates the canonical "Hello World" in gRPC.

Overview

A "hello-world" command line tool that uses generated stubs for the 'Greeter' service which allows you to start a server and to make requests against it.

The tool uses the SwiftNIO HTTP/2 transport.

Usage

Build and run the server using the CLI:

$ swift run hello-world serve
Greeter listening on [ipv4]127.0.0.1:31415

Use the CLI to send a request to the service:

$ swift run hello-world greet
Hello, stranger

Send the name of the greetee in the request by specifying a --name:

$ swift run hello-world greet --name "PanCakes 🐶"
Hello, PanCakes 🐶