예제 #1
0
        public static void Main(string[] args)
        {
            Grpc.Core.Server server = new Grpc.Core.Server
            {
                Services = { Calculadora.BindService(new CalculadoraServer()) },
                Ports    = { new ServerPort("0.0.0.0", Port, ServerCredentials.Insecure) }
            };
            server.Start();

            Console.WriteLine("Greeter server listening on port " + Port);
            Thread.Sleep(Timeout.Infinite);
        }