Class XADataSourceAutoConfiguration
java.lang.Object
org.springframework.boot.autoconfigure.jdbc.XADataSourceAutoConfiguration
- All Implemented Interfaces:
Aware
,BeanClassLoaderAware
@AutoConfiguration(before=DataSourceAutoConfiguration.class)
@EnableConfigurationProperties(DataSourceProperties.class)
@ConditionalOnClass({javax.sql.DataSource.class,jakarta.transaction.TransactionManager.class,org.springframework.jdbc.datasource.embedded.EmbeddedDatabaseType.class})
@ConditionalOnBean(XADataSourceWrapper.class)
@ConditionalOnMissingBean(javax.sql.DataSource.class)
public class XADataSourceAutoConfiguration
extends Object
implements BeanClassLoaderAware
Auto-configuration
for DataSource
with XA.- Since:
- 1.2.0
- Author:
- Phillip Webb, Josh Long, Madhura Bhave, Moritz Halbritter, Andy Wilkinson
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiondataSource
(XADataSourceWrapper wrapper, DataSourceProperties properties, JdbcConnectionDetails connectionDetails, ObjectProvider<XADataSource> xaDataSource) void
setBeanClassLoader
(ClassLoader classLoader)
-
Constructor Details
-
XADataSourceAutoConfiguration
public XADataSourceAutoConfiguration()
-
-
Method Details
-
dataSource
@Bean public DataSource dataSource(XADataSourceWrapper wrapper, DataSourceProperties properties, JdbcConnectionDetails connectionDetails, ObjectProvider<XADataSource> xaDataSource) throws Exception - Throws:
Exception
-
setBeanClassLoader
- Specified by:
setBeanClassLoader
in interfaceBeanClassLoaderAware
-