quarkusio/quarkus · critical · ConfigurationException
The Narayana JTA extension is configured to use the datasour
Error message
The Narayana JTA extension is configured to use the datasource '${objectStoreDataSourceName}' but that datasource is not configured. To solve this, either configure datasource ${objectStoreDataSourceName} referring to https://quarkus.io/guides/datasource for guidance, or configure another datasource to use in the Narayana JTA extension by setting property 'quarkus.transaction-manager.object-store.datasource' to the name of a configured datasource. What it means
Same startup path as the default-datasource error, but here quarkus.transaction-manager.object-store.datasource names a datasource that does not exist in the configured datasource set. The recorder validates the name in startRecoveryService and throws ConfigurationException, aborting startup.
Source
Thrown at extensions/narayana-jta/runtime/src/main/java/io/quarkus/narayana/jta/runtime/NarayanaJtaRecorder.java:172
if (transactions.getValue().objectStore().type().equals(ObjectStoreType.JDBC)) {
final String objectStoreDataSourceName;
if (transactions.getValue().objectStore().datasource().isEmpty()) {
if (!DataSourceUtil.hasDefault(configuredDataSourcesConfigKeys.keySet())) {
throw new ConfigurationException(
"The Narayana JTA extension does not have a datasource configured as the JDBC object store,"
+ " so it defaults to the default datasource,"
+ " but that datasource is not configured."
+ " To solve this, either configure the default datasource,"
+ " referring to https://quarkus.io/guides/datasource for guidance,"
+ " or configure the datasource to use in the Narayana JTA extension "
+ " by setting property 'quarkus.transaction-manager.object-store.datasource' to the name of a configured datasource.");
}
objectStoreDataSourceName = DataSourceUtil.DEFAULT_DATASOURCE_NAME;
} else {
objectStoreDataSourceName = transactions.getValue().objectStore().datasource().get();
if (!configuredDataSourcesConfigKeys.keySet().contains(objectStoreDataSourceName)) {
throw new ConfigurationException(
"The Narayana JTA extension is configured to use the datasource '"
+ objectStoreDataSourceName
+ "' but that datasource is not configured."
+ " To solve this, either configure datasource " + objectStoreDataSourceName
+ " referring to https://quarkus.io/guides/datasource for guidance,"
+ " or configure another datasource to use in the Narayana JTA extension "
+ " by setting property 'quarkus.transaction-manager.object-store.datasource' to the name of a configured datasource.");
}
}
if (dataSourcesWithTransactionIntegration.contains(objectStoreDataSourceName)) {
throw new ConfigurationException(String.format(
"The Narayana JTA extension is configured to use the '%s' JDBC "
+ "datasource as the transaction log storage, "
+ "but that datasource does not have transaction capabilities disabled. "
+ "To solve this, please set '%s=disabled', or configure another datasource "
+ "with disabled transaction capabilities as the JDBC object store. "
+ "Please refer to the https://quarkus.io/guides/transaction#jdbcstore for more information.",
objectStoreDataSourceName, configuredDataSourcesConfigKeys.get(objectStoreDataSourceName)));View on GitHub (pinned to e1c734241f)
Solutions
- Set quarkus.transaction-manager.object-store.datasource to a name that has a matching quarkus.datasource."<name>".* configuration block
- Or remove the property to fall back to the default datasource
- Verify the exact configured name in application.properties / profiles (test vs prod configs may differ)
Example fix
# before quarkus.transaction-manager.object-store.datasource=tx-store # after quarkus.datasource."tx-store".db-kind=postgresql quarkus.datasource."tx-store".jdbc.url=jdbc:postgresql://localhost:5432/txstore quarkus.transaction-manager.object-store.datasource=tx-store
Defensive patterns
Strategy: validation
Validate before calling
String ds = ConfigProvider.getConfig().getValue("quarkus.transaction-manager.object-store.datasource", String.class); if (ConfigProvider.getConfig().getOptionalValue("quarkus.datasource.\"" + ds + "\".db-kind", String.class).isEmpty()) throw new IllegalStateException("object-store datasource not configured: " + ds); Try / catch
try { app.start(); } catch (ConfigurationException e) { if (e.getMessage().contains("is configured to use the datasource")) { /* fix quarkus.transaction-manager.object-store.datasource */ } throw e; } Prevention
- Keep the object-store datasource name in a shared config constant
- Grep application.properties for all quarkus.datasource."<name>" blocks and cross-check the object-store name
- Re-check config after renaming or deleting datasources
When it happens
Trigger: quarkus.transaction-manager.object-store.datasource=<name> where <name> is not among the configured datasources (typo, datasource removed, name not matching quarkus.datasource."<name>". config keys).
Common situations: Typos in the datasource name; renaming/removing a named datasource without updating the transaction config; copy-pasting config between projects; case sensitivity of named datasource config keys.
Related errors
- The Narayana JTA extension does not have a datasource config
- The Narayana JTA extension is configured to use the '%s' JDB
- JDBC Store configured but the '%s' datasource is not configu
- Unable to find top command. Ensure you have a @CommandDefini
- No datasource named '<dataSourceName>' exists
AI-assisted analysis of quarkusio/quarkus@e1c734241f (2026-09-05).
Data as JSON: /api/errors/31b7b2d25cc115c9.
Report an issue: GitHub.