You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Sanigo (JIRA)" <ji...@apache.org> on 2016/04/13 10:27:25 UTC
[jira] [Comment Edited] (CAMEL-9863) loopDoWhile will loop forever
if using ahc component in the loop.
[ https://issues.apache.org/jira/browse/CAMEL-9863?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15238835#comment-15238835 ]
Sanigo edited comment on CAMEL-9863 at 4/13/16 8:26 AM:
--------------------------------------------------------
A sample test route is provided now.
was (Author: sanigo@gmail.com):
A samle test route is provided now.
> loopDoWhile will loop forever if using ahc component in the loop.
> -----------------------------------------------------------------
>
> Key: CAMEL-9863
> URL: https://issues.apache.org/jira/browse/CAMEL-9863
> Project: Camel
> Issue Type: Bug
> Components: camel-core
> Affects Versions: 2.17.0
> Reporter: Sanigo
> Priority: Minor
>
> I have tested several times. The loop condition will not be checked if ahc component is in the loop.
> from("quartz2://jf-log/trigger3?trigger.repeatInterval=2&trigger.repeatCount=0")
> .loopDoWhile(body().isNotEqualTo("done"))
> .setHeader(Exchange.HTTP_METHOD, constant("GET"))
> .to("ahc:https://www.baidu.com/")
> .choice()
> .when(exchangeProperty("CamelLoopIndex").isEqualTo(3))
> .setBody(constant("done"))
> .endChoice()
> .end()
> .end()
> .to("mock:result");
> The loop will be infinite, the workarround is to use http component instead of ahc.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)