Spring Cloud Greenwich.SR6、Hoxton.SR5 和 2020.0.0-M2 (又名 Ilford) 已發布

發布 | Spencer Gibb | 2020年06月01日 | ...

謹代表社群,我很高興地宣布今天發布了以下版本:Spring Cloud Greenwich Release Train 的 Service Release 6 (SR6)、Spring Cloud Hoxton Release Train 的 Service Release 5 (SR5) 和 Spring Cloud 2020.0(代號 Ilford)Release Train 的 Milestone 2 (M2)。Greenwich 和 Hoxton 版本可在 Maven Central 的這裡這裡找到。Ilford 的 milestone 版本可以在 Spring Milestone 儲存庫中找到。您可以查看個別的發布說明以取得更多資訊:Greenwich.SR6Hoxton.SR52020.0.0-M2

與往常一樣,我們歡迎您在 GitHubGitterStack OverflowTwitter 上提供意見反應。


Greenwich Release Train 中的重要變更

Github 專案

Greenwich 與 Spring Boot 2.1.x 相容。

Spring Cloud Config

CVE-2020-5410:spring-cloud-config-server 的目錄遍歷

Spring Cloud Commons

反向移植 bootstrap 屬性來源排序修正。

下列模組已更新,作為 Greenwich.SR6 的一部分

| 模組 | 版本 | 問題 |--- |--- |--- |--- | Spring Cloud Config | 2.1.8.RELEASE |
| Spring Cloud Commons | 2.1.6.RELEASE | (問題)

若要開始使用具有 BOM (僅依賴管理) 的 Maven

<dependencyManagement>
    <dependencies>
        <dependency>
            <groupId>org.springframework.cloud</groupId>
            <artifactId>spring-cloud-dependencies</artifactId>
            <version>Greenwich.SR6</version>
            <type>pom</type>
            <scope>import</scope>
        </dependency>
    </dependencies>
</dependencyManagement>
<dependencies>
    <dependency>
        <groupId>org.springframework.cloud</groupId>
        <artifactId>spring-cloud-starter-config</artifactId>
    </dependency>
    <dependency>
        <groupId>org.springframework.cloud</groupId>
        <artifactId>spring-cloud-starter-netflix-eureka-client</artifactId>
    </dependency>
    ...
</dependencies>

或使用 Gradle

buildscript {
  dependencies {
    classpath "io.spring.gradle:dependency-management-plugin:1.0.9.RELEASE"
  }
}

apply plugin: "io.spring.dependency-management"

dependencyManagement {
  imports {
    mavenBom 'org.springframework.cloud:spring-cloud-dependencies:Greenwich.SR6'
  }
}

dependencies {
  compile 'org.springframework.cloud:spring-cloud-starter-config'
  compile 'org.springframework.cloud:spring-cloud-starter-netflix-eureka-client'
  //...
}

Hoxton Release Train 中的重要變更

Github 專案.

Hoxton.SR5 與 Spring Boot 2.3.x 和 2.2.x 相容。先前的 Hoxton 版本僅與 Spring Boot 2.2.x 相容。

Spring Cloud CLI 未作為 Hoxton.SR5 的一部分發布,請尋找 Hoxton.SR6 的發布版本。

Spring Cloud Contract

新增了對 Spring Cloud LoadBalancer 的支援。請參閱 發布說明,以取得有關升級和 Spring Cloud Contract Gradle Plugin 中的次要 API 變更的資訊。

Spring Cloud Kubernetes

標籤已新增至健康端點。

Spring Cloud Commons

新增了建構器以配置 Spring Cloud LoadBalancer 以及預先配置的 loadBalancers。LoadBalancer 快取機制已調整為支援 HealthCheckInstanceListSupplier。新增了對非可列舉屬性來源的支援。新增了對快取的隨機屬性來源的支援,因此具有隨機值的服務執行個體識別碼不會在重新整理事件期間重新定義。請參閱 發布說明,以取得有關兩個屬性值預設值的變更資訊。

Spring Cloud Netflix

Eureka Client 現在在 bootstrap 期間使用 Eureka HTTP API,因此執行個體不會先註冊然後取消註冊。

Spring Cloud Consul

新增了對 Consul 中繼資料的支援,而不是標籤中的中繼資料。

Spring Cloud Config

更新了對 Vault Azure MSI 驗證的支援。

Spring Cloud Gateway

新增了對自訂 Host 標頭的支援。

Spring Cloud Zookeeper

新增了 CuratorFrameworkCustomizer,允許使用者在自動配置後自訂 Curator。

Spring Cloud Bus

@RemoteApplicationEventsScan 的結果現在是累積的。RefreshRemoteApplicationEvent 僅在以本機為目標時在本機處理。

Spring Cloud Openfeign

新增了對 Spring Data 分頁排序的支援。新增了停用個別 Feign 客戶端父層上下文的功能。新增了 ErrorDecoderFactory

Spring Cloud Sleuth

預設情況下已停用 ExceptionLoggingFilter

以下模組已更新作為 Hoxton.SR5 的一部分

| 模組 | 版本 | 問題 |--- |--- |--- |--- | Spring Cloud Contract | 2.2.3.RELEASE | (問題) | Spring Cloud Kubernetes | 1.1.3.RELEASE | (問題) | Spring Cloud Cloudfoundry | 2.2.2.RELEASE | (問題) | Spring Cloud Commons | 2.2.3.RELEASE | (問題) | Spring Cloud Starter Build | Hoxton.SR5 |
| Spring Cloud Netflix | 2.2.3.RELEASE | (問題) | Spring Cloud Consul | 2.2.3.RELEASE | (問題) | Spring Cloud Config | 2.2.3.RELEASE | (問題) | Spring Cloud Gateway | 2.2.3.RELEASE | (問題) | Spring Cloud Gcp | 1.2.3.RELEASE |
| Spring Cloud Zookeeper | 2.2.2.RELEASE | (問題) | Spring Cloud Vault | 2.2.3.RELEASE | (問題) | Spring Cloud Circuitbreaker | 1.0.3.RELEASE | (問題) | Spring Cloud Bus | 2.2.2.RELEASE | (問題) | Spring Cloud Security | 2.2.2.RELEASE | (問題) | Spring Cloud Openfeign | 2.2.3.RELEASE | (問題) | Spring Cloud Aws | 2.2.2.RELEASE | (問題) | Spring Cloud Sleuth | 2.2.3.RELEASE | (問題)

若要開始使用具有 BOM (僅依賴管理) 的 Maven

<dependencyManagement>
    <dependencies>
        <dependency>
            <groupId>org.springframework.cloud</groupId>
            <artifactId>spring-cloud-dependencies</artifactId>
            <version>Hoxton.SR5</version>
            <type>pom</type>
            <scope>import</scope>
        </dependency>
    </dependencies>
</dependencyManagement>
<dependencies>
    <dependency>
        <groupId>org.springframework.cloud</groupId>
        <artifactId>spring-cloud-starter-config</artifactId>
    </dependency>
    <dependency>
        <groupId>org.springframework.cloud</groupId>
        <artifactId>spring-cloud-starter-netflix-eureka-client</artifactId>
    </dependency>
    ...
</dependencies>

或使用 Gradle

buildscript {
  dependencies {
    classpath "io.spring.gradle:dependency-management-plugin:1.0.9.RELEASE"
  }
}

apply plugin: "io.spring.dependency-management"

dependencyManagement {
  imports {
    mavenBom 'org.springframework.cloud:spring-cloud-dependencies:Hoxton.SR5'
  }
}

dependencies {
  compile 'org.springframework.cloud:spring-cloud-starter-config'
  compile 'org.springframework.cloud:spring-cloud-starter-netflix-eureka-client'
  //...
}

2020.0 版本系列中的顯著變更

Github 專案

Spring Cloud Netflix

Eureka Client 現在預設使用 WebClientRestTemplate,而不是 Jersey。

Spring Cloud Sleuth

Zipkin 依賴性已從核心中移除。

Spring Cloud Gateway

Java Route DSL 得到增強,不會洩漏 Route 方法。這有助於避免對 DSL 應該如何使用的混淆。

Spring Cloud Commons

spring.cloud.loadbalancer.health-check.initial-delay 配置已從 int 變更為 Duration

Spring Cloud Openfeign

Targeter 介面和 FeignClientFactoryBean 已公開。

以下模組已更新作為 2020.0.0-M2 的一部分

| 模組 | 版本 | 問題 |--- |--- |--- |--- | Spring Cloud Netflix | 3.0.0-M2 |
| Spring Cloud Sleuth | 3.0.0-M2 |
| Spring Cloud Consul | 3.0.0-M2 |
| Spring Cloud Kubernetes | 2.0.0-M2 |
| Spring Cloud Gateway | 3.0.0-M2 | (問題) | Spring Cloud Circuitbreaker | 2.0.0-M2 |
| Spring Cloud Contract | 3.0.0-M2 | (問題) | Spring Cloud Starter Build | 2020.0.0-M2 |
| Spring Cloud Config | 3.0.0-M2 |
| Spring Cloud Build | 3.0.0-M2 |
| Spring Cloud Cloudfoundry | 3.0.0-M2 |
| Spring Cloud Security | 3.0.0-M2 |
| Spring Cloud Bus | 3.0.0-M2 |
| Spring Cloud Cli | 3.0.0-M2 |
| Spring Cloud Vault | 3.0.0-M2 |
| Spring Cloud Zookeeper | 3.0.0-M2 |
| Spring Cloud Commons | 3.0.0-M2 |
| Spring Cloud Openfeign | 3.0.0-M2 |

若要開始使用具有 BOM (僅依賴管理) 的 Maven

<repositories>
    <repository>
        <id>spring-milestones</id>
        <name>Spring Milestones</name>
        <url>https://repo.spring.io/milestone</url>
        <snapshots>
            <enabled>false</enabled>
        </snapshots>
    </repository>
</repositories>
<dependencyManagement>
    <dependencies>
        <dependency>
            <groupId>org.springframework.cloud</groupId>
            <artifactId>spring-cloud-dependencies</artifactId>
            <version>2020.0.0-M2</version>
            <type>pom</type>
            <scope>import</scope>
        </dependency>
    </dependencies>
</dependencyManagement>
<dependencies>
    <dependency>
        <groupId>org.springframework.cloud</groupId>
        <artifactId>spring-cloud-starter-config</artifactId>
    </dependency>
    <dependency>
        <groupId>org.springframework.cloud</groupId>
        <artifactId>spring-cloud-starter-netflix-eureka-client</artifactId>
    </dependency>
    ...
</dependencies>

或使用 Gradle

buildscript {
  dependencies {
    classpath "io.spring.gradle:dependency-management-plugin:1.0.9.RELEASE"
  }
}

repositories {
  maven {
    url 'https://repo.spring.io/milestone'
  }
}

apply plugin: "io.spring.dependency-management"

dependencyManagement {
  imports {
    mavenBom 'org.springframework.cloud:spring-cloud-dependencies:2020.0.0-M2'
  }
}

dependencies {
  compile 'org.springframework.cloud:spring-cloud-starter-config'
  compile 'org.springframework.cloud:spring-cloud-starter-netflix-eureka-client'
  //...
}

取得 Spring 電子報

隨時掌握 Spring 電子報的最新資訊

訂閱

領先一步

VMware 提供培訓和認證,以加速您的進度。

瞭解更多

取得支援

Tanzu Spring 在一個簡單的訂閱中提供對 OpenJDK™、Spring 和 Apache Tomcat® 的支援和二進位檔案。

瞭解更多

即將舉行的活動

查看 Spring 社群中所有即將舉行的活動。

查看全部