2015-09-16 30 views
0

我正在使用彈簧引導1.2.5.RELEASE,我使用spring-boot-starter-redis春季啓動如何調用新修復的bug版本?

但我在spring-boot-starter-redis上發現了一個bug,並且spring-boot已經修復了它。

的錯誤是在這裏:

Version 1.6 GA (Gosling)

spring data redis starter exception

Upgrade to Spring Data Gosling RELEASE

現在我可以使用1.2.5.RELEASE固定的版本Version 1.6 GA? 如果不是,我該怎麼辦?下面

是我的pom.xml

<?xml version="1.0" encoding="UTF-8"?> 
<project xmlns="http://maven.apache.org/POM/4.0.0" 
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0  
http://maven.apache.org/xsd/maven-4.0.0.xsd"> 
<modelVersion>4.0.0</modelVersion> 

<parent> 
    <groupId>org.springframework.boot</groupId> 
    <artifactId>spring-boot-starter-parent</artifactId> 
    <version>1.2.5.RELEASE</version> 
</parent> 

<groupId>com.mycompany</groupId> 
<artifactId>tradove-backend-parent</artifactId> 
<packaging>pom</packaging> 
<version>1.0-SNAPSHOT</version> 
<modules> 
    <module>mycompany-redis</module> 
    <module>mycompany-common</module> 
    <module>mycompany-email</module> 
    <module>mycompany-file-system</module> 
    <module>mycompany-domain</module> 
    <module>mycompany-service</module> 
    <module>mycompany-solr</module> 
    <module>mycompany-sms</module> 
</modules> 

<repositories> 
    <repository> 
     <id>nexus</id> 
     <name>local private nexus</name> 
     <url>http://maven.oschina.net/content/groups/public/</url> 
     <releases> 
      <enabled>true</enabled> 
     </releases> 
     <snapshots> 
      <enabled>false</enabled> 
     </snapshots> 
    </repository> 
</repositories> 
<pluginRepositories> 
    <pluginRepository> 
     <id>nexus</id> 
     <name>local private nexus</name> 
     <url>http://maven.oschina.net/content/groups/public/</url> 
     <releases> 
      <enabled>true</enabled> 
     </releases> 
     <snapshots> 
      <enabled>false</enabled> 
     </snapshots> 
    </pluginRepository> 
</pluginRepositories> 


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

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

    <!-- hateos --> 
    <dependency> 
     <groupId>org.springframework.boot</groupId> 
     <artifactId>spring-boot-starter-hateoas</artifactId> 
    </dependency> 

    <!-- data redis --> 
    <dependency> 
     <groupId>org.springframework.boot</groupId> 
     <artifactId>spring-boot-starter-redis</artifactId> 
    </dependency> 

    <!-- data solr--> 
    <dependency> 
     <groupId>org.springframework.boot</groupId> 
     <artifactId>spring-boot-starter-data-solr</artifactId> 
    </dependency> 

    <dependency> 
     <groupId>org.springframework.boot</groupId> 
     <artifactId>spring-boot-starter-mail</artifactId> 
    </dependency> 


    <dependency> 
     <groupId>mysql</groupId> 
     <artifactId>mysql-connector-java</artifactId> 
    </dependency> 


    <dependency> 
     <groupId>org.springframework.boot</groupId> 
     <artifactId>spring-boot-starter-test</artifactId> 
     <scope>test</scope> 
    </dependency> 

    <dependency> 
     <groupId>com.jayway.restassured</groupId> 
     <artifactId>rest-assured</artifactId> 
     <version>2.3.3</version> 
     <scope>test</scope> 
    </dependency> 


    <dependency> 
     <groupId>commons-lang</groupId> 
     <artifactId>commons-lang</artifactId> 
     <version>2.6</version> 
    </dependency> 

    <dependency> 
     <groupId>org.springframework.boot</groupId> 
     <artifactId>spring-boot-configuration-processor</artifactId> 
     <optional>true</optional> 
    </dependency> 

</dependencies> 

回答

1

春季啓動導入爲Spring數據公佈列車的BOM獲取所有的春季數據模塊的版本。要升級到包含Spring Data Redis 1.6的Gosling發行版,請覆蓋您的pom中的spring-data-releasetrain.version屬性:

<properties> 
    <spring-data-releasetrain.version>Gosling-RELEASE</spring-data-releasetrain.version> 
</properties> 
+0

謝謝,文件在哪裏? – diligent

+0

明白了,謝謝。 – diligent

+0

我應該把內容放在哪裏,pom.xml? – diligent