Skip to content

Instantly share code, notes, and snippets.

@gistlyn
Created December 28, 2019 06:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gistlyn/f294665245ae9bad0a5f73ef54d9d36e to your computer and use it in GitHub Desktop.
Save gistlyn/f294665245ae9bad0a5f73ef54d9d36e to your computer and use it in GitHub Desktop.
Insecure VB.NET gRPC Generic ServiceClient TodoWorld Example
Imports System
Imports System.Collections.Generic
Imports System.Threading.Tasks
Imports System.Security.Cryptography.X509Certificates
Imports ServiceStack
Imports TodoWorld.ServiceModel
Module Program
Async Function Todo() As Task
ProtoBuf.Grpc.Client.GrpcClientFactory.AllowUnencryptedHttp2 = true
Dim client = new GrpcServiceClient("http://todoworld.servicestack.net:5054")
Dim response = Await client.GetAsync(New Hello With { .Name = "gRPC VB.NET" })
Console.WriteLine(response.Result)
End Function
Sub Main(args As String())
Task.WaitAll(Todo())
End Sub
End Module
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment