Class TableOptions
Provides config options for cache tables
Inheritance
System.Object
TableOptions
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Assembly: Azos.dll
Syntax
[Serializable]
public sealed class TableOptions : INamed
Constructors
TableOptions(IConfigSectionNode, Boolean)
Declaration
public TableOptions(IConfigSectionNode node, bool nameRequired = true)
Parameters
TableOptions(String)
Declaration
public TableOptions(string name)
Parameters
Type |
Name |
Description |
System.String |
name |
|
Fields
DEFAULT_MAX_AGE_SEC_DEFAULT
Declaration
public const int DEFAULT_MAX_AGE_SEC_DEFAULT = 900
Field Value
Type |
Description |
System.Int32 |
|
GROWTH_FACTOR_DEFAULT
Declaration
public const double GROWTH_FACTOR_DEFAULT = 2
Field Value
Type |
Description |
System.Double |
|
GROWTH_FACTOR_MAX
Declaration
public const double GROWTH_FACTOR_MAX = 4
Field Value
Type |
Description |
System.Double |
|
GROWTH_FACTOR_MIN
Declaration
public const double GROWTH_FACTOR_MIN = 1.2
Field Value
Type |
Description |
System.Double |
|
INITIAL_CAPACITY_DEFAULT
Declaration
public const long INITIAL_CAPACITY_DEFAULT = 4096L
Field Value
Type |
Description |
System.Int64 |
|
INITIAL_CAPACITY_MIN
Declaration
public const long INITIAL_CAPACITY_MIN = 1024L
Field Value
Type |
Description |
System.Int64 |
|
LOAD_FACTOR_HWM_DEFAULT
Declaration
public const double LOAD_FACTOR_HWM_DEFAULT = 0.7
Field Value
Type |
Description |
System.Double |
|
LOAD_FACTOR_HWM_MAX
Declaration
public const double LOAD_FACTOR_HWM_MAX = 0.95
Field Value
Type |
Description |
System.Double |
|
LOAD_FACTOR_HWM_MIN
Declaration
public const double LOAD_FACTOR_HWM_MIN = 0.45
Field Value
Type |
Description |
System.Double |
|
LOAD_FACTOR_LWM_DEFAULT
Declaration
public const double LOAD_FACTOR_LWM_DEFAULT = 0.5
Field Value
Type |
Description |
System.Double |
|
LOAD_FACTOR_LWM_MAX
Declaration
public const double LOAD_FACTOR_LWM_MAX = 0.7
Field Value
Type |
Description |
System.Double |
|
LOAD_FACTOR_LWM_MIN
Declaration
public const double LOAD_FACTOR_LWM_MIN = 0.1
Field Value
Type |
Description |
System.Double |
|
SHRINK_FACTOR_DEFAULT
Declaration
public const double SHRINK_FACTOR_DEFAULT = 0.75
Field Value
Type |
Description |
System.Double |
|
SHRINK_FACTOR_MAX
Declaration
public const double SHRINK_FACTOR_MAX = 0.9
Field Value
Type |
Description |
System.Double |
|
SHRINK_FACTOR_MIN
Declaration
public const double SHRINK_FACTOR_MIN = 0.5
Field Value
Type |
Description |
System.Double |
|
Properties
AsExternalParameter
Allows to get/set options as external parameters
Declaration
public object AsExternalParameter { get; set; }
Property Value
Type |
Description |
System.Object |
|
CollisionMode
Defines how table handles collisions.
Note: this property can only be supplied to table ctor, the changes are ignored after the table has created
Declaration
[Config(Default = CollisionMode.Speculative)]
public CollisionMode CollisionMode { get; set; }
Property Value
DefaultMaxAgeSec
Specifies default max age length which is applied to cache items if Put() does not specify particular max age
Declaration
[Config]
public int DefaultMaxAgeSec { get; set; }
Property Value
Type |
Description |
System.Int32 |
|
DetailedInstrumentation
True to include instrumentation details per table
Declaration
[Config]
public bool DetailedInstrumentation { get; set; }
Property Value
Type |
Description |
System.Boolean |
|
GrowthFactor
Defines the factor of growth - how much does a table grow when HWM is reached. The number has to be at least 1.2d
Declaration
[Config]
public double GrowthFactor { get; set; }
Property Value
Type |
Description |
System.Double |
|
InitialCapacity
How many elements an empty table should contain. The value is dependent on bucket count, so the actual table capacity is bucket-dependent
Declaration
[Config]
public long InitialCapacity { get; set; }
Property Value
Type |
Description |
System.Int64 |
|
LoadFactorHWM
Defines the load factor above which the growth is triggered
Declaration
[Config]
public double LoadFactorHWM { get; set; }
Property Value
Type |
Description |
System.Double |
|
LoadFactorLWM
Defines the load factor below which the shrinking is triggered
Declaration
[Config]
public double LoadFactorLWM { get; set; }
Property Value
Type |
Description |
System.Double |
|
MaximumCapacity
How many elements a table may have at maximum, the property is checked at growth.
Zero = no limit
Declaration
[Config]
public long MaximumCapacity { get; set; }
Property Value
Type |
Description |
System.Int64 |
|
MinimumCapacity
How many elements a table may have at minimum, the property is checked at shrinking.
Zero = no limit.
The value is dependent on bucket count, so the actual table capacity is bucket-dependent
Declaration
[Config]
public long MinimumCapacity { get; set; }
Property Value
Type |
Description |
System.Int64 |
|
Name
Declaration
public string Name { get; }
Property Value
Type |
Description |
System.String |
|
ShrinkFactor
Defines the factor of shrinking - how much does a table shrink when LWM is reached. The number has to be at most 0.7d
Declaration
[Config]
public double ShrinkFactor { get; set; }
Property Value
Type |
Description |
System.Double |
|
Methods
Clone()
Makes an identical copy of this instance
Declaration
public TableOptions Clone()
Returns
Implements
Extension Methods