Class GrpcOptions
- Namespace
- DMediatR
- Assembly
- DMediatR.dll
Optional gRPC configuration Facade aligning client and server configuration with single values.
public class GrpcOptions
- Inheritance
-
GrpcOptions
- Inherited Members
Fields
SectionName
public const string SectionName = "DMediatR:Grpc"
Field Value
Properties
EnableDetailedErrors
GrpcServiceOptions.EnableDetailedErrors and also whether to include exception details on the server in the RpcException. Defaults to false.
public bool EnableDetailedErrors { get; set; }
Property Value
MaxLatency
Duration the CorrelationGuid of a ICorrelatedNotification should stay in the cache. Required to prevent it from indefinitely growing. Afterwards, received duplicate copies of a notifications can no more be correlated and thus ignored. Defaults to 1 day, but can be adjusted to specific workloads here.
public TimeSpan? MaxLatency { get; set; }
Property Value
MaxMessageSize
Aligns GrpcServiceOptions.MaxReceiveMessageSize GrpcServiceOptions.MaxSendMessageSize GrpcChannelOptions.MaxReceiveMessageSize GrpcChannelOptions.MaxSendMessageSize
public int? MaxMessageSize { get; set; }
Property Value
- int?
MessagePackCompression
Proxy for static MessagePack.MessagePackCompression. Ensure that all clients and servers are configured for compression or omit it on all nodes to avoid a MessagePackSerializationException. Enum values: None|Lz4Block|Lz4BlockArray
public static MessagePackCompression? MessagePackCompression { get; set; }
Property Value
- MessagePackCompression?
OptionsMonitorEnabled
Automatic restarting of the Grpc server application on appsettings.json change can be disabled here. Defaults to true.
public bool OptionsMonitorEnabled { get; set; }
Property Value
RemotesSvg
Whether to expose a /remotes.svg and whether to respond to and forward a remote RemotesGraphRequest instance. Defaults to true.
public bool RemotesSvg { get; set; }
Property Value
ResponseCompressionAlgorithm
Header grpc-accept-encoding compression algorithm natively supported: gzip
public string? ResponseCompressionAlgorithm { get; set; }
Property Value
ResponseCompressionLevel
The compress level used to compress messages sent from the server.
public CompressionLevel? ResponseCompressionLevel { get; set; }
Property Value
ServerCertificateWatcherEnabled
Automatic restarting of the Grpc server application on server certificate change can be disabled here. Defaults to true.
public bool ServerCertificateWatcherEnabled { get; set; }