I\'d like to take advantage of some of the Spring Boot auto-configured beans in XML configuration files, but I keep running into exceptions and errors when I try to do so.
I used your autoconfig-test sample project and was able to get it to work. The only problem I found with your xml is as follows...
I'm assuming you want to use the embedded broker. When I ran your project, that was what was auto configured...
@Bean
public ConnectionFactory jmsConnectionFactory() {
return this.properties.createConnectionFactory();
}
This creates a bean named jmsConnectionFactory, however your xml is trying to wire a bean named connectionFactory. Changing the bean name to jmsConnectionFactory fixes that...
I don't know why you would want to use xml, but it does work.
Edit: I will also add there may be some misunderstanding of how to use spring jpa integration. Despite the fact the autowiring of the EntityManagerFactory does work, it really shouldn't be used directly. You should be wiring an EntityManager as follows...
@PersistenceContext
private EntityManager entityManager
I know its beyond the scope of this question, but just thought I should add that