ReplicatorSettings.LoadFrom Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Loads the ReplicatorSettings object from the service configuration settings file.
public static System.Fabric.ReplicatorSettings LoadFrom (System.Fabric.CodePackageActivationContext codePackageActivationContext, string configPackageName, string sectionName);
static member LoadFrom : System.Fabric.CodePackageActivationContext * string * string -> System.Fabric.ReplicatorSettings
Public Shared Function LoadFrom (codePackageActivationContext As CodePackageActivationContext, configPackageName As String, sectionName As String) As ReplicatorSettings
Parameters
- codePackageActivationContext
- CodePackageActivationContext
The current code package activation context CodePackageActivationContext
- configPackageName
- String
The current configuration package name
- sectionName
- String
The section within the configuration file that defines all the replicator settings
Returns
The loaded ReplicatorSettings object from the service configuration settings file
Remarks
The configuration settings file (settings.xml) within the service configuration folder generally contains all the replicator settings that is needed to pass in the ReplicatorSettings object to the CreateReplicator(IStateProvider, ReplicatorSettings) method. Typically, the onus is on the service author to read the settings.xml file, parse the values and appropriately construct the ReplicatorSettings object.
With the current helper method, the service author can bypass the above process.
The following are the parameter names that should be provided in the service configuration “settings.xml”, to be recognizable by windows fabric to perform the above parsing automatically:
BatchAcknowledgementInterval –BatchAcknowledgementInterval value in seconds
InitialCopyQueueSize -InitialCopyQueueSize
MaxCopyQueueSize -MaxCopyQueueSize
MaxReplicationMessageSize -MaxReplicationMessageSize
RetryInterval -RetryInterval value in seconds
RequireServiceAck -RequireServiceAck
ReplicatorAddress or ReplicatorEndpoint – ReplicatorAddress should be of the form IPort. ReplicatorEndpoint must reference a valid service endpoint resource from the service manifest -ReplicatorAddress
ReplicatorListenAddress or ReplicatorEndpoint – ReplicatorListenAddress should be of the form IPort. ReplicatorEndpoint must reference a valid service endpoint resource from the service manifest -ReplicatorListenAddress
ReplicatorPublishAddress or ReplicatorEndpoint – ReplicatorPublishAddress should be of the form IPort. ReplicatorEndpoint must reference a valid service endpoint resource from the service manifest -ReplicatorPublishAddress
SecondaryClearAcknowledgedOperations -SecondaryClearAcknowledgedOperations
PrimaryWaitForPendingQuorumsTimeout - PrimaryWaitForPendingQuorumsTimeout value in seconds
UseStreamFaultsAndEndOfStreamOperationAck -UseStreamFaultsAndEndOfStreamOperationAck
InitialPrimaryReplicationQueueSize -InitialPrimaryReplicationQueueSize
InitialSecondaryReplicationQueueSize -InitialSecondaryReplicationQueueSize
MaxPrimaryReplicationQueueSize -MaxPrimaryReplicationQueueSize
MaxSecondaryReplicationQueueSize -MaxSecondaryReplicationQueueSize
MaxPrimaryReplicationQueueMemorySize -MaxPrimaryReplicationQueueMemorySize
MaxSecondaryReplicationQueueMemorySize -MaxSecondaryReplicationQueueMemorySize