camel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Claus Ibsen <claus.ib...@gmail.com>
Subject Re: Master/Leader RoutePolicy deprecation/fix
Date Mon, 29 May 2017 14:57:55 GMT
Hi

Yeah the set auto startup=false seems like a good idea.

On Mon, May 29, 2017 at 4:44 PM, Luca Burgazzoli <lburgazzoli@gmail.com> wrote:
> Hello,
>
> I did a small review of the RoutePolicy we have for having one route
> master and one slave and all have an issue as they are invoked after
> the route is started so the consumer may have the time to consume some
> data before the policy kicks in [1].
>
> There is now a zookeeper-master component and some work is in in
> progress [2] in such area so wondering if we should deprecate such
> policies once [2] is done with or without fixing them.
>
> If we decide to fix them we could make the route to not auto start on
> policy initialization so then the policy could take care to start/stop
> the routes it is supposed to manage, an example of such behaviour can
> be see in my experimental branch [3] and in CuratorLeaderPolicy [4].
>
> Thoughts ?
>
> [1] https://github.com/apache/camel/blob/master/camel-core/src/main/java/org/apache/camel/impl/RouteService.java#L213-L232
> [2] https://issues.apache.org/jira/browse/CAMEL-10320
> [3] https://github.com/lburgazzoli/apache-camel/blob/route-policy/components/camel-infinispan/src/main/java/org/apache/camel/component/infinispan/policy/InfinispanRoutePolicy.java
> [4] https://github.com/apache/camel/blob/master/components/camel-zookeeper/src/main/java/org/apache/camel/component/zookeeper/policy/CuratorLeaderRoutePolicy.java
>
> ---
> Luca Burgazzoli



-- 
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2

Mime
View raw message