无法在xd-singlenode上使用spring-data-jpa部署spring-xd处理器模块

时间:2015-07-06 20:37:02

标签: java spring maven spring-data-jpa spring-xd

我有一个spring-xd处理器模块,它使用spring-data-jpa对项目具有依赖性:

xd-processor模块的pom.xml:

<dependencies>
    <dependency>
        <groupId>org.test.common</groupId>
        <artifactId>org.test.common</artifactId>
        <version>0.0.1-SNAPSHOT</version>
    </dependency>
</dependencies>

org.test.common的pom.xml:

<dependencies>
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-data-jpa</artifactId>
    </dependency>
</dependencies>

如果我运行integration test一切正常。但是部署到xd-singlenode(1.2.0.RELEASE)失败,出现以下错误:

2015-06-21T20:50:35+0200 1.2.0.RELEASE ERROR    DeploymentsPathChildrenCache-0 boot.SpringApplication - Application startup failed
java.lang.IllegalStateException: Error processing condition on org.springframework.boot.autoconfigure.orm.jpa.JpaBaseConfiguration.jpaVendorAdapter
    at org.springframework.boot.autoconfigure.condition.SpringBootCondition.matches(SpringBootCondition.java:58) ~[spring-boot-autoconfigure-1.2.3.RELEASE.jar:1.2.3.RELEASE]
...
Caused by: java.lang.IllegalArgumentException: @ConditionalOnMissingBean annotations must specify at least one bean (type, name or annotation)
...

您可以在github上查看完整的示例。

我做错了什么?任何帮助将不胜感激。

1 个答案:

答案 0 :(得分:1)

尝试以下解决方案

<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-data-jpa</artifactId>
<version>1.2.6.RELEASE</version>

click here了解更多