Database creation options
When creating a Starcounter database, we can provide the following options to configure it.
Name | Type | Required | Default Value | Description |
|
| Yes |
| The collation to use for string values in the database. |
|
| Yes |
| The first object id (oid) value. |
|
| Yes |
| The last object id (oid) value. |
|
| Yes |
| Database transaction log file size in MiB. |
These options are available to configure via the Starcounter.Database.Bluestar.DatabaseCreationOptions
class.
Example:
*Note: These options are unchangeable after the database has been created.*
Collation
Collation
The Collation
option defines the collation to use for string values in the database. Starcounter supports the following string collations:
en-GB-CI-AS
, English, case insensitive, accent sensitive.sv-SE
, Swedish, case insensitive, accent insensitive.nb-NO
, Norwegian, case insensitive, accent insensitive.en-GB
, English, case insensitive, accent insensitive.ru-RU
, Russian, case insensitive, accent insensitive.
FirstObjectId
and LastObjectId
FirstObjectId
and LastObjectId
These options are used to limit range of the object identifiers (oid's) used by Starcounter. Every time a new database object is created, a unique oid will be assigned to it. If there is no more unique numbers in the range, an exception will be thrown.
The LogFileSize
option
LogFileSize
optionStarcounter continuously writes database changes to the transaction log on disk. Once the transaction log file grows to the size specified by LogFileSize
, it's compressed and a new file created. Any Starcounter database consists of at least two transaction log files.
256 MiB is the optimal value for production, but it can be tweaked if needed.
For testing purposes it might be beneficial to use smaller transaction log file size, such as 64 MiB.
The transaction log file size can be increased to any desired size to make transaction log compression happen less frequently.
Last updated