Add gRPC standard headers to known headers (#24714)

This commit is contained in:
James Newton-King 2020-08-13 08:59:44 +12:00 committed by GitHub
parent ff4db3627f
commit ffeeb034f5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 2707 additions and 1899 deletions

View File

@ -44,6 +44,11 @@ namespace Microsoft.Net.Http.Headers
public static readonly string Expires = "Expires";
public static readonly string Expect = "Expect";
public static readonly string From = "From";
public static readonly string GrpcAcceptEncoding = "Grpc-Accept-Encoding";
public static readonly string GrpcEncoding = "Grpc-Encoding";
public static readonly string GrpcMessage = "Grpc-Message";
public static readonly string GrpcStatus = "Grpc-Status";
public static readonly string GrpcTimeout = "Grpc-Timeout";
public static readonly string Host = "Host";
public static readonly string KeepAlive = "Keep-Alive";
public static readonly string IfMatch = "If-Match";

View File

@ -42,6 +42,7 @@ namespace CodeGenerator
"Cache-Control",
"Connection",
"Date",
"Grpc-Encoding",
"Keep-Alive",
"Pragma",
"Trailer",
@ -89,6 +90,8 @@ namespace CodeGenerator
"Cookie",
"Expect",
"From",
"Grpc-Accept-Encoding",
"Grpc-Timeout",
"Host",
"If-Match",
"If-Modified-Since",
@ -185,6 +188,8 @@ namespace CodeGenerator
ResponseTrailers = new[]
{
"ETag",
"Grpc-Message",
"Grpc-Status"
}
.Select((header, index) => new KnownHeader
{