Show / Hide Table of Contents

Class PersistentState.Options

Represents configuration options of the persistent audit trail.

Inheritance
object
PersistentState.Options
MemoryBasedStateMachine.Options
Inherited Members
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: DotNext.Net.Cluster.Consensus.Raft
Assembly: DotNext.Net.Cluster.dll
Syntax
public class PersistentState.Options

Properties

| Edit this page View Source

BackupFormat

Gets or sets compression level used to create backup archive.

Declaration
public TarEntryFormat BackupFormat { get; set; }
Property Value
Type Description
TarEntryFormat
| Edit this page View Source

BufferSize

Gets or sets size of in-memory buffer for I/O operations.

Declaration
public int BufferSize { get; set; }
Property Value
Type Description
int
Exceptions
Type Condition
ArgumentOutOfRangeException

value is too small.

| Edit this page View Source

CopyOnReadOptions

If set then every read operations will be performed on buffered copy of the log entries.

Declaration
public LogEntriesBufferingOptions? CopyOnReadOptions { get; set; }
Property Value
Type Description
LogEntriesBufferingOptions
| Edit this page View Source

InitialPartitionSize

Gets or sets the initial size of the file that holds the partition with log entries, in bytes.

Declaration
public long InitialPartitionSize { get; set; }
Property Value
Type Description
long
Exceptions
Type Condition
ArgumentOutOfRangeException

value is less than zero.

| Edit this page View Source

IntegrityCheck

Enables or disables integrity check of the internal WAL state.

Declaration
public bool IntegrityCheck { get; set; }
Property Value
Type Description
bool
Remarks

The default value is false for backward compatibility.

| Edit this page View Source

MaxConcurrentReads

Gets or sets the number of possible parallel reads.

Declaration
public int MaxConcurrentReads { get; set; }
Property Value
Type Description
int
Exceptions
Type Condition
ArgumentOutOfRangeException

value is less than 2.

| Edit this page View Source

MaxLogEntrySize

Gets or sets maximum size of the log entry, in bytes.

Declaration
public long? MaxLogEntrySize { get; set; }
Property Value
Type Description
long?
Remarks

If enabled, WAL uses sparse files to optimize performance. CreateBackupAsync(Stream, CancellationToken) method supports backup of sparse files on Linux only. RestoreFromBackupAsync(Stream, DirectoryInfo, CancellationToken) method cannot restore the backup, you need to use tar utility to extract files.

| Edit this page View Source

MeasurementTags

Gets or sets a list of tags to be associated with each measurement.

Declaration
[CLSCompliant(false)]
public TagList MeasurementTags { get; set; }
Property Value
Type Description
TagList
| Edit this page View Source

ParallelIO

Gets or sets a value indicating that the underlying storage device can perform read/write operations simultaneously.

Declaration
public bool ParallelIO { get; set; }
Property Value
Type Description
bool
Remarks

This parameter makes no sense if UseCaching is true. If caching is disabled, set this property to true if the underlying storage is attached using parallel interface such as NVMe (via PCIe bus). The default value is false.

| Edit this page View Source

UseCaching

Enables or disables in-memory cache.

Declaration
public bool UseCaching { get; set; }
Property Value
Type Description
bool

true to in-memory cache for faster read/write of log entries; false to reduce the memory by the cost of the performance.

| Edit this page View Source

UseLegacyBinaryFormat

Gets or sets a value indicating that legacy binary format must be used.

Declaration
[Obsolete("Use default format instead.")]
public bool UseLegacyBinaryFormat { get; set; }
Property Value
Type Description
bool
| Edit this page View Source

WriteMode

Gets or sets a value indicating how the log interacts with underlying storage device.

Declaration
public PersistentState.WriteMode WriteMode { get; set; }
Property Value
Type Description
PersistentState.WriteMode

Methods

| Edit this page View Source

GetMemoryAllocator<T>()

Gets memory allocator for internal purposes.

Declaration
public virtual MemoryAllocator<T> GetMemoryAllocator<T>()
Returns
Type Description
MemoryAllocator<T>

The memory allocator.

Type Parameters
Name Description
T

The type of items in the pool.

Extension Methods

BasicExtensions.As<T>(T)
BasicExtensions.GetUserData<T>(T)
BasicExtensions.IsBetween<T, TLowerBound, TUpperBound>(T, TLowerBound, TUpperBound)
BasicExtensions.IsOneOf<T>(T, ReadOnlySpan<T>)
ExpressionBuilder.Const<T>(T)
AsyncLockAcquisition.AcquireLockAsync<T>(T, CancellationToken)
AsyncLockAcquisition.AcquireLockAsync<T>(T, TimeSpan, CancellationToken)
AsyncLockAcquisition.AcquireReadLockAsync<T>(T, CancellationToken)
AsyncLockAcquisition.AcquireReadLockAsync<T>(T, TimeSpan, CancellationToken)
AsyncLockAcquisition.AcquireWriteLockAsync<T>(T, bool, CancellationToken)
AsyncLockAcquisition.AcquireWriteLockAsync<T>(T, bool, TimeSpan, CancellationToken)
AsyncLockAcquisition.AcquireWriteLockAsync<T>(T, CancellationToken)
AsyncLockAcquisition.AcquireWriteLockAsync<T>(T, TimeSpan, CancellationToken)
LockAcquisition.AcquireReadLock<T>(T)
LockAcquisition.AcquireReadLock<T>(T, TimeSpan)
LockAcquisition.AcquireUpgradeableReadLock<T>(T)
LockAcquisition.AcquireUpgradeableReadLock<T>(T, TimeSpan)
LockAcquisition.AcquireWriteLock<T>(T)
LockAcquisition.AcquireWriteLock<T>(T, TimeSpan)
  • Edit this page
  • View Source
☀
☾
In this article
Back to top
Supported by the .NET Foundation
☀
☾