Class GrpcChannelProvider
Namespace: ArmoniK.Api.Common.Channel.Utils
Assembly: ArmoniK.Api.Common.Channel.dll
Provides a built gRPC Channel from given options
[UsedImplicitly]
public sealed class GrpcChannelProvider : IAsyncDisposable
Inheritance
Implements
Inherited Members
object.Equals(object?), object.Equals(object?, object?), object.GetHashCode(), object.GetType(), object.ReferenceEquals(object?, object?), object.ToString()
Constructors
GrpcChannelProvider(GrpcChannel, ILogger<GrpcChannelProvider>)
Instantiate a
public GrpcChannelProvider(GrpcChannel options, ILogger<GrpcChannelProvider> logger)
Parameters
options GrpcChannel
Options to configure the creation of the gRPC channel
logger ILogger<GrpcChannelProvider>
Logger that will produce logs
Exceptions
when address is empty
Methods
DisposeAsync()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources asynchronously.
public ValueTask DisposeAsync()
Returns
A task that represents the asynchronous dispose operation.
Get()
Access to the created gRPC Channel
public ChannelBase Get()
Returns
The created gRPC Channel
Exceptions
when socket type is unknown