+ setSnapshotDataThreshold(DEFAULT_SHARD_SNAPSHOT_DATA_THRESHOLD);
+ setElectionTimeoutFactor(DEFAULT_SHARD_ELECTION_TIMEOUT_FACTOR);
+ setCandidateElectionTimeoutDivisor(DEFAULT_SHARD_CANDIDATE_ELECTION_TIMEOUT_DIVISOR);
+ setSyncIndexThreshold(DEFAULT_SYNC_INDEX_THRESHOLD);
+ setMaximumMessageSliceSize(DEFAULT_MAX_MESSAGE_SLICE_SIZE);
+ }
+
+ private DatastoreContext(final DatastoreContext other) {
+ shardTransactionIdleTimeout = other.shardTransactionIdleTimeout;
+ operationTimeoutInMillis = other.operationTimeoutInMillis;
+ dataStoreMXBeanType = other.dataStoreMXBeanType;
+ shardTransactionCommitTimeoutInSeconds = other.shardTransactionCommitTimeoutInSeconds;
+ shardTransactionCommitQueueCapacity = other.shardTransactionCommitQueueCapacity;
+ shardInitializationTimeout = other.shardInitializationTimeout;
+ shardLeaderElectionTimeout = other.shardLeaderElectionTimeout;
+ initialSettleTimeoutMultiplier = other.initialSettleTimeoutMultiplier;
+ persistent = other.persistent;
+ snapshotOnRootOverwrite = other.snapshotOnRootOverwrite;
+ configurationReader = other.configurationReader;
+ transactionCreationInitialRateLimit = other.transactionCreationInitialRateLimit;
+ dataStoreName = other.dataStoreName;
+ logicalStoreType = other.logicalStoreType;
+ storeRoot = other.storeRoot;
+ shardBatchedModificationCount = other.shardBatchedModificationCount;
+ writeOnlyTransactionOptimizationsEnabled = other.writeOnlyTransactionOptimizationsEnabled;
+ shardCommitQueueExpiryTimeoutInMillis = other.shardCommitQueueExpiryTimeoutInMillis;
+ transactionDebugContextEnabled = other.transactionDebugContextEnabled;
+ shardManagerPersistenceId = other.shardManagerPersistenceId;
+ useTellBasedProtocol = other.useTellBasedProtocol;
+ backendAlivenessTimerInterval = other.backendAlivenessTimerInterval;
+ requestTimeout = other.requestTimeout;
+ noProgressTimeout = other.noProgressTimeout;
+ initialPayloadSerializedBufferCapacity = other.initialPayloadSerializedBufferCapacity;
+ useLz4Compression = other.useLz4Compression;
+ exportOnRecovery = other.exportOnRecovery;
+ recoveryExportBaseDir = other.recoveryExportBaseDir;
+
+ setShardJournalRecoveryLogBatchSize(other.raftConfig.getJournalRecoveryLogBatchSize());
+ setSnapshotBatchCount(other.raftConfig.getSnapshotBatchCount());
+ setRecoverySnapshotIntervalSeconds(other.raftConfig.getRecoverySnapshotIntervalSeconds());
+ setHeartbeatInterval(other.raftConfig.getHeartBeatInterval().toMillis());
+ setIsolatedLeaderCheckInterval(other.raftConfig.getIsolatedCheckIntervalInMillis());
+ setSnapshotDataThresholdPercentage(other.raftConfig.getSnapshotDataThresholdPercentage());
+ setSnapshotDataThreshold(other.raftConfig.getSnapshotDataThreshold());
+ setElectionTimeoutFactor(other.raftConfig.getElectionTimeoutFactor());
+ setCandidateElectionTimeoutDivisor(other.raftConfig.getCandidateElectionTimeoutDivisor());
+ setCustomRaftPolicyImplementation(other.raftConfig.getCustomRaftPolicyImplementationClass());
+ setMaximumMessageSliceSize(other.getMaximumMessageSliceSize());
+ setShardSnapshotChunkSize(other.raftConfig.getSnapshotChunkSize());
+ setPeerAddressResolver(other.raftConfig.getPeerAddressResolver());
+ setTempFileDirectory(other.getTempFileDirectory());
+ setFileBackedStreamingThreshold(other.getFileBackedStreamingThreshold());
+ setSyncIndexThreshold(other.raftConfig.getSyncIndexThreshold());