You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by "Vadim Chekan (JIRA)" <ji...@apache.org> on 2008/11/04 05:27:05 UTC

[jira] Commented: (CAMEL-1048) allow routes to easily be enabled/disabled based on an external predicate such as queue size

    [ https://issues.apache.org/activemq/browse/CAMEL-1048?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=47035#action_47035 ] 

Vadim Chekan commented on CAMEL-1048:
-------------------------------------

Another use-case: listen to a control queue and start/stop route:
{code}
from control_queue
case when xpath "/headers/message_type"='"stop"
   el: ${routes["route_a"].stop}
case when xpath "/headers/message_type"='"start"
   el: ${routes["route_a"].start}
{code}

> allow routes to easily be enabled/disabled based on an external predicate such as queue size
> --------------------------------------------------------------------------------------------
>
>                 Key: CAMEL-1048
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-1048
>             Project: Apache Camel
>          Issue Type: New Feature
>            Reporter: James Strachan
>             Fix For: 2.0.0
>
>
> For example we may want to do this route...
> {code}
> <route>
>   <requires>
>     <el>${broker2.queueSize('AnotherQueue') == 0}</el>
>   </requires>
>   <from uri="broker1:MyQueue"/>
>   <to uri="broker2:AnotherQueue"/>
> </route>
> {code}
> i.e. only implement a specific route while some predicate is true (e.g. only route while a condition is met; disable when its not met).
> Maybe we need to allow endpoints to define if they are ready yet? e.g. only send to a certain queue if its got capacity?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.