You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@zookeeper.apache.org by "maoling (Jira)" <ji...@apache.org> on 2020/12/23 08:10:00 UTC

[jira] [Created] (ZOOKEEPER-4035) Add a documentation about the property: zookeeper.testingonly.initialZxid

maoling created ZOOKEEPER-4035:
----------------------------------

             Summary: Add a documentation about the property: zookeeper.testingonly.initialZxid
                 Key: ZOOKEEPER-4035
                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-4035
             Project: ZooKeeper
          Issue Type: Improvement
          Components: documentation
            Reporter: maoling


{code:java}
 * This field allows you to override the zxid of the server. Typically
 * you'll want to set it to something like 0xfffffff0 and then
 * start the quorum, run some operations and see the re-election.
 */
String initialZxid = System.getProperty("zookeeper.testingonly.initialZxid");
if (initialZxid != null) {
    long zxid = Long.parseLong(initialZxid);
    zk.setZxid((zk.getZxid() & 0xffffffff00000000L) | zxid);
}
{code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)