> On Nov. 23, 2014, 8:35 p.m., Neha Narkhede wrote: > > core/src/main/scala/kafka/utils/ZkUtils.scala, line 714 > > <https://reviews.apache.org/r/23702/diff/7/?file=771304#file771304line714> > > > > Why not use persistent sequential nodes instead?
if I used createPersistentSequential it keeps creating a new node in zk with a sequential number. It will leave too many nodes in zk depending on the number of brokers that the user run. Instead I used a zk path each time updating with a expected version as -1 and using returned stat.getVersion for the sequential number. - Sriharsha ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/23702/#review62737 ----------------------------------------------------------- On Nov. 26, 2014, 4:29 a.m., Sriharsha Chintalapani wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/23702/ > ----------------------------------------------------------- > > (Updated Nov. 26, 2014, 4:29 a.m.) > > > Review request for kafka. > > > Bugs: KAFKA-1070 > https://issues.apache.org/jira/browse/KAFKA-1070 > > > Repository: kafka > > > Description > ------- > > KAFKA-1070. Auto-assign node id. > > > Diffs > ----- > > core/src/main/scala/kafka/common/GenerateBrokerIdException.scala > PRE-CREATION > core/src/main/scala/kafka/common/InconsistentBrokerIdException.scala > PRE-CREATION > core/src/main/scala/kafka/server/BrokerMetadataFileHandler.scala > PRE-CREATION > core/src/main/scala/kafka/server/KafkaConfig.scala > 6e26c5436feb4629d17f199011f3ebb674aa767f > core/src/main/scala/kafka/server/KafkaServer.scala > 1bf7d10cef23a77e716666eb16bf6d0e68bc4ebe > core/src/main/scala/kafka/utils/ZkUtils.scala > 56e3e88e0cc6d917b0ffd1254e173295c1c4aabd > core/src/test/scala/unit/kafka/server/ServerGenerateBrokerIdTest.scala > PRE-CREATION > core/src/test/scala/unit/kafka/utils/TestUtils.scala > 0da774d0ed015bdc0461b854e3540ee6e48d1838 > > Diff: https://reviews.apache.org/r/23702/diff/ > > > Testing > ------- > > > Thanks, > > Sriharsha Chintalapani > >