Share via


WcfServiceRemotingClientFactory.ICommunicationClientFactory<IServiceRemotingClient>.GetClientAsync Method

Definition

Overloads

ICommunicationClientFactory<IServiceRemotingClient>.GetClientAsync(ResolvedServicePartition, TargetReplicaSelector, String, OperationRetrySettings, CancellationToken)

Re-resolves a partition of the specified service containing one or more communication listeners and returns a client to communicate to the endpoint corresponding to the given listenerName.

The endpoint of the service is of the form - {"Endpoints":{"Listener1":"Endpoint1","Listener2":"Endpoint2" ...}}

ICommunicationClientFactory<IServiceRemotingClient>.GetClientAsync(Uri, ServicePartitionKey, TargetReplicaSelector, String, OperationRetrySettings, CancellationToken)

Resolves a partition of the specified service containing one or more communication listeners and returns a client to communicate to the endpoint corresponding to the given listenerName.

The endpoint of the service is of the form - {"Endpoints":{"Listener1":"Endpoint1","Listener2":"Endpoint2" ...}}

ICommunicationClientFactory<IServiceRemotingClient>.GetClientAsync(ResolvedServicePartition, TargetReplicaSelector, String, OperationRetrySettings, CancellationToken)

Re-resolves a partition of the specified service containing one or more communication listeners and returns a client to communicate to the endpoint corresponding to the given listenerName.

The endpoint of the service is of the form - {"Endpoints":{"Listener1":"Endpoint1","Listener2":"Endpoint2" ...}}

System.Threading.Tasks.Task<Microsoft.ServiceFabric.Services.Remoting.V1.Client.IServiceRemotingClient> ICommunicationClientFactory<IServiceRemotingClient>.GetClientAsync (System.Fabric.ResolvedServicePartition previousRsp, Microsoft.ServiceFabric.Services.Communication.Client.TargetReplicaSelector targetReplicaSelector, string listenerName, Microsoft.ServiceFabric.Services.Communication.Client.OperationRetrySettings retrySettings, System.Threading.CancellationToken cancellationToken);
abstract member Microsoft.ServiceFabric.Services.Communication.Client.ICommunicationClientFactory<Microsoft.ServiceFabric.Services.Remoting.V1.Client.IServiceRemotingClient>.GetClientAsync : System.Fabric.ResolvedServicePartition * Microsoft.ServiceFabric.Services.Communication.Client.TargetReplicaSelector * string * Microsoft.ServiceFabric.Services.Communication.Client.OperationRetrySettings * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.ServiceFabric.Services.Remoting.V1.Client.IServiceRemotingClient>
override this.Microsoft.ServiceFabric.Services.Communication.Client.ICommunicationClientFactory<Microsoft.ServiceFabric.Services.Remoting.V1.Client.IServiceRemotingClient>.GetClientAsync : System.Fabric.ResolvedServicePartition * Microsoft.ServiceFabric.Services.Communication.Client.TargetReplicaSelector * string * Microsoft.ServiceFabric.Services.Communication.Client.OperationRetrySettings * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.ServiceFabric.Services.Remoting.V1.Client.IServiceRemotingClient>
Function GetClientAsync (previousRsp As ResolvedServicePartition, targetReplicaSelector As TargetReplicaSelector, listenerName As String, retrySettings As OperationRetrySettings, cancellationToken As CancellationToken) As Task(Of IServiceRemotingClient) Implements ICommunicationClientFactory(Of IServiceRemotingClient).GetClientAsync

Parameters

previousRsp
ResolvedServicePartition

Previous ResolvedServicePartition value

targetReplicaSelector
TargetReplicaSelector

Specifies which replica in the partition identified by the partition key, the client should connect to

listenerName
String

Specifies which listener in the endpoint of the chosen replica, to which the client should connect to

retrySettings
OperationRetrySettings

Specifies the retry policy that should be used for exceptions that occur when creating the client.

cancellationToken
CancellationToken

Cancellation token

Returns

Task<Microsoft.ServiceFabric.Services.Remoting.V1.Client.IServiceRemotingClient>

A Task that represents outstanding operation. The result of the Task is the CommunicationClient(ICommunicationClient) object.

Implements

Applies to

ICommunicationClientFactory<IServiceRemotingClient>.GetClientAsync(Uri, ServicePartitionKey, TargetReplicaSelector, String, OperationRetrySettings, CancellationToken)

Resolves a partition of the specified service containing one or more communication listeners and returns a client to communicate to the endpoint corresponding to the given listenerName.

The endpoint of the service is of the form - {"Endpoints":{"Listener1":"Endpoint1","Listener2":"Endpoint2" ...}}

System.Threading.Tasks.Task<Microsoft.ServiceFabric.Services.Remoting.V1.Client.IServiceRemotingClient> ICommunicationClientFactory<IServiceRemotingClient>.GetClientAsync (Uri serviceUri, Microsoft.ServiceFabric.Services.Client.ServicePartitionKey partitionKey, Microsoft.ServiceFabric.Services.Communication.Client.TargetReplicaSelector targetReplicaSelector, string listenerName, Microsoft.ServiceFabric.Services.Communication.Client.OperationRetrySettings retrySettings, System.Threading.CancellationToken cancellationToken);
abstract member Microsoft.ServiceFabric.Services.Communication.Client.ICommunicationClientFactory<Microsoft.ServiceFabric.Services.Remoting.V1.Client.IServiceRemotingClient>.GetClientAsync : Uri * Microsoft.ServiceFabric.Services.Client.ServicePartitionKey * Microsoft.ServiceFabric.Services.Communication.Client.TargetReplicaSelector * string * Microsoft.ServiceFabric.Services.Communication.Client.OperationRetrySettings * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.ServiceFabric.Services.Remoting.V1.Client.IServiceRemotingClient>
override this.Microsoft.ServiceFabric.Services.Communication.Client.ICommunicationClientFactory<Microsoft.ServiceFabric.Services.Remoting.V1.Client.IServiceRemotingClient>.GetClientAsync : Uri * Microsoft.ServiceFabric.Services.Client.ServicePartitionKey * Microsoft.ServiceFabric.Services.Communication.Client.TargetReplicaSelector * string * Microsoft.ServiceFabric.Services.Communication.Client.OperationRetrySettings * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.ServiceFabric.Services.Remoting.V1.Client.IServiceRemotingClient>
Function GetClientAsync (serviceUri As Uri, partitionKey As ServicePartitionKey, targetReplicaSelector As TargetReplicaSelector, listenerName As String, retrySettings As OperationRetrySettings, cancellationToken As CancellationToken) As Task(Of IServiceRemotingClient) Implements ICommunicationClientFactory(Of IServiceRemotingClient).GetClientAsync

Parameters

serviceUri
Uri

Uri of the service to resolve

partitionKey
ServicePartitionKey

Key that identifies the partition to resolve

targetReplicaSelector
TargetReplicaSelector

Specifies which replica in the partition identified by the partition key, the client should connect to

listenerName
String

Specifies which listener in the endpoint of the chosen replica, to which the client should connect to

retrySettings
OperationRetrySettings

Specifies the retry policy that should be used for exceptions that occur when creating the client.

cancellationToken
CancellationToken

Cancellation token

Returns

Task<Microsoft.ServiceFabric.Services.Remoting.V1.Client.IServiceRemotingClient>

A Task that represents outstanding operation. The result of the Task is the CommunicationClient(ICommunicationClient) object.

Implements

Applies to