SparkseeNet  5.0.0
Public Member Functions | List of all members
com.sparsity.sparksee.gdb.SparkseeConfig Class Reference

Sparksee configuration class. More...

Public Member Functions

long GetHighAvailabilitySynchronization ()
 Gets the synchronization polling time. More...
 
void SetRecoveryCacheMaxSize (int v)
 Sets the maximum size for the recovery log cache in extents. More...
 
void SetHighAvailabilityIP (System.String v)
 Sets the IP address and port of the instance. More...
 
void SetPoolPersistentMinSize (int v)
 Sets the minimum size for the persistent pool in number of frames. More...
 
int GetExtentSize ()
 Gets the size of a extent. More...
 
void SetHighAvailabilityEnabled (bool v)
 Enables or disables high availability mode. More...
 
void SetHighAvailabilityCoordinators (System.String v)
 Sets the coordinators address and port list. More...
 
System.String GetLogFile ()
 Gets the log file. More...
 
long GetRecoveryCheckpointTime ()
 Gets the delay time (in microseconds) between automatic checkpoints. More...
 
void SetCacheStatisticsSnapshotTime (long v)
 Sets the cache statistics snapshot time. More...
 
bool GetCacheStatisticsEnabled ()
 Gets whether cache statistics are enabled or disabled. More...
 
int GetPoolPersistentMaxSize ()
 Gets the maximum size for the persistent pool in number of frames. More...
 
void SetLogLevel (com.sparsity.sparksee.gdb.LogLevel v)
 Sets the log level. More...
 
void SetExtentSize (int v)
 Sets the size of a pool frame in number of extents. More...
 
System.String GetRecoveryLogFile ()
 Gets the recovery log file. More...
 
int GetExtentPages ()
 Gets the number of pages per extent. More...
 
void SetPoolPersistentMaxSize (int v)
 Sets the maximum size for the persistent pool in number of frames. More...
 
void SetCacheMaxSize (int v)
 Sets the maximum size for the cache (all pools) in MB. More...
 
bool GetHighAvailabilityEnabled ()
 Gets whether high availability mode is enabled or disabled. More...
 
void SetRecoveryLogFile (System.String v)
 Sets the recovery log file. More...
 
bool GetRecoveryEnabled ()
 Gets whether the recovery is enabled or disabled. More...
 
 SparkseeConfig ()
 Creates a new instance. More...
 
System.String GetHighAvailabilityCoordinators ()
 Gets the coordinators address and port list. More...
 
void SetLicense (System.String v)
 Sets the license code. More...
 
void SetRecoveryEnabled (bool v)
 Enables or disables the recovery. More...
 
void SetPoolTemporaryMaxSize (int v)
 Sets the maximum size for the temporary pool in number of frames. More...
 
void SetHighAvailabilitySynchronization (long v)
 Sets the synchronization polling time. More...
 
void SetPoolFrameSize (int v)
 Sets the size of a pool frame in number of extents. More...
 
System.String GetCacheStatisticsFile ()
 Gets the cache statistics log file. More...
 
void SetCacheStatisticsFile (System.String v)
 Sets the cache statistics log file. More...
 
int GetPoolFrameSize ()
 Gets the size of a pool frame in number of extents. More...
 
int GetCacheMaxSize ()
 Gets the maximum size for the cache (all pools) in MB. More...
 
long GetCacheStatisticsSnapshotTime ()
 Gets the cache statistics snapshot time in microseconds. More...
 
int GetPoolTemporaryMaxSize ()
 Gets the maximum size for the temporary pool in number of frames. More...
 
void SetExtentPages (int v)
 Sets the number of pages per extent. More...
 
void SetPoolTemporaryMinSize (int v)
 Sets the minimum size for the temporary pool in number of frames. More...
 
System.String GetLicense ()
 Gets the license code. More...
 
int GetPoolTemporaryMinSize ()
 Gets the minimum size for the temporary pool in number of frames. More...
 
void SetHighAvailabilityMasterHistory (long v)
 Sets the master's history log. More...
 
void SetCacheStatisticsEnabled (bool v)
 Enables or disables cache statistics. More...
 
int GetRecoveryCacheMaxSize ()
 Gets the maximum size for the recovery log cache in extents. More...
 
long GetHighAvailabilityMasterHistory ()
 Gets the master's history log. More...
 
System.String GetHighAvailabilityIP ()
 Gets the IP address and port of the instance. More...
 
com.sparsity.sparksee.gdb.LogLevel GetLogLevel ()
 Gets the log level. More...
 
void SetRecoveryCheckpointTime (long v)
 Sets the delay time (in microseconds) between automatic checkpoints. More...
 
void SetLogFile (System.String v)
 Sets the log file. More...
 
int GetPoolPersistentMinSize ()
 Gets the minimum size for the persistent pool in number of frames. More...
 

Detailed Description

Sparksee configuration class.

If not specified, 0 means unlimited which is the maximum available. For the pools that's the total cache size. For the cache unlimited means nearly all the physical memory of the computer.

For each field, there is a default value. This value can be overrided with values from a properties file (see SparkseeProperties class). Also, this settings can be overrided calling a specific setter.

For each field, it is shown its default value and the property to override this value:

Extent size: 4KB ('sparksee.storage.extentsize' at SparkseeProperties).

Pages per extent: 1 page ('sparksee.storage.extentpages' at SparkseeProperties).

Pool frame size: 1 extent ('sparksee.io.pool.frame.size' at SparkseeProperties).

Minimum size for the persistent pool: 64 frames ('sparksee.io.pool.persistent.minsize' at SparkseeProperties).

Maximum size for the persistent pool: 0 frames ('sparksee.io.pool.persistent.maxsize' at SparkseeProperties).

Minimum size for the temporary pool: 16 frames ('sparksee.io.pool.temporal.minsize' at SparkseeProperties).

Maximum size for the temporary pool: 0 frames ('sparksee.io.pool.temporal.maxsize' at SparkseeProperties).

Maximum size for the cache (all pools): 0 MB ('sparksee.io.cache.maxsize' at SparkseeProperties).

License code: "" ('sparksee.license' at SparkseeProperties). No license code means evaluation license.

Log level: Info ('sparksee.log.level' at SparkseeProperties).

Log file: "sparksee.log" ('sparksee.log.file' at SparkseeProperties).

Cache statistics: false (disabled) ('sparksee.cache.statistics' at SparkseeProperties).

Cache statistics log file: "statistics.log" ('sparksee.cache.statisticsFile' at SparkseeProperties).

Cache statistics snapshot time: 1000 msecs [TimeUnit] ('sparksee.cache.statisticsSnapshotTime' at SparkseeProperties).

Recovery enabled: false ('sparksee.io.recovery' at SparkseeProperties).

Recovery log file: "" ('sparksee.io.recovery.logfile' at SparkseeProperties).

Recovery cache max size: 1MB ('sparksee.io.recovery.cachesize' at SparkseeProperties).

Recovery checkpoint time: 60 seconds [TimeUnit] ('sparksee.io.recovery.checkpointTime' at SparkseeProperties).

High-availability: false (disabled) ('sparksee.ha' at SparkseeProperties).

High-availability coordinators: "" ('sparksee.ha.coordinators' at SparkseeProperties).

High-availability IP: "" ('sparksee.ha.ip' at SparkseeProperties).

High-availability sync polling: 0 (disabled) [TimeUnit] ('sparksee.ha.sync' at SparkseeProperties).

High-availability master history: 1D (1 day) [TimeUnit] ('sparksee.ha.master.history' at SparkseeProperties).

Use of TimeUnit:

Those variables using TimeUnit allow for:

<X>[D|H|M|S|s|m|u]

where <X> is a number followed by an optional character which represents the unit: D for days, H for hours, M for minutes, S or s for seconds, m for milliseconds and u for microseconds. If no unit character is given, seconds are assumed.

Author
Sparsity Technologies http://www.sparsity-technologies.com

Constructor & Destructor Documentation

com.sparsity.sparksee.gdb.SparkseeConfig.SparkseeConfig ( )

Creates a new instance.

Values are set with default values.

Member Function Documentation

int com.sparsity.sparksee.gdb.SparkseeConfig.GetCacheMaxSize ( )

Gets the maximum size for the cache (all pools) in MB.

Returns
The maximum size for the cache (all pools) in MB.
bool com.sparsity.sparksee.gdb.SparkseeConfig.GetCacheStatisticsEnabled ( )

Gets whether cache statistics are enabled or disabled.

Returns
TRUE if cache statistics are enabled, FALSE otherwise.
System.String com.sparsity.sparksee.gdb.SparkseeConfig.GetCacheStatisticsFile ( )

Gets the cache statistics log file.

Useless if cache statistics are disabled.

Returns
The cache statistics log file.
long com.sparsity.sparksee.gdb.SparkseeConfig.GetCacheStatisticsSnapshotTime ( )

Gets the cache statistics snapshot time in microseconds.

Useless if cache statistics are disabled.

Returns
The cache statistics snapshot time in microseconds.
int com.sparsity.sparksee.gdb.SparkseeConfig.GetExtentPages ( )

Gets the number of pages per extent.

Returns
The number of pages per extent.
int com.sparsity.sparksee.gdb.SparkseeConfig.GetExtentSize ( )

Gets the size of a extent.

Returns
The size of a extent in KB.
System.String com.sparsity.sparksee.gdb.SparkseeConfig.GetHighAvailabilityCoordinators ( )

Gets the coordinators address and port list.

Returns
The coordinators address and port list.
bool com.sparsity.sparksee.gdb.SparkseeConfig.GetHighAvailabilityEnabled ( )

Gets whether high availability mode is enabled or disabled.

Returns
TRUE if high availability mode is enabled, FALSE otherwise.
System.String com.sparsity.sparksee.gdb.SparkseeConfig.GetHighAvailabilityIP ( )

Gets the IP address and port of the instance.

Returns
The IP address and port of the instance.
long com.sparsity.sparksee.gdb.SparkseeConfig.GetHighAvailabilityMasterHistory ( )

Gets the master's history log.

Returns
The master's history log.
long com.sparsity.sparksee.gdb.SparkseeConfig.GetHighAvailabilitySynchronization ( )

Gets the synchronization polling time.

Returns
The Synchronization polling time.
System.String com.sparsity.sparksee.gdb.SparkseeConfig.GetLicense ( )

Gets the license code.

Returns
The license code.
System.String com.sparsity.sparksee.gdb.SparkseeConfig.GetLogFile ( )

Gets the log file.

Returns
The log file.
com.sparsity.sparksee.gdb.LogLevel com.sparsity.sparksee.gdb.SparkseeConfig.GetLogLevel ( )

Gets the log level.

Returns
The LogLevel.
int com.sparsity.sparksee.gdb.SparkseeConfig.GetPoolFrameSize ( )

Gets the size of a pool frame in number of extents.

Returns
The size of a pool frame in number of extents.
int com.sparsity.sparksee.gdb.SparkseeConfig.GetPoolPersistentMaxSize ( )

Gets the maximum size for the persistent pool in number of frames.

Returns
The maximum size for the persistent pool in number of frames.
int com.sparsity.sparksee.gdb.SparkseeConfig.GetPoolPersistentMinSize ( )

Gets the minimum size for the persistent pool in number of frames.

Returns
The minimum size for the persistent pool in number of frames.
int com.sparsity.sparksee.gdb.SparkseeConfig.GetPoolTemporaryMaxSize ( )

Gets the maximum size for the temporary pool in number of frames.

Returns
The maximum size for the temporary pool in number of frames.
int com.sparsity.sparksee.gdb.SparkseeConfig.GetPoolTemporaryMinSize ( )

Gets the minimum size for the temporary pool in number of frames.

Returns
The minimum size for the temporary pool in number of frames.
int com.sparsity.sparksee.gdb.SparkseeConfig.GetRecoveryCacheMaxSize ( )

Gets the maximum size for the recovery log cache in extents.

Returns
The maximum size for the recovery log cache in extents.
long com.sparsity.sparksee.gdb.SparkseeConfig.GetRecoveryCheckpointTime ( )

Gets the delay time (in microseconds) between automatic checkpoints.

Returns
The delay time (in microseconds) between automatic checkpoints.
bool com.sparsity.sparksee.gdb.SparkseeConfig.GetRecoveryEnabled ( )

Gets whether the recovery is enabled or disabled.

Returns
TRUE if the recovery is enabled, FALSE otherwise.
System.String com.sparsity.sparksee.gdb.SparkseeConfig.GetRecoveryLogFile ( )

Gets the recovery log file.

Returns
The recovery log file.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetCacheMaxSize ( int  v)

Sets the maximum size for the cache (all pools) in MB.

Parameters
v[in] The maximum size for the cache (all pools) in MB. It must be non-negative.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetCacheStatisticsEnabled ( bool  v)

Enables or disables cache statistics.

Parameters
v[in] If TRUE this enables cache statistics, if FALSE this disables cache statistics.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetCacheStatisticsFile ( System.String  v)

Sets the cache statistics log file.

Useless if cache statistics are disabled.

Parameters
v[in] The cache statistics log file.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetCacheStatisticsSnapshotTime ( long  v)

Sets the cache statistics snapshot time.

Useless if cache statistics are disabled.

Parameters
v[in] The cache statistics snapshot time in microseconds.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetExtentPages ( int  v)

Sets the number of pages per extent.

Parameters
v[in] The number of pages. It must be at least 1 page and the page size must be greater than or equal to 4KB.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetExtentSize ( int  v)

Sets the size of a pool frame in number of extents.

Parameters
v[in] The size of a extent size in KB. An extent can have a size between 4KB and 64KB, and it must be a power of 2.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetHighAvailabilityCoordinators ( System.String  v)

Sets the coordinators address and port list.

Parameters
v[in] The coordinators address and port list.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetHighAvailabilityEnabled ( bool  v)

Enables or disables high availability mode.

Parameters
v[in] If TRUE this enables high availability mode, if FALSE this disables high availability mode.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetHighAvailabilityIP ( System.String  v)

Sets the IP address and port of the instance.

Parameters
v[in] The IP address and port of the instance.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetHighAvailabilityMasterHistory ( long  v)

Sets the master's history log.

Parameters
v[in] The master's history log.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetHighAvailabilitySynchronization ( long  v)

Sets the synchronization polling time.

Parameters
v[in] The synchronization polling time.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetLicense ( System.String  v)

Sets the license code.

Parameters
v[in] The license code.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetLogFile ( System.String  v)

Sets the log file.

Parameters
v[in] The log file.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetLogLevel ( com.sparsity.sparksee.gdb.LogLevel  v)

Sets the log level.

Parameters
v[in] The LogLevel.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetPoolFrameSize ( int  v)

Sets the size of a pool frame in number of extents.

Parameters
v[in] The size of a pool frame in number of extents. It must be non-negative.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetPoolPersistentMaxSize ( int  v)

Sets the maximum size for the persistent pool in number of frames.

Parameters
v[in] The maximum size for the persistent pool in number of frames. It must be non-negative.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetPoolPersistentMinSize ( int  v)

Sets the minimum size for the persistent pool in number of frames.

Parameters
v[in] The minimum size for the persistent pool in number of frames. It must be non-negative.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetPoolTemporaryMaxSize ( int  v)

Sets the maximum size for the temporary pool in number of frames.

Parameters
v[in] The maximum size for the temporary pool in number of frames. It must be non-negative.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetPoolTemporaryMinSize ( int  v)

Sets the minimum size for the temporary pool in number of frames.

Parameters
v[in] The minimum size for the temporary pool in number of frames. It must be non-negative.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetRecoveryCacheMaxSize ( int  v)

Sets the maximum size for the recovery log cache in extents.

Parameters
v[in] The maximum size for the recovery log cache in extents. A 0 sets the default value (extents up to 1MB).
void com.sparsity.sparksee.gdb.SparkseeConfig.SetRecoveryCheckpointTime ( long  v)

Sets the delay time (in microseconds) between automatic checkpoints.

Parameters
v[in] The delay time (in microseconds) between automatic checkpoints. A 0 forces a checkpoint after each commited transaction.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetRecoveryEnabled ( bool  v)

Enables or disables the recovery.

Parameters
v[in] If TRUE this enables the recovery, if FALSE then disables it.
void com.sparsity.sparksee.gdb.SparkseeConfig.SetRecoveryLogFile ( System.String  v)

Sets the recovery log file.

Parameters
v[in] The recovery log file. Left it empty for the default log file (same as <database_file_name>.log)