文件:出站适配器,可将文件放置在多个目标存储桶中

时间:2018-10-24 09:11:35

标签: spring spring-integration spring-integration-sftp

有一个spring应用程序,我试图在其中使用单个文件出站适配器/网关将文件放置到多个目录中。

想知道是否有可能使用spring-integration-file i使用单个出站适配器将文件放置在多个目录中

任何建议都会有所帮助。

文件:出站适配器:

<integration:chain id="filesOutChain" input-channel="filesOut">
    <integration:transformer expression="headers.FILE"/>
        <file:outbound-gateway id="fileMover" 
            auto-create-directory="true"
            directory-expression="headers.TARGET_PATH"
            mode="REPLACE">
            <file:request-handler-advice-chain>
                <ref bean="retryAdvice" />
            </file:request-handler-advice-chain>
        </file:outbound-gateway>    
        <integration:gateway request-channel="filesOutChainChannel" error-channel="errorChannel"/>
    </integration:chain>

0 个答案:

没有答案