Spring集成来自多个s3存储桶的AWS s3入站流媒体通道适配器流

Spring集成来自多个s3存储桶的AWS s3入站流媒体通道适配器流,spring,spring-boot,spring-integration,spring-integration-aws,Spring,Spring Boot,Spring Integration,Spring Integration Aws,我正在使用基于XML的spring集成,并使用s3入站流媒体通道适配器从单个s3存储桶进行流媒体传输 现在,我们需要从两个s3存储桶进行流式处理 因此,s3入站流媒体通道适配器是否可以从多个存储桶进行流媒体传输 或者我需要为每个s3存储桶创建一个单独的s3入站流媒体通道适配器吗 这是我目前为单个s3存储桶所做的设置,它确实有效 <int-aws:s3-inbound-streaming-channel-adapter channel="s3Channel" session-factory

我正在使用基于XML的spring集成,并使用
s3入站流媒体通道适配器
单个s3存储桶进行流媒体传输

现在,我们需要从两个s3存储桶进行流式处理

因此,
s3入站流媒体通道适配器
是否可以从多个
存储桶进行流媒体传输

或者我需要为每个s3存储桶创建一个单独的
s3入站流媒体通道适配器吗

这是我目前为单个s3存储桶所做的设置,它确实有效

<int-aws:s3-inbound-streaming-channel-adapter 
channel="s3Channel"
session-factory="s3SessionFactory" 
filter="acceptOnceFilter"
remote-directory-expression="'bucket-1'">
    <int:poller fixed-rate="1000"/>
</int-aws:s3-inbound-streaming-channel-adapter>

`

没错,当前的实现只支持一个定期轮询的
远程目录。我们现在正努力将这种解决方案正式化为一种开箱即用的特性。报告了类似的FTP支持请求,特别是在配置过程中不预先知道目标目录的情况下

如果为每个目录配置几个通道适配器对您来说不是什么大问题,那就太好了。您始终可以将消息从它们发送到同一通道进行处理

否则您可以考虑通过:

循环桶列表。
  <xsd:attribute name="remote-directory-expression" type="xsd:string">
        <xsd:annotation>
            <xsd:documentation>
                Specify a SpEL expression which will be used to evaluate the directory
                path to where the files will be transferred
                (e.g., "headers.['remote_dir'] + '/myTransfers'" for outbound endpoints)
                There is no root object (message) for inbound endpoints
                (e.g., "@someBean.fetchDirectory");
            </xsd:documentation>
        </xsd:annotation>
    </xsd:attribute>

指定将用于计算目录的SpEL表达式
文件将被传输到的路径
(例如,“头。['remote_dir']+'/myTransfers'”用于出站端点)
入站终结点没有根对象(消息)
(例如,“@someBean.fetchDirectory”);

在一些豆子里。

如果春天的人能给我指出正确的方向,我将不胜感激。谢谢。请看我的更新上面。我最终为每个入站适配器创建了acceptOnceFilter和metadataStore,因为如果没有它,就会出现一些奇怪的循环。
  <xsd:attribute name="remote-directory-expression" type="xsd:string">
        <xsd:annotation>
            <xsd:documentation>
                Specify a SpEL expression which will be used to evaluate the directory
                path to where the files will be transferred
                (e.g., "headers.['remote_dir'] + '/myTransfers'" for outbound endpoints)
                There is no root object (message) for inbound endpoints
                (e.g., "@someBean.fetchDirectory");
            </xsd:documentation>
        </xsd:annotation>
    </xsd:attribute>