bind() could fail on Leader because it does not setReuseAddress on its 
ServerSocket 
------------------------------------------------------------------------------------

                 Key: ZOOKEEPER-973
                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-973
             Project: ZooKeeper
          Issue Type: Bug
          Components: server
    Affects Versions: 3.3.2
            Reporter: Vishal K
            Priority: Trivial
             Fix For: 3.3.3


setReuseAddress(true) should be used below.

    Leader(QuorumPeer self,LeaderZooKeeperServer zk) throws IOException {
        this.self = self;
        try {
            ss = new ServerSocket(self.getQuorumAddress().getPort());
        } catch (BindException e) {
            LOG.error("Couldn't bind to port "
                    + self.getQuorumAddress().getPort(), e);
            throw e;
        }
        this.zk=zk;
    }



-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to