2016-11-03 13 views
0

IDEAで実行中にこのエラーが発生するのはなぜですか?既に回答済みの提案された質問を試しました。'int-xml:xpath-filter'要素の宣言が見つかりません

xml名前空間とschemalocationは、ドキュメントごとに一致します。固定

<?xml version="1.0" encoding="UTF-8"?> 
<beans xmlns="http://www.springframework.org/schema/beans" 
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
    xmlns:int="http://www.springframework.org/schema/integration" 
    xmlns:int-xml="http://www.springframework.org/schema/integration/xml" 
    xmlns:int-file="http://www.springframework.org/schema/integration/file" 
    xsi:schemaLocation="http://www.springframework.org/schema/beans 
     http://www.springframework.org/schema/beans/spring-beans.xsd 
     http://www.springframework.org/schema/integration 
     http://www.springframework.org/schema/integration/spring-integration.xsd 
     http://www.springframework.org/schema/integration/xml 
     http://www.springframework.org/schema/integration/xml/spring-integration-xml.xsd 
     http://www.springframework.org/schema/integration/file 
     http://www.springframework.org/schema/integration/file/spring-integration-file.xsd"> 

<int-file:inbound-channel-adapter 
     id="fileIn" 
     directory="file:${java.io.tmpdir}/fileFilter/input"> 
    <int:poller fixed-delay="500" /> 
</int-file:inbound-channel-adapter> 

<int:service-activator input-channel="fileIn" output-channel="fiterInChannel" ref="handler"/> 
<bean id="handler" class="org.learning.springintegration.fileadapters.FileInOutDemo"/> 

<int:channel id="fiterInChannel"> 
</int:channel> 

<int-xml:xpath-filter id="fileMajorAlarmFilter" 
         input-channel="fiterInChannel" 
         match-type="exact" 
         match-value="3" 
         output-channel="fileOut" 
         throw-exception-on-rejection="false"> 
    <int-xml:xpath-expression expression="/alarm/priorityvalue/text()" /> 
</int-xml:xpath-filter> 

<int-file:outbound-channel-adapter 
     id="fileOut" 
     directory="file:${java.io.tmpdir}/fileFilter/output" 
     delete-source-files="true"/> 

+1

は、出力ディレクトリと共有スタックトレースをきれいにしてください追加しました。さらに、 'spring-integration-xml'がクラスパスにあることを確認してください –

答えて

1

は、依存

<dependency> 
    <groupId>org.springframework.integration</groupId> 
    <artifactId>spring-integration-xml</artifactId> 
    <version>4.3.1.RELEASE</version> 
    <scope>compile</scope> 
</dependency> 
関連する問題