DevToolsDataSourceAutoConfiguration fails when FactoryBean in Spring XML
See original GitHub issueI prepared example when adding devtools breaks application: https://github.com/michaldo/dev-tools-defect
DevToolsDataSourceAutoConfiguration$DevToolsDataSourceCondition.getMatchOutcome
calls context.getBeanFactory().getBeanNamesForType(DataSource.class);
If FactoryBean
is defined within Spring XML configuration, the factory is instantiated before placeholders ${}
are resolved, which can cause exceptions.
Issue Analytics
- State:
- Created 6 years ago
- Reactions:1
- Comments:8 (3 by maintainers)
Top Results From Across the Web
Spring Boot - Error creating bean with name 'dataSource ...
It looks like a classpath problem. What kind of dependency do you have for your database, and how is it defined in the...
Read more >How to use the Spring FactoryBean? - Baeldung
2. The Basics of Factory Beans · 2.1. Implement a FactoryBean · 2.2. Use FactoryBean With XML-based Configuration · 2.3. Use FactoryBean With...
Read more >Issue with SpringConfiguration.XML in Munit Error creating ...
Error creating bean with name '_muleNotificationManager': FactoryBean threw exception on object ... <spring:import resource="classpath:App-Config1.xml"/>.
Read more >Spring Boot Error - Error creating a bean with name ...
Spring Boot Error - Error creating a bean with name 'dataSource' defined in class path resource DataSourceAutoConfiguration. Hello guys, If you are using...
Read more >[Solved]-Bean definition store exception caused by ...
Exception was caused due to using different version of spring framework - Defined ... You can fix it by adding a "Bill of...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Sorry, we’re going to have a hard time spending too much time on this since it’s XML based configuration. Our recommendation is to move to Java config.
I use XML in application due legacy configuration. Workaround is working