Hi there,

I am using the PersistentEphemeralNode, and I have noticed that it is needed to 
make it work assure that the PersistentEphemeralNode instance started when the 
CuratorFramework is connected. Otherwise it looks that the recipee does not work

For instance this sequence is not working:

// ZK servers are not started here
ExponentialBackoffRetry retryPolicy = new ExponentialBackoffRetry(1000, 1, 
2000);
CuratorFramework zkClient = 
CuratorFrameworkFactory.newClient("127.0.0.1:30101", 

4500,
4500,
retryPolicy);
zkClient.start();
Thread.sleep(2000);

PersistentEphemeralNode pen = new PersistentEphemeralNode(zkClient, 
Mode.EPHEMERAL, "/abc/pen", "hello".getBytes());
Thread.sleep(2000);

// Start ZK servers here
Thread.sleep(2000);
// "/abc/pen" ephemeral node is not created

Is this a bug? Is it assumed that a connection listener should be used to start 
the PersistentEphemeralNode when the zkclient is connected?


Thanks in advance,

Evaristo

Reply via email to