修改设计系统
This commit is contained in:
parent
01bcaefa19
commit
6da7b00c92
@ -13,12 +13,16 @@ gRPC 使用 Protocol Buffers 作为接口定义语言(IDL),Protocol Buffer
|
||||
定义一个 gRPC 服务,需要创建一个 gRPC 服务定义文件(.proto 文件),然后使用 gRPC 工具生成服务端和客户端代码。
|
||||
|
||||
|
||||
## 带有OpenAPI 的 gRPC 服务
|
||||
## 带有 OpenAPI 的 gRPC 服务
|
||||
|
||||
```shell
|
||||
dotnet add package Microsoft.AspNetCore.Grpc.Swagger
|
||||
```
|
||||
|
||||
```xml
|
||||
<IncludeHttpRuleProtos>true</IncludeHttpRuleProtos>
|
||||
```
|
||||
|
||||
```csharp
|
||||
var builder = WebApplication.CreateBuilder(args);
|
||||
builder.Services.AddGrpc().AddJsonTranscoding();
|
||||
|
Loading…
Reference in New Issue
Block a user