当前位置: 首页 > 知识库问答 >
问题:

最新的Spring云任务是否与Spring boot 2.6.6不兼容?

宗烨赫
2023-03-14

我正在尝试将spring云任务核心版本2.4.1与spring boot版本2.6.6(来自2021.0.x发行系列)一起使用。这显示了以下错误:

Your project setup is incompatible with our requirements due to following reasons:

- Spring Boot [2.6.6] is not compatible with this Spring Cloud release train


Action:

Consider applying the following actions:

- Change Spring Boot version to one of the following versions [2.4.x, 2.5.x] .
You can find the latest Spring Boot versions here [https://spring.io/projects/spring-boot#learn]. 
If you want to learn more about the Spring Cloud Release train compatibility, you can visit this page [https://spring.io/projects/spring-cloud#overview] and check the [Release Trains] section.
If you want to disable this check, just set the property [spring.cloud.compatibility-verifier.enabled=false]

这是否意味着云任务2.4.1与spring boot 2.6.6不兼容?在我向spring社区提出这个问题之前,我想先在这里确认一下。

编辑-1:我的Pom。将spring云任务依赖项用作BOM的xml:

对于以前的spring boot 2.1.1:

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-dependencies</artifactId>
                <version>${spring-boot.version}</version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>
        </dependencies>
    </dependencyManagement>

对于建议的Spring防尘套2.6.6或2.5.12:

   <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>org.springframework.cloud</groupId>
                <artifactId>spring-cloud-task-dependencies</artifactId>
                <version>${spring-cloud-task-dependencies.version}</version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>
        </dependencies>
    </dependencyManagement>

这里,我必须使用spring云任务依赖项。版本,因为Spring启动。版本给出以下错误:

共有1个答案

阎令
2023-03-14

Spring Boot 2.6.6和Spring Cloud Task 2.4.1兼容。

该消息由SpringBootVersionVerifier生成,SpringBootVersionVerifier是SpringCloudCommons的一部分。您似乎在版本3.0中拥有该工件。尽管您需要3.1版,但类路径上仍有x。x。

您需要确保spring cloud commons的版本没有以某种方式固定到某个旧版本。由Spring Cloud release train 2021.0的bom管理版本是最简单的。x。

Spring初始值设定项中的maven片段是

<dependencyManagement>
  <dependencies>
    <dependency>
      <groupId>org.springframework.cloud</groupId>
      <artifactId>spring-cloud-dependencies</artifactId>
      <version>${spring-cloud.version}</version>
      <type>pom</type>
      <scope>import</scope>
    </dependency>
  </dependencies>
</dependencyManagement>

其中<代码>Spring云。版本应设置为2021.0.1。

 类似资料:
  • 我们的微服务实现目前在Spring Cloud上。SR4,并且我们能够在使用Spring Boot 2.2.8时成功地处理Spring Cloud Stream Kinesis请求(发送Avro消息)。释放。然而,在升级到Spring Cloud之后。SR5,我们现在看到下面的异常堆栈跟踪,向我表明Spring Cloud和Hoxton之间可能存在不兼容。SR5和组织。springframewor

  • 我在使用SpringWebService和SpringFramework4.3时收到以下错误。15个版本罐。 spring-ws-2.1。2.全部释放。jarspring-ws-core-2.2。2.释放。罐子 您能告诉我如何解决这个问题吗?我需要升级SpringWS-JAR还是降低SpringFramework版本。 原因:java。lang.NoSuchMethodError:org。spri

  • 我在Openshift集群上安装了一个Spring Cloud数据流。我尝试注册一个应用程序,然后创建一个任务,一切都很好,但当我试图安排任务时,我遇到了以下异常: 我不知道这是什么意思,我是Dataflow的新手。我不明白为什么他试图使用Maven而不是kubernetes部署器,也不明白为什么我会出现这个错误。有人能再给我解释一下吗? 顺便说一句,我将这些应用程序注册为docker容器。

  • 我已经构建了一个应用程序,它是一个Eureka服务器,服务注册表。 pom.xml如下所示: 运行应用程序的主要类如下所示: 当我删除pom.xml中的eureka依赖项时,应用程序运行成功。 哪里不对?

  • 问题内容: 这是在我的Angular代码中正常工作的ES5函数: 我想将其转换为ES6箭头功能 但是它给出了错误 ES6箭头功能是否与Angular不兼容? 编辑:我想也许Angular不能推断出该名称,因此无法注入它,但随后我将其记录到控制台,并确实显示了它: 问题答案: 正确。您的AngularJS版本与使用$ injector的箭头功能不兼容。 这主要是因为AngularJS 1.4.6使用

  • Spring Cloud组成的批处理任务作业(jobid=1)被执行并停止而未完成。如果尝试从dataflow shell再次运行任务,则JobExecutionAlreadyRunningException将引发。即使为下一个任务执行创建了新的作业id 2。是否有任何解决方案可用于运行下一个任务,即使上一个任务的执行未完成/停止 使用MySQL在spring-cloud-dataflow-ser