Reader small image

You're reading from  Apps and Services with .NET 8 - Second Edition

Product typeBook
Published inDec 2023
Reading LevelIntermediate
PublisherPackt
ISBN-139781837637133
Edition2nd Edition
Languages
Tools
Right arrow
Author (1)
Mark J. Price
Mark J. Price
author image
Mark J. Price

Mark J. Price is a Microsoft Specialist: Programming in C# and Architecting Microsoft Azure Solutions, with over 20 years' experience. Since 1993, he has passed more than 80 Microsoft programming exams and specializes in preparing others to pass them. Between 2001 and 2003, Mark was employed to write official courseware for Microsoft in Redmond, USA. His team wrote the first training courses for C# while it was still an early alpha version. While with Microsoft, he taught "train-the-trainer" classes to get other MCTs up-to-speed on C# and .NET. Mark holds a Computer Science BSc. Hons. Degree.
Read more about Mark J. Price

Right arrow

Building a gRPC service and client

Let’s see an example service and client for sending and receiving simple messages.

Building a Hello World gRPC service

We will start by building the gRPC service using one of the project templates provided as standard:

  1. Use your preferred code editor to create a new project, as defined in the following list:
    • Project template: ASP.NET Core gRPC Service / grpc
    • Solution file and folder: Chapter13
    • Project file and folder: Northwind.Grpc.Service
    • Enable Docker: Cleared.
    • Do not use top-level statements: Cleared.
    • Enable native AOT publish: Selected.

    Good Practice: Make sure to select Enable native AOT publish. With .NET 8 and later, gRPC projects can be ahead-of-time (AOT) compiled for native platforms. This gives improved performance and a reduced start time, which is important for microservices that are frequently redeployed and spun up and down...

lock icon
The rest of the page is locked
Previous PageNext Page
You have been reading a chapter from
Apps and Services with .NET 8 - Second Edition
Published in: Dec 2023Publisher: PacktISBN-13: 9781837637133

Author (1)

author image
Mark J. Price

Mark J. Price is a Microsoft Specialist: Programming in C# and Architecting Microsoft Azure Solutions, with over 20 years' experience. Since 1993, he has passed more than 80 Microsoft programming exams and specializes in preparing others to pass them. Between 2001 and 2003, Mark was employed to write official courseware for Microsoft in Redmond, USA. His team wrote the first training courses for C# while it was still an early alpha version. While with Microsoft, he taught "train-the-trainer" classes to get other MCTs up-to-speed on C# and .NET. Mark holds a Computer Science BSc. Hons. Degree.
Read more about Mark J. Price