Ambience/Repertoire 2024 and later versions support dynamic pool substitution in datasource definitions. To use this feature, you must first configure your connection pools and then reference them dynamically in your datasource.
1. Configure Connection Pools using a Wildcard
Begin by defining your connection pools. You can follow these guides for specific database types:
- Creating a Postgresql JDBC connection pool
- Creating a MSSQL JDBC connection pool
- Creating a MSSQL JDBC connection pool
- Establishing Oracle Connection Pool on Repertoire 202x Designer
To be able to configure dynamic pool substitution, you will have to edit the configuration to use wildcards:
elixir.data.jdbc.connection-pool {
definition {
"*" = "/path/to/your/build/hikari-*.properties"
}
}
For example:
This automatically loads all matching property files (e.g., hikari-postgres.properties, hikari-mysql.properties, hikari-oracle.properties) and creates unique pools for each.
Wildcard rules:
- Wildcards only apply at the file level, not in the path.
- Multiple wildcards are allowed (e.g.,
hik??i-*.properties). - You can mix wildcard keys with explicit pairs; if duplicates occur, the last processed wins.
- Only one wildcard key is allowed per config file.
This configuration ensures all pools are loaded automatically at server startup.
2. Parameterize the Pool in the DS File
Once your pools are configured, you can parameterize the datasource to select them dynamically by opening Repertoire Designer and entering ${pool} directly into the Connection Pool field in the Datasource Wizard:
Alternatively, you can open up your datasource in a text editor and edit the following connection-pool parameter to;
<ds:jdbc connection-type="POOL" connection-pool="${pool}">
Doing this prompts the pool name to be entered at runtime. Note that you can change "pool" to any other parameter name if needed.
Practical Guidance
- If you only have one or two pools, fixed DS files may be simpler.
- For larger numbers, configure pools with wildcards, then use
${pool}to parameterize selection dynamically.



