grpc/examples/csharp/helloworld-from-cli
Alexander Polcyn f5521c33f9 Revert "Merge branch 'master' into v1.3.x"
This reverts commit 79759fea1a, reversing
changes made to dc36f4df6a.
2017-04-26 14:18:39 -07:00
..
Greeter Revert "Merge branch 'master' into v1.3.x" 2017-04-26 14:18:39 -07:00
GreeterClient Revert "Merge branch 'master' into v1.3.x" 2017-04-26 14:18:39 -07:00
GreeterServer Revert "Merge branch 'master' into v1.3.x" 2017-04-26 14:18:39 -07:00
README.md Revert "Merge branch 'master' into v1.3.x" 2017-04-26 14:18:39 -07:00
global.json Revert "Merge branch 'master' into v1.3.x" 2017-04-26 14:18:39 -07:00

README.md

gRPC in 3 minutes (C#)

BACKGROUND

This is a different version of the helloworld example, using the dotnet sdk tools to build and run.

For this sample, we've already generated the server and client stubs from helloworld.proto.

Example projects in this directory depend on the Grpc and Google.Protobuf NuGet packages which have been already added to the project for you.

The examples in this directory target .NET 4.5 framework, as .NET Core support is currently experimental.

PREREQUISITES

  • The DotNetCore SDK cli.

  • The .NET 4.5 framework.

Both are available to download at https://www.microsoft.com/net/download

BUILD

From the examples/csharp/helloworld-from-cli directory:

  • dotnet restore

  • dotnet build **/project.json (this will automatically download NuGet dependencies)

Try it!

  • Run the server

    > cd GreeterServer
    > dotnet run
    
  • Run the client

    > cd GreeterClient
    > dotnet run
    

Tutorial

You can find a more detailed tutorial about Grpc in gRPC Basics: C#