camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Meisner Larsen <>
Subject ZooKeeperPolicy not working in Camel 2.18.1 (?)
Date Mon, 30 Jan 2017 10:00:32 GMT
I would really appreciate if someone could help me get ZooKeeperRoutePolicy
working asexpected...

I have a zookeeper cluster with 3 servers and two karaf instances with the
following route installed:

                .routePolicy(new ZooKeeperRoutePolicy(zookeeperLock, 1))
                .log(LoggingLevel.INFO, logger, "Hello, World");

The value of zookeeperLock is,,

Here is my test scenario:

Install route on server A

 - I can see the log from server A

Install the route on server B

 - The route fails on server B because it didn't get the lock

Now I stopped the karaf instance on A, expecting B to start writing "Hello,
World" in the log

 - Nothing happens <====== WHY NOT?

Starting instance A again

 - The route fails because A couldn't get the lock

When expecting the zookeeper cluster, all servers looks as expected, the
lock contains two entries with the one from B first in list

I was expecting server B to get the lock and start the route when instance
A was shutdown. Since A could not get the lock I know that B got it, and
this was verified by looking into zookeeper.

But the route in B was never started, which leads me to the conclusion,
that ZookeepeRoutePolicy is not working (as I expected it to...)


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message