私はSpringが初めてで、現在、ファイルをFTPロケーションに転送するためのstping統合に取り組んでいます。以下の Spring-context.xml を見つけてください。
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:int="http://www.springframework.org/schema/integration"
xmlns:int-ftp="http://www.springframework.org/schema/integration/ftp"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-3.1.xsd
http://www.springframework.org/schema/context
http://www.springframework.org/schema/context/spring-context-3.1.xsd
http://www.springframework.org/schema/integration
http://www.springframework.org/schema/integration/spring-integration-2.0.xsd
http://www.springframework.org/schema/integration/ftp
http://www.springframework.org/schema/integration/ftp/spring-integration-ftp-2.0.xsd">
<context:property-placeholder location="classpath:Test.properties"/>
<bean id="ftpClientFactory" class="org.springframework.integration.ftp.session.DefaultFtpSessionFactory">
<property name="host" value="${host}"/>
<property name="port" value="${availableServerPort}"/>
<property name="username" value="${userid}"/>
<property name="password" value="${password}"/>
</bean>
<int:channel id="ftpChannel"/>
<int-ftp:outbound-channel-adapter id="ftpOutbound" cache-sessions="false" charset="UTF-8" channel="ftpChannel" remote-directory="/" session-factory="ftpClientFactory"/>
</beans>
この XML ファイルの読み込み中。以下のエラーメッセージが表示されます
org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException:
Line 27 in XML document from class path resource [FTPOutboundChannelAdapterSample-context.xml]
is invalid; nested exception is org.xml.sax.SAXParseException; lineNumber: 27; columnNumber:
171; cvc-complex-type.2.4.c: The matching wildcard is strict, but no declaration can be found
for element 'int-ftp:outbound-channel-adapter'.
上記の xmlns:int-ftp 宣言を追加しましたが、まだエラー メッセージが表示されます。私は spring-integration-core-2.2.1、spring-integration-test-2.2.1 を使用しており、他のすべての春関連の jar はバージョン 3.1.4 です。この問題を解決するために私を助けてください。前もって感謝します