Class BloviateContainers.Builder
java.lang.Object
io.bloviate.testcontainers.BloviateContainers.Builder
- Enclosing class:
BloviateContainers
Configures and runs a fill against a
JdbcDatabaseContainer.-
Method Summary
Modifier and TypeMethodDescriptionbatchSize(int batchSize) Sets the JDBC batch size for INSERTs.databaseSupport(DatabaseSupport databaseSupport) Overrides the auto-detectedDatabaseSupport.voidfill()Opens a connection to the container and fills its schema.rows(long rows) Sets the default number of rows to generate per table.seed(long seed) Sets the base seed for reproducible generation.tableConfigurations(Set<TableConfiguration> tableConfigurations) Sets optional per-table overrides.
-
Method Details
-
batchSize
Sets the JDBC batch size for INSERTs.- Parameters:
batchSize- the JDBC batch size for INSERTs (default 1000)- Returns:
- this builder
-
rows
Sets the default number of rows to generate per table.- Parameters:
rows- the default number of rows to generate per table (default 100)- Returns:
- this builder
-
seed
Sets the base seed for reproducible generation.- Parameters:
seed- the base seed for reproducible generation (default 0); vary it for a different but reproducible dataset- Returns:
- this builder
-
databaseSupport
Overrides the auto-detectedDatabaseSupport.- Parameters:
databaseSupport- the support to use, or null to auto-detect from the connection- Returns:
- this builder
-
tableConfigurations
Sets optional per-table overrides.- Parameters:
tableConfigurations- optional per-table overrides (row counts, column generators)- Returns:
- this builder
-
fill
Opens a connection to the container and fills its schema.- Throws:
SQLException- if a database access error occurs
-