0

I am new to zookeeper programming. I am trying to implement produce consumer queue using zookeeper.I am getting exception while initializing queue. In my zookeeper only root entry is there which is [zookeeper].

I am trying to execute code given at. http://zookeeper.apache.org/doc/r3.3.3/zookeeperTutorial.html#sc_producerConsumerQueues (Not pasting code here to keep post clean)

Exception:

org.apache.zookeeper.KeeperException$NoNodeException: KeeperErrorCode = NoNode for /app1
at org.apache.zookeeper.KeeperException.create(KeeperException.java:111)
at org.apache.zookeeper.KeeperException.create(KeeperException.java:51)
at org.apache.zookeeper.ZooKeeper.create(ZooKeeper.java:783)
at Queue.<init>(Queue.java:27)
at Queue.main(Queue.java:90)

Can any one advice me on  this?


Thanks
Kapil
  • 193
  • 2
  • 14

1 Answers1

0

You trying create child node (for ex. "/root/child") when parent node ("/root") does not exists, not created. Check that parent node is created.

pasha701
  • 6,831
  • 1
  • 15
  • 22