Closed Mengyantong closed 4 months ago
The FlagTTL in go-zookeeper/zk is wrong. The CreateMode flag of PERSISTENT_WITH_TTL is 5 in zookeeper code while in the go-zookeeper/zk is 4. In this case, the Create is trying to create a Container instead of a persistent node with TTL.
I will push a PR to fix this.
I am facing an issue while attempting to create a TTL node. During the execution of the corresponding function, I consistently encounter an "invalid arguments" error. My parameters align with the function definition, yet the error persists. Could it be that I am using the function incorrectly? My code like:
res, err := conn.CreateTTL("/testpath", []byte("ttl node"), zk.FlagTTL, zk.WorldACL(zk.PermAll), time.Second)