ReplicatorSettings Class

  • java.lang.Object
    • system.fabric.ReplicatorSettings

public class ReplicatorSettings

Constructor Summary

Constructor Description
ReplicatorSettings()

Method Summary

Modifier and Type Method and Description
Duration getBatchAcknowledgementInterval()

Gets the amount of time that the replicator waits after receiving an operation before sending back an acknowledgment.

Remarks:Other operations received and acknowledged during this time period will have their acknowledgments sent back in a single message. Increasing the system.fabric.ReplicatorSettings#batchAcknowledgementInterval value decreases latency of individual replication operations but increases throughput of the replicator. Default value is 0.05 Seconds (50 milliseconds)

long getInitialCopyQueueSize()

Gets the initial size of the copy operation queue inside FabricReplicator, which contains copy Operations not yet pumped and processed by the service.

Remarks:The default value is 64. Note that values for this parameter must be a power of 2.

long getInitialPrimaryReplicationQueueSize()

Defines the initial size of the primary replication operation queue inside FabricReplicator, which contains replication Operations.The unit here is the number of operations in the queue.

Remarks:This setting is specific to the Replicator when the role of the service is Primary The default value is 64. Note that values for this parameter must be a power of 2.

long getInitialReplicationQueueSize()

Gets the initial size of the replication queue size.

long getInitialSecondaryReplicationQueueSize()

Defines the initial size of the secondary replication operation queue inside FabricReplicator, which contains replication Operations

Remarks:This setting is specific to the Replicator when the role of the service is Secondary/Idle The default value is 64. Note that values for this parameter must be a power of 2.

long getMaxCopyQueueSize()

Gets the maximum size of the copy operation queue inside FabricReplicator, which contains copy Operations not yet pumped and processed by the service.

Remarks:If this queue size is reached at the secondary, operations will be buffered in the Primary’s copy queue. If that queue also fills, then the Primary will begin seeing system.fabric.FabricErrorCode#ReplicationQueueFull exceptions. The default value is 1024

long getMaxPrimaryReplicationQueueMemorySize()

Defines the maximum size of the primary replication operation queue inside FabricReplicator, which contains replication Operations

Remarks:This setting is specific to the Replicator when the role of the service is Primary. The default value is 0. This implies there is no memory limit

long getMaxPrimaryReplicationQueueSize()

Defines the maximum size of the primary replication operation queue inside FabricReplicator, which contains replication Operations

Remarks:If this queue size is reached, then the Primary will begin seeing system.fabric.FabricErrorCode#ReplicationQueueFull exceptions. The default value is 1024 Note that values for this parameter must be a power of 2. This setting is specific to the Replicator when the role of the service is Primary

Long getMaxReplicationMessageSize()

Gets the maximum size of a message that can be transmitted via the replicator. These include replication messages, copy messages and copy context messages. The unit of representation is bytes.

Remarks:The default value is 50MB

long getMaxReplicationQueueMemorySize()

Gets the maximum size for the replication queue memory.

Remarks:The default value is 0. This implies there is no memory limit

long getMaxReplicationQueueSize()

Gets the maximum size for the replication queue.

long getMaxSecondaryReplicationQueueMemorySize()

Defines the maximum size of the secondary replication operation queue inside FabricReplicator, which contains replication Operations.

Remarks:This setting is specific to the Replicator when the role of the service is Secondary/Idle. The default value is 0. This implies there is no memory limit

long getMaxSecondaryReplicationQueueSize()

Defines the maximum size of the secondary replication operation queue inside FabricReplicator, which contains replication Operations

Remarks:If this queue size is reached, operations will be buffered in the Primary’s replication queue. If that queue also fills, then the Primary will begin seeing system.fabric.FabricErrorCode#ReplicationQueueFull exceptions. The default value is 2048.Note that values for this parameter must be a power of 2. This setting is specific to the Replicator when the role of the service is Secondary/Idle

Duration getPrimaryWaitForPendingQuorumsTimeout()

Defines how long the primary replicator waits for receiving a quorum of acknowledgments for any pending replication operations before processing a reconfiguration request, that could potentially result in ‘cancelling’ the pending replication operations.

Remarks:The default value is 0. This implies that reconfigurations aren’t waited upon for receiving quorum on the pending replication operations. This helps in completing reconfigurations sooner. Note that larger values for this parameter could potentially result in slower reconfigurations, implying longer durations to fail-over a primary.

String getReplicatorAddress()

Configures the address that this replicator will use when communicating with other Replicators.

Remarks:String is formatted as "hostname:port", where hostname can be FQDN or IP address. The default value is localhost:0

Duration getRetryInterval()

Defines how long the FabricReplicator waits after it transmits a message from the primary to the secondary for the secondary to acknowledge that it has received the message.

Remarks:Receiving a message does not necessarily that the message has been processed. If this timer is exceeded, then the message is retransmitted. The default value is 5 seconds.

SecurityCredentials getSecurityCredentials()

Allows the service to define security credentials for securing the traffic between replicators.

boolean isRequireServiceAck()

Prevents the optimistic acknowledgment of operations in non-persistent services by requiring that the service calls acknowledge() before it pumps the next operation.

Remarks:Non-persistent services which require explicit acknowledgment can set this property to True in order to prevent optimistic acknowledgment of the operations by the Replicator. This setting has no effect for persistent services. The default value is false.

boolean isSecondaryClearAcknowledgedOperations()

Typically, operations in the secondary replicator are kept in the queue to be able to catchup replicas if it is promoted to a primary. With this flag enabled, the secondary replicator releases the operation as soon as it is acknowledged by the user service.

Remarks:The default value is false

boolean isUseStreamFaultsAndEndOfStreamOperationAck()

Specifies whether the replicator uses stream faults.

Remarks:The default value is false

ReplicatorSettings loadFrom(FabricCodePackageActivationContext codePackageActivationContext, String configPackageName, String sectionName)
void setBatchAcknowledgementInterval(Duration batchAcknowledgementInterval)

Sets the amount of time that the replicator waits after receiving an operation before sending back an acknowledgment.

Remarks:Other operations received and acknowledged during this time period will have their acknowledgments sent back in a single message. Increasing the system.fabric.ReplicatorSettings#batchAcknowledgementInterval value decreases latency of individual replication operations but increases throughput of the replicator. Default value is 0.05 Seconds (50 milliseconds)

void setInitialCopyQueueSize(long initialCopyQueueSize)

Gets or sets the initial size of the copy operation queue inside FabricReplicator, which contains copy Operations not yet pumped and processed by the service.

Remarks:The default value is 64. Note that values for this parameter must be a power of 2.

void setInitialPrimaryReplicationQueueSize(long initialPrimaryReplicationQueueSize)

Defines the initial size of the primary replication operation queue inside FabricReplicator, which contains replication Operations.The unit here is the number of operations in the queue.

Remarks:This setting is specific to the Replicator when the role of the service is Primary The default value is 64. Note that values for this parameter must be a power of 2.

void setInitialReplicationQueueSize(long initialReplicationQueueSize)

Sets the initial size of the replication queue size.

void setInitialSecondaryReplicationQueueSize(long initialSecondaryReplicationQueueSize)

Defines the initial size of the secondary replication operation queue inside FabricReplicator, which contains replication Operations

Remarks:This setting is specific to the Replicator when the role of the service is Secondary/Idle The default value is 64. Note that values for this parameter must be a power of 2.

void setMaxCopyQueueSize(long maxCopyQueueSize)

Sets the maximum size of the copy operation queue inside FabricReplicator, which contains copy Operations not yet pumped and processed by the service.

Remarks:If this queue size is reached at the secondary, operations will be buffered in the Primary’s copy queue. If that queue also fills, then the Primary will begin seeing system.fabric.FabricErrorCode#ReplicationQueueFull exceptions. The default value is 1024

void setMaxPrimaryReplicationQueueMemorySize(long maxPrimaryReplicationQueueMemorySize)

Defines the maximum size of the primary replication operation queue inside FabricReplicator, which contains replication Operations

Remarks:This setting is specific to the Replicator when the role of the service is Primary. The default value is 0. This implies there is no memory limit

void setMaxPrimaryReplicationQueueSize(long maxPrimaryReplicationQueueSize)

Defines the maximum size of the primary replication operation queue inside FabricReplicator, which contains replication Operations

Remarks:If this queue size is reached, then the Primary will begin seeing system.fabric.FabricErrorCode#ReplicationQueueFull exceptions. The default value is 1024 Note that values for this parameter must be a power of 2. This setting is specific to the Replicator when the role of the service is Primary

void setMaxReplicationMessageSize(long maxReplicationMessageSize)

Sets the maximum size of a message that can be transmitted via the replicator. These include replication messages, copy messages and copy context messages. The unit of representation is bytes.

Remarks:The default value is 50MB

void setMaxReplicationQueueMemorySize(long maxReplicationQueueMemorySize)

Sets the maximum size for the replication queue memory.

Remarks:The default value is 0. This implies there is no memory limit

void setMaxReplicationQueueSize(long maxReplicationQueueSize)

Sets the maximum size for the replication queue.

void setMaxSecondaryReplicationQueueMemorySize(long maxSecondaryReplicationQueueMemorySize)

Defines the maximum size of the secondary replication operation queue inside FabricReplicator, which contains replication Operations.

Remarks:This setting is specific to the Replicator when the role of the service is Secondary/Idle. The default value is 0. This implies there is no memory limit

void setMaxSecondaryReplicationQueueSize(long maxSecondaryReplicationQueueSize)

Defines the maximum size of the secondary replication operation queue inside FabricReplicator, which contains replication Operations

Remarks:If this queue size is reached, operations will be buffered in the Primary’s replication queue. If that queue also fills, then the Primary will begin seeing system.fabric.FabricErrorCode#ReplicationQueueFull exceptions. The default value is 2048.Note that values for this parameter must be a power of 2. This setting is specific to the Replicator when the role of the service is Secondary/Idle

void setPrimaryWaitForPendingQuorumsTimeout(Duration primaryWaitForPendingQuorumsTimeout)

Defines how long the primary replicator waits for receiving a quorum of acknowledgments for any pending replication operations before processing a reconfiguration request, that could potentially result in ‘cancelling’ the pending replication operations.

Remarks:The default value is 0. This implies that reconfigurations aren’t waited upon for receiving quorum on the pending replication operations. This helps in completing reconfigurations sooner. Note that larger values for this parameter could potentially result in slower reconfigurations, implying longer durations to fail-over a primary.

void setReplicatorAddress(String replicatorAddress)

Configures the address that this replicator will use when communicating with other Replicators.

Remarks:String is formatted as "hostname:port", where hostname can be FQDN or IP address. The default value is localhost:0

void setRequireServiceAck(boolean requireServiceAck)

Prevents the optimistic acknowledgment of operations in non-persistent services by requiring that the service calls acknowledge() before it pumps the next operation.

Remarks:Non-persistent services which require explicit acknowledgment can set this property to True in order to prevent optimistic acknowledgment of the operations by the Replicator. This setting has no effect for persistent services. The default value is false.

void setRetryInterval(Duration retryInterval)

Defines how long the FabricReplicator waits after it transmits a message from the primary to the secondary for the secondary to acknowledge that it has received the message.

Remarks:Receiving a message does not necessarily that the message has been processed. If this timer is exceeded, then the message is retransmitted. The default value is 5 seconds.

void setSecondaryClearAcknowledgedOperations(boolean secondaryClearAcknowledgedOperations)

Typically, operations in the secondary replicator are kept in the queue to be able to catchup replicas if it is promoted to a primary. With this flag enabled, the secondary replicator releases the operation as soon as it is acknowledged by the user service.

Remarks:The default value is false

void setSecurityCredentials(SecurityCredentials securityCredentials)

Allows the service to define security credentials for securing the traffic between replicators.

void setUseStreamFaultsAndEndOfStreamOperationAck(boolean useStreamFaultsAndEndOfStreamOperationAck)

Specifies whether the replicator uses stream faults.

Remarks:The default value is false

long toNative(PinCollection pinCollection)
String toString()

Constructor Details

ReplicatorSettings

public ReplicatorSettings()

Method Details

getBatchAcknowledgementInterval

public Duration getBatchAcknowledgementInterval()

Gets the amount of time that the replicator waits after receiving an operation before sending back an acknowledgment.

Remarks:Other operations received and acknowledged during this time period will have their acknowledgments sent back in a single message. Increasing the system.fabric.ReplicatorSettings#batchAcknowledgementInterval value decreases latency of individual replication operations but increases throughput of the replicator. Default value is 0.05 Seconds (50 milliseconds)

Returns:

The amount of time that the replicator waits after receiving an operation before sending back an acknowledgment.

getInitialCopyQueueSize

public long getInitialCopyQueueSize()

Gets the initial size of the copy operation queue inside FabricReplicator, which contains copy Operations not yet pumped and processed by the service.

Remarks:The default value is 64. Note that values for this parameter must be a power of 2.

Returns:

The initial size of the copy operation queue inside FabricReplicator, which contains copy Operations not yet pumped and processed by the service.

getInitialPrimaryReplicationQueueSize

public long getInitialPrimaryReplicationQueueSize()

Defines the initial size of the primary replication operation queue inside FabricReplicator, which contains replication Operations.The unit here is the number of operations in the queue.

Remarks:This setting is specific to the Replicator when the role of the service is Primary The default value is 64. Note that values for this parameter must be a power of 2.

Returns:

The initial size of the primary replication operation queue inside FabricReplicator

getInitialReplicationQueueSize

public long getInitialReplicationQueueSize()

Gets the initial size of the replication queue size.

Returns:

The initial size of the replication queue size.

getInitialSecondaryReplicationQueueSize

public long getInitialSecondaryReplicationQueueSize()

Defines the initial size of the secondary replication operation queue inside FabricReplicator, which contains replication Operations

Remarks:This setting is specific to the Replicator when the role of the service is Secondary/Idle The default value is 64. Note that values for this parameter must be a power of 2.

Returns:

The initial size of the secondary replication operation queue inside FabricReplicator, which contains replication Operations not yet pumped and processed by the service. The unit here is the number of operations in the queue

getMaxCopyQueueSize

public long getMaxCopyQueueSize()

Gets the maximum size of the copy operation queue inside FabricReplicator, which contains copy Operations not yet pumped and processed by the service.

Remarks:If this queue size is reached at the secondary, operations will be buffered in the Primary’s copy queue. If that queue also fills, then the Primary will begin seeing system.fabric.FabricErrorCode#ReplicationQueueFull exceptions. The default value is 1024

Returns:

The maximum size of the copy operation queue inside FabricReplicator, which contains copy Operations not yet pumped and processed by the service.

getMaxPrimaryReplicationQueueMemorySize

public long getMaxPrimaryReplicationQueueMemorySize()

Defines the maximum size of the primary replication operation queue inside FabricReplicator, which contains replication Operations

Remarks:This setting is specific to the Replicator when the role of the service is Primary. The default value is 0. This implies there is no memory limit

Returns:

. Returns the maximum size of the primary replication operation queue inside FabricReplicator, which contains replication Operations The unit here is the virtual memory consumption of the queue .Returns long.

getMaxPrimaryReplicationQueueSize

public long getMaxPrimaryReplicationQueueSize()

Defines the maximum size of the primary replication operation queue inside FabricReplicator, which contains replication Operations

Remarks:If this queue size is reached, then the Primary will begin seeing system.fabric.FabricErrorCode#ReplicationQueueFull exceptions. The default value is 1024 Note that values for this parameter must be a power of 2. This setting is specific to the Replicator when the role of the service is Primary

Returns:

The maximum size of the primary replication operation queue inside FabricReplicator, which contains replication Operations. The unit here is the number of operations in the queue.

getMaxReplicationMessageSize

public Long getMaxReplicationMessageSize()

Gets the maximum size of a message that can be transmitted via the replicator. These include replication messages, copy messages and copy context messages. The unit of representation is bytes.

Remarks:The default value is 50MB

Returns:

The maximum size of a message that can be transmitted via the replicator.

getMaxReplicationQueueMemorySize

public long getMaxReplicationQueueMemorySize()

Gets the maximum size for the replication queue memory.

Remarks:The default value is 0. This implies there is no memory limit

Returns:

The maximum size for the replication queue memory.

getMaxReplicationQueueSize

public long getMaxReplicationQueueSize()

Gets the maximum size for the replication queue.

Returns:

the maximum size for the replication queue.

getMaxSecondaryReplicationQueueMemorySize

public long getMaxSecondaryReplicationQueueMemorySize()

Defines the maximum size of the secondary replication operation queue inside FabricReplicator, which contains replication Operations.

Remarks:This setting is specific to the Replicator when the role of the service is Secondary/Idle. The default value is 0. This implies there is no memory limit

Returns:

Returns the maximum size of the secondary replication operation queue inside FabricReplicator, which contains replication Operations. The unit here is the virtual memory consumption of the queue.

getMaxSecondaryReplicationQueueSize

public long getMaxSecondaryReplicationQueueSize()

Defines the maximum size of the secondary replication operation queue inside FabricReplicator, which contains replication Operations

Remarks:If this queue size is reached, operations will be buffered in the Primary’s replication queue. If that queue also fills, then the Primary will begin seeing system.fabric.FabricErrorCode#ReplicationQueueFull exceptions. The default value is 2048.Note that values for this parameter must be a power of 2. This setting is specific to the Replicator when the role of the service is Secondary/Idle

Returns:

The maximum size of the secondary replication operation queue inside FabricReplicator, which contains replication Operations not yet pumped and processed by the service. The unit here is the number of operations in the queue

getPrimaryWaitForPendingQuorumsTimeout

public Duration getPrimaryWaitForPendingQuorumsTimeout()

Defines how long the primary replicator waits for receiving a quorum of acknowledgments for any pending replication operations before processing a reconfiguration request, that could potentially result in ‘cancelling’ the pending replication operations.

Remarks:The default value is 0. This implies that reconfigurations aren’t waited upon for receiving quorum on the pending replication operations. This helps in completing reconfigurations sooner. Note that larger values for this parameter could potentially result in slower reconfigurations, implying longer durations to fail-over a primary.

Returns:

Amount of time the primary replicator waits for receiving a quorum of acknowledgments for any pending replication operations when there is a request for the primary replicator to process a reconfiguration java.time.Duration.

getReplicatorAddress

public String getReplicatorAddress()

Configures the address that this replicator will use when communicating with other Replicators.

Remarks:String is formatted as "hostname:port", where hostname can be FQDN or IP address. The default value is localhost:0

Returns:

The address that this replicator will use when communicating with other Replicators.

getRetryInterval

public Duration getRetryInterval()

Defines how long the FabricReplicator waits after it transmits a message from the primary to the secondary for the secondary to acknowledge that it has received the message.

Remarks:Receiving a message does not necessarily that the message has been processed. If this timer is exceeded, then the message is retransmitted. The default value is 5 seconds.

Returns:

The time needed the FabricReplicator waits after it transmits a message from the primary to the secondary for the secondary to acknowledge that it has received the message.

getSecurityCredentials

public SecurityCredentials getSecurityCredentials()

Allows the service to define security credentials for securing the traffic between replicators.

Returns:

The service to define security credentials for securing the traffic between replicators.

isRequireServiceAck

public boolean isRequireServiceAck()

Prevents the optimistic acknowledgment of operations in non-persistent services by requiring that the service calls acknowledge() before it pumps the next operation.

Remarks:Non-persistent services which require explicit acknowledgment can set this property to True in order to prevent optimistic acknowledgment of the operations by the Replicator. This setting has no effect for persistent services. The default value is false.

Returns:

true if the optimistic acknowledgment of operations in non-persistent services;otherwise, false.

isSecondaryClearAcknowledgedOperations

public boolean isSecondaryClearAcknowledgedOperations()

Typically, operations in the secondary replicator are kept in the queue to be able to catchup replicas if it is promoted to a primary. With this flag enabled, the secondary replicator releases the operation as soon as it is acknowledged by the user service.

Remarks:The default value is false

Returns:

true if the secondary replicator releases the operation as soon as it is acknowledged by the user service; otherwise, false.

isUseStreamFaultsAndEndOfStreamOperationAck

public boolean isUseStreamFaultsAndEndOfStreamOperationAck()

Specifies whether the replicator uses stream faults.

Remarks:The default value is false

Returns:

true if the replicator uses stream faults; otherwise, false.

loadFrom

public static ReplicatorSettings loadFrom(FabricCodePackageActivationContext codePackageActivationContext, String configPackageName, String sectionName)

Parameters:

codePackageActivationContext
configPackageName
sectionName

setBatchAcknowledgementInterval

public void setBatchAcknowledgementInterval(Duration batchAcknowledgementInterval)

Sets the amount of time that the replicator waits after receiving an operation before sending back an acknowledgment.

Remarks:Other operations received and acknowledged during this time period will have their acknowledgments sent back in a single message. Increasing the system.fabric.ReplicatorSettings#batchAcknowledgementInterval value decreases latency of individual replication operations but increases throughput of the replicator. Default value is 0.05 Seconds (50 milliseconds)

Parameters:

batchAcknowledgementInterval - The amount of time that the replicator waits after receiving an operation before sending back an acknowledgment.

setInitialCopyQueueSize

public void setInitialCopyQueueSize(long initialCopyQueueSize)

Gets or sets the initial size of the copy operation queue inside FabricReplicator, which contains copy Operations not yet pumped and processed by the service.

Remarks:The default value is 64. Note that values for this parameter must be a power of 2.

Parameters:

initialCopyQueueSize - The initial size of the copy operation queue inside FabricReplicator, which contains copy Operations not yet pumped and processed by the service.

setInitialPrimaryReplicationQueueSize

public void setInitialPrimaryReplicationQueueSize(long initialPrimaryReplicationQueueSize)

Defines the initial size of the primary replication operation queue inside FabricReplicator, which contains replication Operations.The unit here is the number of operations in the queue.

Remarks:This setting is specific to the Replicator when the role of the service is Primary The default value is 64. Note that values for this parameter must be a power of 2.

Parameters:

initialPrimaryReplicationQueueSize - The initial size of the primary replication operation queue inside FabricReplicator

setInitialReplicationQueueSize

public void setInitialReplicationQueueSize(long initialReplicationQueueSize)

Sets the initial size of the replication queue size.

Parameters:

initialReplicationQueueSize - The initial size of the replication queue size.

setInitialSecondaryReplicationQueueSize

public void setInitialSecondaryReplicationQueueSize(long initialSecondaryReplicationQueueSize)

Defines the initial size of the secondary replication operation queue inside FabricReplicator, which contains replication Operations

Remarks:This setting is specific to the Replicator when the role of the service is Secondary/Idle The default value is 64. Note that values for this parameter must be a power of 2.

Parameters:

initialSecondaryReplicationQueueSize - The initial size of the secondary replication operation queue inside FabricReplicator, which contains replication Operations not yet pumped and processed by the service. The unit here is the number of operations in the queue

setMaxCopyQueueSize

public void setMaxCopyQueueSize(long maxCopyQueueSize)

Sets the maximum size of the copy operation queue inside FabricReplicator, which contains copy Operations not yet pumped and processed by the service.

Remarks:If this queue size is reached at the secondary, operations will be buffered in the Primary’s copy queue. If that queue also fills, then the Primary will begin seeing system.fabric.FabricErrorCode#ReplicationQueueFull exceptions. The default value is 1024

Parameters:

maxCopyQueueSize - The maximum size of the copy operation queue inside FabricReplicator, which contains copy Operations not yet pumped and processed by the service.

setMaxPrimaryReplicationQueueMemorySize

public void setMaxPrimaryReplicationQueueMemorySize(long maxPrimaryReplicationQueueMemorySize)

Defines the maximum size of the primary replication operation queue inside FabricReplicator, which contains replication Operations

Remarks:This setting is specific to the Replicator when the role of the service is Primary. The default value is 0. This implies there is no memory limit

Parameters:

maxPrimaryReplicationQueueMemorySize - the maximum size of the primary replication operation queue inside FabricReplicator, which contains replication Operations The unit here is the virtual memory consumption of the queue .Returns long.

setMaxPrimaryReplicationQueueSize

public void setMaxPrimaryReplicationQueueSize(long maxPrimaryReplicationQueueSize)

Defines the maximum size of the primary replication operation queue inside FabricReplicator, which contains replication Operations

Remarks:If this queue size is reached, then the Primary will begin seeing system.fabric.FabricErrorCode#ReplicationQueueFull exceptions. The default value is 1024 Note that values for this parameter must be a power of 2. This setting is specific to the Replicator when the role of the service is Primary

Parameters:

maxPrimaryReplicationQueueSize - The maximum size of the primary replication operation queue inside FabricReplicator, which contains replication Operations. The unit here is the number of operations in the queue.

setMaxReplicationMessageSize

public void setMaxReplicationMessageSize(long maxReplicationMessageSize)

Sets the maximum size of a message that can be transmitted via the replicator. These include replication messages, copy messages and copy context messages. The unit of representation is bytes.

Remarks:The default value is 50MB

Parameters:

maxReplicationMessageSize - The maximum size of a message that can be transmitted via the replicator.

setMaxReplicationQueueMemorySize

public void setMaxReplicationQueueMemorySize(long maxReplicationQueueMemorySize)

Sets the maximum size for the replication queue memory.

Remarks:The default value is 0. This implies there is no memory limit

Parameters:

maxReplicationQueueMemorySize - The maximum size for the replication queue memory.

setMaxReplicationQueueSize

public void setMaxReplicationQueueSize(long maxReplicationQueueSize)

Sets the maximum size for the replication queue.

Parameters:

maxReplicationQueueSize - the maximum size for the replication queue.

setMaxSecondaryReplicationQueueMemorySize

public void setMaxSecondaryReplicationQueueMemorySize(long maxSecondaryReplicationQueueMemorySize)

Defines the maximum size of the secondary replication operation queue inside FabricReplicator, which contains replication Operations.

Remarks:This setting is specific to the Replicator when the role of the service is Secondary/Idle. The default value is 0. This implies there is no memory limit

Parameters:

maxSecondaryReplicationQueueMemorySize - Returns the maximum size of the secondary replication operation queue inside FabricReplicator, which contains replication Operations. The unit here is the virtual memory consumption of the queue.

setMaxSecondaryReplicationQueueSize

public void setMaxSecondaryReplicationQueueSize(long maxSecondaryReplicationQueueSize)

Defines the maximum size of the secondary replication operation queue inside FabricReplicator, which contains replication Operations

Remarks:If this queue size is reached, operations will be buffered in the Primary’s replication queue. If that queue also fills, then the Primary will begin seeing system.fabric.FabricErrorCode#ReplicationQueueFull exceptions. The default value is 2048.Note that values for this parameter must be a power of 2. This setting is specific to the Replicator when the role of the service is Secondary/Idle

Parameters:

maxSecondaryReplicationQueueSize - The maximum size of the secondary replication operation queue inside FabricReplicator, which contains replication Operations not yet pumped and processed by the service. The unit here is the number of operations in the queue

setPrimaryWaitForPendingQuorumsTimeout

public void setPrimaryWaitForPendingQuorumsTimeout(Duration primaryWaitForPendingQuorumsTimeout)

Defines how long the primary replicator waits for receiving a quorum of acknowledgments for any pending replication operations before processing a reconfiguration request, that could potentially result in ‘cancelling’ the pending replication operations.

Remarks:The default value is 0. This implies that reconfigurations aren’t waited upon for receiving quorum on the pending replication operations. This helps in completing reconfigurations sooner. Note that larger values for this parameter could potentially result in slower reconfigurations, implying longer durations to fail-over a primary.

Parameters:

primaryWaitForPendingQuorumsTimeout - Amount of time the primary replicator waits for receiving a quorum of acknowledgments for any pending replication operations when there is a request for the primary replicator to process a reconfiguration java.time.Duration.

setReplicatorAddress

public void setReplicatorAddress(String replicatorAddress)

Configures the address that this replicator will use when communicating with other Replicators.

Remarks:String is formatted as "hostname:port", where hostname can be FQDN or IP address. The default value is localhost:0

Parameters:

replicatorAddress - The address that this replicator will use when communicating with other Replicators.

setRequireServiceAck

public void setRequireServiceAck(boolean requireServiceAck)

Prevents the optimistic acknowledgment of operations in non-persistent services by requiring that the service calls acknowledge() before it pumps the next operation.

Remarks:Non-persistent services which require explicit acknowledgment can set this property to True in order to prevent optimistic acknowledgment of the operations by the Replicator. This setting has no effect for persistent services. The default value is false.

Parameters:

requireServiceAck - true if the optimistic acknowledgment of operations in non-persistent services;otherwise, false.

setRetryInterval

public void setRetryInterval(Duration retryInterval)

Defines how long the FabricReplicator waits after it transmits a message from the primary to the secondary for the secondary to acknowledge that it has received the message.

Remarks:Receiving a message does not necessarily that the message has been processed. If this timer is exceeded, then the message is retransmitted. The default value is 5 seconds.

Parameters:

retryInterval - The time needed the FabricReplicator waits after it transmits a message from the primary to the secondary for the secondary to acknowledge that it has received the message.

setSecondaryClearAcknowledgedOperations

public void setSecondaryClearAcknowledgedOperations(boolean secondaryClearAcknowledgedOperations)

Typically, operations in the secondary replicator are kept in the queue to be able to catchup replicas if it is promoted to a primary. With this flag enabled, the secondary replicator releases the operation as soon as it is acknowledged by the user service.

Remarks:The default value is false

Parameters:

secondaryClearAcknowledgedOperations - true if the secondary replicator releases the operation as soon as it is acknowledged by the user service; otherwise, false.

setSecurityCredentials

public void setSecurityCredentials(SecurityCredentials securityCredentials)

Allows the service to define security credentials for securing the traffic between replicators.

Parameters:

securityCredentials - The service to define security credentials for securing the traffic between replicators.

setUseStreamFaultsAndEndOfStreamOperationAck

public void setUseStreamFaultsAndEndOfStreamOperationAck(boolean useStreamFaultsAndEndOfStreamOperationAck)

Specifies whether the replicator uses stream faults.

Remarks:The default value is false

Parameters:

useStreamFaultsAndEndOfStreamOperationAck - true if the replicator uses stream faults; otherwise, false.

toNative

public long toNative(PinCollection pinCollection)

Parameters:

pinCollection

toString

public String toString()

Applies to