You are here: Configuration > File Configuration > Database Growth Size

Database Growth Size

Configures how much the database-file grows, when there not enough space. Whenever no free space in the database is large enough to store a object the database file is enlarged. This setting configures by how much it should be extended, in bytes. This configuration setting is intended to reduce fragmentation. Higher values will produce bigger database files and less fragmentation. To extend the database file, a single byte array is created and written to the end of the file in one write operation. Be aware that a high setting will require allocating memory for this byte array.

IEmbeddedConfiguration configuration = Db4oEmbedded.NewConfiguration();
configuration.File.DatabaseGrowthSize = 4096;
FileConfiguration.cs: Configure the growth size
Dim configuration As IEmbeddedConfiguration = Db4oEmbedded.NewConfiguration()
configuration.File.DatabaseGrowthSize = 4096
FileConfiguration.vb: Configure the growth size