eXtremeDB SQL .NET 6.0 API
Classes | Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes | Properties | List of all members
eXtremeDB.Database Class Reference

eXtremeDB database interface. More...

Inheritance diagram for eXtremeDB.Database:
Inheritance graph
[legend]

Classes

struct  BackupInfo
 
class  Device
 An abstract database device (a volatile or non-volatile memory resource). More...
 
class  FileDevice
 An Operating System file device. More...
 
struct  mco_db_params_t
 
struct  mco_log_params_t
 Parameters for the database open method. More...
 
struct  mco_ssl_params_t
 
class  MultiFileDevice
 A multifile segment. A multifile consists of several physical files. The size of each segment except the last is fixed, the last segment can be extended indefinitely. More...
 
class  Parameters
 Parameters for the database open method. More...
 
class  PrivateMemoryDevice
 An in-process private memory segment (allocated using malloc). More...
 
class  RaidDevice
 A RAID segment. More...
 
struct  RuntimeInfo
 Actual loaded runtime information More...
 
class  SharedMemoryDevice
 A shared memory region (allocated using mmap or a similar system call). More...
 
class  SSLParameters
 

Public Types

enum class  TransactionType { ReadOnly , Update , ReadWrite , Exclusive }
 Transaction types. More...
 
enum class  TransactionPriority {
  Idle , Background , Foreground , AboveNormal ,
  Highest
}
 Transaction priorities. More...
 
enum class  IsolationLevel { Default , ReadCommitted , RepeatableRead , Serializable }
 Transaction isolation levels. More...
 
enum class  LogType : int { NoLog , RedoLog , UndoLog }
 Transaction log types. More...
 
enum class  IndexType {
  Hashtable , BTree , Patricia , RTree ,
  RTreeOfPoint , KDTree , Trigram
}
 Index kind More...
 
enum class  CommitPolicy { SyncFlush , Buffered , Delayed , NoSync }
 Transaction commit policies (used only for on-disk databases). More...
 
enum class  TransSchedPolicy { Fifo , ReaderFavor , WriterFavor }
 Scheduling policy for transactions with the same priority More...
 
enum class  BackupType { Auto , Snapshot , Incremental }
 
enum class  Compression {
  ObjHead = 1 , ObjNode = 2 , BlobHead = 64 , BlobTail = 128 ,
  FixedrecSet = 4096 , All = ObjHead | ObjNode | FixedrecSet | BlobHead | BlobTail
}
 
enum class  Mode : int {
  WindowsShmPrefixNone = 0x00 , WindowsShmPrefixSessions = 0x01 , WindowsShmPrefixLocal = 0x02 , WindowsShmPrefixGlobal = 0x03 ,
  WindowsShmSecDescrNull = 0x00 , WindowsShmSecDescrEmpty = 0x04 , WindowsShmSecDescrSameUser = 0x0C , HighAvailabilitySupport = 0x10 ,
  TransactionLoggingSupport = 0x20 , ClusterSupport = 0x40 , MPIClusterSupport = 0x80 , SharedMemorySupport = 0x100 ,
  DiskSupport = 0x200 , MVCCTransactionManager = 0x400 , DebugSupport = 0x800 , CacheFieldAccess = 0x1000 ,
  SQLSupport = 0x2000 , DirectPointerSupport = 0x4000 , Default = 0
}
 
enum class  MDType { NULL = 0 , CONV = 1 , NAMED = 2 }
 

Public Member Functions

delegate bool ClusterQuorumDelegate (int[] neighbourIds)
 
RuntimeInfo GetRunTimeInfo ()
 
void Open (String name, Parameters parameters, Database.Device[] devices)
 The open database method. More...
 
void Open (String name, Parameters parameters, ulong size)
 Open an all-in-memory database . More...
 
void setRuntimeOption (int option, int val)
 Set database runtime option More...
 
int getRuntimeOption (int option)
 Get database runtime option More...
 
void SSLInit ()
 
void SSLLoadVerifyLocations (String caFile, String caPath)
 
void Close ()
 Close the database. More...
 
void Dispose ()
 Close the database. More...
 
Connection Connect ()
 Create a new database connection. Each thread should use its own database connection. More...
 
SqlLocalConnection ConnectSql ()
 Create a new local SQL database connection. connection. More...
 
SqlRemoteConnection ConnectRemoteSql (string host, int port)
 Create a new remote SQL database connection.

Parameters
hostxsql host name
portxsql port name
More...
 
SqlRemoteConnection ConnectRemoteSql (string host, int port, int maxAttempts)
 Create a new remote SQL database connection.

Parameters
hostxsql host name
portxsql port name
maxAttemptsmaximal attempts of connection to server, interval between each connection attempt is one second, so totally connection will be performed during maxConnectionAttempts seconds
More...
 
 Database (IDatabaseWrapper impl, Mode mode)
 The database constructor. More...
 
MDType getMDType ()
 
 Database (Mode mode)
 
 Database (Mode mode, string runtime_path)
 
 Database (IDatabaseWrapper impl)
 The database constructor. More...
 

Static Public Member Functions

static Database.mco_db_params_t createParameters ()
 

Static Public Attributes

const int DB_MODE_MVCC_AUTO_REPAIR = 0x01
 Automatically perform cleanup of a disk database after a crash. (remove all working copies.) (This is appropriate only if using the MVCC transaction manager.) More...
 
const int DB_MODE_SMART_INDEX_INSERT = 0x2
 Sort objects by key before inserting into disk indexes. More...
 
const int DB_OPEN_EXISTING = 0x04
 
const int DB_USE_CRC_CHECK = 0x08
 
const int DB_TRANSIENT = 0x10
 
const int DB_LAZY_MEM_INITIALIZATION = 0x20
 
const int DB_MURSIW_DISK_COMMIT_OPTIMIZATION = 0x40
 
const int DB_BULK_WRITE_MODIFIED_PAGES = 0x80
 
const int DB_TRANS_LOG_FAST_CRC = 0x0100
 
const int DB_INDEX_PRELOAD = 0x0200
 
const int DB_DISABLE_NESTED_TRANSACTIONS = 0x0400
 
const int DB_DISABLE_IMPLICIT_ROLLBACK = 0x0800
 
const int DB_INMEMORY_PROTECTION = 0x1000
 
const int DB_INCLUSIVE_BTREE = 0x2000
 
const int DB_INMEMORY_COMPRESSION = 0x4000
 
const int DB_SEPARATE_BITMAP = 0x8000
 
const int DB_DISABLE_BTREE_REBALANCE_ON_DELETE = 0x10000
 
const int DB_AUTO_ROLLBACK_FIRST_PHASE = 0x20000
 
const int DB_MVCC_COMPATIBILITY_MODE = 0x40000
 
const int DB_DISABLE_PAGE_POOL_RESERVE = 0x80000
 
const int DB_REDO_LOG_OPTIMIZATION = 0x100000
 
const int DB_DISABLE_HOT_UPDATES = 0x200000
 
const int DB_SQL_AUTOCHECKPOINT = 0x400000
 
const int DB_MODE_READ_ONLY = 0x800000
 
const int DB_USE_AIO = 0x1000000
 
const int DB_INCREMENTAL_BACKUP_ENABLED = 0x2000000
 
const int DB_INCREMENTAL_BACKUP_PROCESSING = 0x4000000
 
const int DB_MVCC_TABLE_LEVEL_LOCKING = 0x8000000
 
const int DB_DISABLE_SMART_ALLOC = 0x10000000
 
const int DB_DISABLE_DISK_SPACE_RESERVE = 0x20000000
 
const int DB_USE_ALLOCATION_MAP = 0x40000000
 
const String MULTIBYTE_ENCODING = "UTF-8"
 Multibyte string encoding. (This can be used in Parameters.StringEncoding and Encoding attribute.) More...
 
const String WIDE_CHARACTER_ENCODING = "UTF-16"
 Wide character string encoding. (This can be used in Parameters.StringEncoding and Encoding attribute.) More...
 
const int RT_OPTION_EXTHEAPS = 0
 Runtime options. More...
 
const int RT_WINDOWS_SHM_OPT = 1
 
const int RT_OPTION_MARK_LAST_OBJ = 2
 
const int RT_OPTION_UNIX_SHM_MASK = 3
 
const int RT_POSIX_SHM_OPT = 4
 
const int RT_CRC_ALGORITHM = 5
 
const int RT_MAX_PATRICIA_DEPTH = 6
 
const int RT_MAX_DYNAMIC_PIPES = 7
 
const int RT_OPTION_CLASS_LOAD_MERGE = 8
 
const int RT_OPTION_DATETIME_PRECISION = 9
 
const int BACKUP_FLAG_COMPRESSED = 1
 
const int BACKUP_FLAG_ENCRYPTED = 2
 
const int CLUSTER_NOTIFY_NODE_CONNECT = 0
 
const int CLUSTER_NOTIFY_NODE_DISCONNECT = 1
 

Properties

string? mco_root [get]
 

Detailed Description

eXtremeDB database interface.

Member Enumeration Documentation

◆ BackupType

Enumerator
Auto 
Snapshot 
Incremental 

◆ CommitPolicy

Transaction commit policies (used only for on-disk databases).

Enumerator
SyncFlush 

Wait until all changes are saved on disk. (the default policy)

Buffered 

Do not flush changes to disk.

Delayed 

Delay flushing changes to disk until the size of the changes or number of delayed transactions exceeds the specified threshold value.

NoSync 

Flush changes to disk asynchronously.

◆ Compression

Enumerator
ObjHead 
ObjNode 
BlobHead 
BlobTail 
FixedrecSet 
All 

◆ IndexType

Index kind

Enumerator
Hashtable 
BTree 
Patricia 
RTree 
RTreeOfPoint 
KDTree 
Trigram 

◆ IsolationLevel

Transaction isolation levels.

Enumerator
Default 
ReadCommitted 
RepeatableRead 
Serializable 

◆ LogType

enum eXtremeDB.Database.LogType : int
strong

Transaction log types.

Enumerator
NoLog 
RedoLog 
UndoLog 

◆ MDType

Enumerator
NULL 
CONV 
NAMED 

◆ Mode

enum eXtremeDB.Database.Mode : int
strong
Enumerator
WindowsShmPrefixNone 
WindowsShmPrefixSessions 
WindowsShmPrefixLocal 
WindowsShmPrefixGlobal 
WindowsShmSecDescrNull 
WindowsShmSecDescrEmpty 
WindowsShmSecDescrSameUser 
HighAvailabilitySupport 
TransactionLoggingSupport 
ClusterSupport 
MPIClusterSupport 
SharedMemorySupport 
DiskSupport 
MVCCTransactionManager 
DebugSupport 
CacheFieldAccess 
SQLSupport 
DirectPointerSupport 
Default 

◆ TransactionPriority

Transaction priorities.

Enumerator
Idle 
Background 
Foreground 
AboveNormal 
Highest 

◆ TransactionType

Transaction types.

Enumerator
ReadOnly 
Update 
ReadWrite 
Exclusive 

◆ TransSchedPolicy

Scheduling policy for transactions with the same priority

Enumerator
Fifo 

Honest policy: first-in first-out

ReaderFavor 

Place readers in queue before writers

WriterFavor 

Place writers in queue before readers

Constructor & Destructor Documentation

◆ Database() [1/4]

eXtremeDB.Database.Database ( IDatabaseWrapper  impl,
Mode  mode 
)

The database constructor.

Parameters
implImplementation of database wrapper
modeMask of Databasse.Mode flags

◆ Database() [2/4]

eXtremeDB.Database.Database ( Mode  mode)

◆ Database() [3/4]

eXtremeDB.Database.Database ( Mode  mode,
string  runtime_path 
)

◆ Database() [4/4]

eXtremeDB.Database.Database ( IDatabaseWrapper  impl)

The database constructor.

Parameters
implImplementation of database wrapper

Member Function Documentation

◆ Close()

void eXtremeDB.Database.Close ( )

Close the database.

◆ ClusterQuorumDelegate()

delegate bool eXtremeDB.Database.ClusterQuorumDelegate ( int[]  neighbourIds)

◆ Connect()

Connection eXtremeDB.Database.Connect ( )

Create a new database connection. Each thread should use its own database connection.

Returns
the new connection.

◆ ConnectRemoteSql() [1/2]

SqlRemoteConnection eXtremeDB.Database.ConnectRemoteSql ( string  host,
int  port 
)

Create a new remote SQL database connection.

Parameters
hostxsql host name
portxsql port name

Returns
the new remote connection.

◆ ConnectRemoteSql() [2/2]

SqlRemoteConnection eXtremeDB.Database.ConnectRemoteSql ( string  host,
int  port,
int  maxAttempts 
)

Create a new remote SQL database connection.

Parameters
hostxsql host name
portxsql port name
maxAttemptsmaximal attempts of connection to server, interval between each connection attempt is one second, so totally connection will be performed during maxConnectionAttempts seconds

Returns
the new remote connection.

◆ ConnectSql()

SqlLocalConnection eXtremeDB.Database.ConnectSql ( )

Create a new local SQL database connection. connection.

Returns
the new local connection.

◆ createParameters()

static Database.mco_db_params_t eXtremeDB.Database.createParameters ( )
static

◆ Dispose()

void eXtremeDB.Database.Dispose ( )

Close the database.

◆ getMDType()

MDType eXtremeDB.Database.getMDType ( )

◆ GetRunTimeInfo()

RuntimeInfo eXtremeDB.Database.GetRunTimeInfo ( )

◆ getRuntimeOption()

int eXtremeDB.Database.getRuntimeOption ( int  option)

Get database runtime option

◆ Open() [1/2]

void eXtremeDB.Database.Open ( String  name,
Parameters  parameters,
Database.Device[]  devices 
)

The open database method.

Parameters
name
parametersthe open parameters.
devicesthe list of database devices. If null, then actual database will not be created, useful f.e. for connecting to already existing shared memory database.

◆ Open() [2/2]

void eXtremeDB.Database.Open ( String  name,
Parameters  parameters,
ulong  size 
)

Open an all-in-memory database .

Parameters
name
parametersthe open parameters.
sizethe size of the database segment in memory.

◆ setRuntimeOption()

void eXtremeDB.Database.setRuntimeOption ( int  option,
int  val 
)

Set database runtime option

◆ SSLInit()

void eXtremeDB.Database.SSLInit ( )

◆ SSLLoadVerifyLocations()

void eXtremeDB.Database.SSLLoadVerifyLocations ( String  caFile,
String  caPath 
)

Member Data Documentation

◆ BACKUP_FLAG_COMPRESSED

const int eXtremeDB.Database.BACKUP_FLAG_COMPRESSED = 1
static

◆ BACKUP_FLAG_ENCRYPTED

const int eXtremeDB.Database.BACKUP_FLAG_ENCRYPTED = 2
static

◆ CLUSTER_NOTIFY_NODE_CONNECT

const int eXtremeDB.Database.CLUSTER_NOTIFY_NODE_CONNECT = 0
static

◆ CLUSTER_NOTIFY_NODE_DISCONNECT

const int eXtremeDB.Database.CLUSTER_NOTIFY_NODE_DISCONNECT = 1
static

◆ DB_AUTO_ROLLBACK_FIRST_PHASE

const int eXtremeDB.Database.DB_AUTO_ROLLBACK_FIRST_PHASE = 0x20000
static

◆ DB_BULK_WRITE_MODIFIED_PAGES

const int eXtremeDB.Database.DB_BULK_WRITE_MODIFIED_PAGES = 0x80
static

◆ DB_DISABLE_BTREE_REBALANCE_ON_DELETE

const int eXtremeDB.Database.DB_DISABLE_BTREE_REBALANCE_ON_DELETE = 0x10000
static

◆ DB_DISABLE_DISK_SPACE_RESERVE

const int eXtremeDB.Database.DB_DISABLE_DISK_SPACE_RESERVE = 0x20000000
static

◆ DB_DISABLE_HOT_UPDATES

const int eXtremeDB.Database.DB_DISABLE_HOT_UPDATES = 0x200000
static

◆ DB_DISABLE_IMPLICIT_ROLLBACK

const int eXtremeDB.Database.DB_DISABLE_IMPLICIT_ROLLBACK = 0x0800
static

◆ DB_DISABLE_NESTED_TRANSACTIONS

const int eXtremeDB.Database.DB_DISABLE_NESTED_TRANSACTIONS = 0x0400
static

◆ DB_DISABLE_PAGE_POOL_RESERVE

const int eXtremeDB.Database.DB_DISABLE_PAGE_POOL_RESERVE = 0x80000
static

◆ DB_DISABLE_SMART_ALLOC

const int eXtremeDB.Database.DB_DISABLE_SMART_ALLOC = 0x10000000
static

◆ DB_INCLUSIVE_BTREE

const int eXtremeDB.Database.DB_INCLUSIVE_BTREE = 0x2000
static

◆ DB_INCREMENTAL_BACKUP_ENABLED

const int eXtremeDB.Database.DB_INCREMENTAL_BACKUP_ENABLED = 0x2000000
static

◆ DB_INCREMENTAL_BACKUP_PROCESSING

const int eXtremeDB.Database.DB_INCREMENTAL_BACKUP_PROCESSING = 0x4000000
static

◆ DB_INDEX_PRELOAD

const int eXtremeDB.Database.DB_INDEX_PRELOAD = 0x0200
static

◆ DB_INMEMORY_COMPRESSION

const int eXtremeDB.Database.DB_INMEMORY_COMPRESSION = 0x4000
static

◆ DB_INMEMORY_PROTECTION

const int eXtremeDB.Database.DB_INMEMORY_PROTECTION = 0x1000
static

◆ DB_LAZY_MEM_INITIALIZATION

const int eXtremeDB.Database.DB_LAZY_MEM_INITIALIZATION = 0x20
static

◆ DB_MODE_MVCC_AUTO_REPAIR

const int eXtremeDB.Database.DB_MODE_MVCC_AUTO_REPAIR = 0x01
static

Automatically perform cleanup of a disk database after a crash. (remove all working copies.) (This is appropriate only if using the MVCC transaction manager.)

◆ DB_MODE_READ_ONLY

const int eXtremeDB.Database.DB_MODE_READ_ONLY = 0x800000
static

◆ DB_MODE_SMART_INDEX_INSERT

const int eXtremeDB.Database.DB_MODE_SMART_INDEX_INSERT = 0x2
static

Sort objects by key before inserting into disk indexes.

◆ DB_MURSIW_DISK_COMMIT_OPTIMIZATION

const int eXtremeDB.Database.DB_MURSIW_DISK_COMMIT_OPTIMIZATION = 0x40
static

◆ DB_MVCC_COMPATIBILITY_MODE

const int eXtremeDB.Database.DB_MVCC_COMPATIBILITY_MODE = 0x40000
static

◆ DB_MVCC_TABLE_LEVEL_LOCKING

const int eXtremeDB.Database.DB_MVCC_TABLE_LEVEL_LOCKING = 0x8000000
static

◆ DB_OPEN_EXISTING

const int eXtremeDB.Database.DB_OPEN_EXISTING = 0x04
static

◆ DB_REDO_LOG_OPTIMIZATION

const int eXtremeDB.Database.DB_REDO_LOG_OPTIMIZATION = 0x100000
static

◆ DB_SEPARATE_BITMAP

const int eXtremeDB.Database.DB_SEPARATE_BITMAP = 0x8000
static

◆ DB_SQL_AUTOCHECKPOINT

const int eXtremeDB.Database.DB_SQL_AUTOCHECKPOINT = 0x400000
static

◆ DB_TRANS_LOG_FAST_CRC

const int eXtremeDB.Database.DB_TRANS_LOG_FAST_CRC = 0x0100
static

◆ DB_TRANSIENT

const int eXtremeDB.Database.DB_TRANSIENT = 0x10
static

◆ DB_USE_AIO

const int eXtremeDB.Database.DB_USE_AIO = 0x1000000
static

◆ DB_USE_ALLOCATION_MAP

const int eXtremeDB.Database.DB_USE_ALLOCATION_MAP = 0x40000000
static

◆ DB_USE_CRC_CHECK

const int eXtremeDB.Database.DB_USE_CRC_CHECK = 0x08
static

◆ MULTIBYTE_ENCODING

const String eXtremeDB.Database.MULTIBYTE_ENCODING = "UTF-8"
static

Multibyte string encoding. (This can be used in Parameters.StringEncoding and Encoding attribute.)

◆ RT_CRC_ALGORITHM

const int eXtremeDB.Database.RT_CRC_ALGORITHM = 5
static

◆ RT_MAX_DYNAMIC_PIPES

const int eXtremeDB.Database.RT_MAX_DYNAMIC_PIPES = 7
static

◆ RT_MAX_PATRICIA_DEPTH

const int eXtremeDB.Database.RT_MAX_PATRICIA_DEPTH = 6
static

◆ RT_OPTION_CLASS_LOAD_MERGE

const int eXtremeDB.Database.RT_OPTION_CLASS_LOAD_MERGE = 8
static

◆ RT_OPTION_DATETIME_PRECISION

const int eXtremeDB.Database.RT_OPTION_DATETIME_PRECISION = 9
static

◆ RT_OPTION_EXTHEAPS

const int eXtremeDB.Database.RT_OPTION_EXTHEAPS = 0
static

Runtime options.

◆ RT_OPTION_MARK_LAST_OBJ

const int eXtremeDB.Database.RT_OPTION_MARK_LAST_OBJ = 2
static

◆ RT_OPTION_UNIX_SHM_MASK

const int eXtremeDB.Database.RT_OPTION_UNIX_SHM_MASK = 3
static

◆ RT_POSIX_SHM_OPT

const int eXtremeDB.Database.RT_POSIX_SHM_OPT = 4
static

◆ RT_WINDOWS_SHM_OPT

const int eXtremeDB.Database.RT_WINDOWS_SHM_OPT = 1
static

◆ WIDE_CHARACTER_ENCODING

const String eXtremeDB.Database.WIDE_CHARACTER_ENCODING = "UTF-16"
static

Wide character string encoding. (This can be used in Parameters.StringEncoding and Encoding attribute.)

Property Documentation

◆ mco_root

string? eXtremeDB.Database.mco_root
get

The documentation for this class was generated from the following file: