I'm trying to use the file:inbound-channel-adapter and I'm getting the following error:
Clearly I'm not understanding something.
Exception in thread "main" org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'filesIn': Invocation of init method failed; nested excep\
tion is java.lang.IllegalArgumentException: No poller has been defined for channel-adapter 'filesIn', and no default poller is available within the context.
Im using 1.0.3 but I also tried this in 1.0.2. Here is what my context file looks like
<?xml version="1.0" encoding="UTF-8"?>
<beans:beans xmlns="http://www.springframework.org/schema/integration"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:beans="http://www.springframework.org/schema/beans"
xmlns:integration="http://www.springframework.org/schema/integration"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:util="http://www.springframework.org/schema/util" xmlns:jms="http://www.springframework.org/schema/integration/jms"
xmlns:file="http://www.springframework.org/schema/integration/file"
xmlns:si-xml="http://www.springframework.org/schema/integration/xml"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schem...-beans-2.5.xsd
http://www.springframework.org/schema/context
http://www.springframework.org/schem...ontext-2.5.xsd
http://www.springframework.org/schema/integration
http://www.springframework.org/schem...ration-1.0.xsd
http://www.springframework.org/schema/integration/jms
http://www.springframework.org/schem...on-jms-1.0.xsd
http://www.springframework.org/schema/integration/xml
http://www.springframework.org/schem...on-xml-1.0.xsd
http://www.springframework.org/schema/util
http://www.springframework.org/schem...g-util-2.5.xsd
http://www.springframework.org/schem...gration/stream
http://www.springframework.org/schem...stream-1.0.xsd
http://www.springframework.org/schema/integration/file
http://www.springframework.org/schema/integration/file/spring-integration-file-1.0.xsd">
<file:inbound-channel-adapter id="filesIn"
directory="file:/opt/ads/test-data"
channel="incomingDcgsaFilesChannel" />
<channel
id="incomingDcgsaFilesChannel">
<integration:interceptors>
<beans:ref
bean="interceptorMessageReceivedBean" />
<beans:ref
bean="interceptorEchoBean" />
</integration:interceptors>
</channel>
<service-activator
input-channel="incomingDcgsaFilesChannel"
ref="doNothingServiceActivator" />
</beans:beans>


Reply With Quote
oller>
