1
下面是出站http网关配置了标题,但在添加轮询器时没有连续触发。它只会触发一次并停止。带有轮询器的弹簧集成出站网关
<int:inbound-channel-adapter channel="fooinfotrigger.channel" expression="''">
<int:poller fixed-delay="5000"></int:poller>
</int:inbound-channel-adapter>
<int:channel id="fooinfo.channel">
<int:queue capacity="10"/>
</int:channel>
<int:channel id="fooinfotrigger.channel"></int:channel>
<int:chain input-channel="fooinfotrigger.channel" output-channel="fooinfo.channel">
<int:header-enricher>
<int:header name="Authorization" value="...." />
<int:header name="Content-Type" value="...." />
</int:header-enricher>
<int-http:outbound-gateway id="fooHttpGateway"
url="https://foo.com/v1/services/foo?status=active"
http-method="GET"
expected-response-type="java.lang.String"
charset="UTF-8"
reply-timeout="5000">
</int-http:outbound-gateway>
<int:transformer method="transform" ref="fooResourcesTransformer"/>
</int:chain>
<bean id="fooResourcesTransformer" class="com.foo.FooTransformer" />
是的同意你。当REST服务失败并出现401 Http状态错误时,它会正确重新触发,但当它以200 Http状态成功时,它不会重新触发。我在这个要点复制了类似的例子,它也有相同的问题https://gist.github.com/krishnaaravacadreon/3b22ff9a33c3fada2500d76789cee817 – user1044173
M-m-m。另一方面,该测试用例在第一个结果接收后才退出。所以,这是完全的事实,你可能只有一次民意测验。 –