Skip to content

Instantly share code, notes, and snippets.

@gistlyn gistlyn/main.swift

Created Dec 29, 2019
What would you like to do?
Swift Google protoc insecure GrpcServicesClient TodoWorld Example
import Foundation
import GRPC
import NIO
import NIOSSL
do {
let configuration = ClientConnection.Configuration(
target: .hostAndPort("", 5054),
eventLoopGroup: MultiThreadedEventLoopGroup(numberOfThreads: 1)
let client = GrpcServicesServiceClient(connection: ClientConnection(configuration: configuration))
var request = Hello() = "gRPC Swift"
let response = try client.getHello(request).response.wait().result
} catch {
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.