ServicePartitionClient<TCommunicationClient>(ICommunicationClientFactory<TCommunicationClient>, Uri, ServicePartitionKey, TargetReplicaSelector, String, OperationRetrySettings) Constructor

Definition

Instantiates a service partition client that uses the specified communication client factory to create a client to talk to the service endpoint identified by the service uri, partitionkey, replica and listener arguments.

public ServicePartitionClient (Microsoft.ServiceFabric.Services.Communication.Client.ICommunicationClientFactory<TCommunicationClient> communicationClientFactory, Uri serviceUri, Microsoft.ServiceFabric.Services.Client.ServicePartitionKey partitionKey = null, Microsoft.ServiceFabric.Services.Communication.Client.TargetReplicaSelector targetReplicaSelector = Microsoft.ServiceFabric.Services.Communication.Client.TargetReplicaSelector.PrimaryReplica, string listenerName = null, Microsoft.ServiceFabric.Services.Communication.Client.OperationRetrySettings retrySettings = null);
new Microsoft.ServiceFabric.Services.Communication.Client.ServicePartitionClient<'CommunicationClient (requires 'CommunicationClient :> Microsoft.ServiceFabric.Services.Communication.Client.ICommunicationClient)> : Microsoft.ServiceFabric.Services.Communication.Client.ICommunicationClientFactory<'CommunicationClient (requires 'CommunicationClient :> Microsoft.ServiceFabric.Services.Communication.Client.ICommunicationClient)> * Uri * Microsoft.ServiceFabric.Services.Client.ServicePartitionKey * Microsoft.ServiceFabric.Services.Communication.Client.TargetReplicaSelector * string * Microsoft.ServiceFabric.Services.Communication.Client.OperationRetrySettings -> Microsoft.ServiceFabric.Services.Communication.Client.ServicePartitionClient<'CommunicationClient (requires 'CommunicationClient :> Microsoft.ServiceFabric.Services.Communication.Client.ICommunicationClient)>

Parameters

communicationClientFactory
ICommunicationClientFactory<TCommunicationClient>

Communication client factory

serviceUri
Uri

Name of the service

partitionKey
ServicePartitionKey

The partition key used to identify the partition within the service.

targetReplicaSelector
TargetReplicaSelector

Target replica information

listenerName
String

Listener in the replica to which the client should connect to

retrySettings
OperationRetrySettings

Retry policy for exceptions seen during communication

Applies to