gpt4 book ai didi

java - 如何解决 outbound-gateway 不允许使用 http-method

转载 作者:行者123 更新时间:2023-11-30 10:36:00 25 4
gpt4 key购买 nike

您好,我正在将 spring-integration web 应用程序部署到 apache-tomcat-8.0.36:maven 依赖项是:

 <dependency>
<groupId>org.springframework.integration</groupId>
<artifactId>spring-integration-core</artifactId>
<version>4.3.5.RELEASE</version>
</dependency>

但是我在部署应用程序时遇到以下异常:

org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line 89 in XML document from ServletContext resource [/WEB-INF/spring/application-context.xml] is invalid; nested exception is org.xml.sax.SAXParseException; lineNumber: 89; columnNumber: 100; cvc-complex-type.3.2.2: Attribute 'http-method' is not allowed to appear in element 'int-http:outbound-gateway'.
at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:399) ~[spring-beans-4.3.4.RELEASE.jar:4.3.4.RELEASE]

我在war的WEB-INF/lib文件夹下也能看到spring-integration-core-4.3.5.RELEASE.jar

最佳答案

确保将 spring-integration-httpspring-integration-core 添加到您的依赖项中。

<dependency>
<groupId>org.springframework.integration</groupId>
<artifactId>spring-integration-http</artifactId>
<version>4.3.5.RELEASE</version>
</dependency>

关于java - 如何解决 outbound-gateway 不允许使用 http-method,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40799562/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com