From notifications-return-1523-archive-asf-public=cust-asf.ponee.io@zookeeper.apache.org Fri Aug 23 14:47:44 2019 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [207.244.88.153]) by mx-eu-01.ponee.io (Postfix) with SMTP id A1634180637 for ; Fri, 23 Aug 2019 16:47:44 +0200 (CEST) Received: (qmail 27293 invoked by uid 500); 23 Aug 2019 14:47:44 -0000 Mailing-List: contact notifications-help@zookeeper.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@zookeeper.apache.org Delivered-To: mailing list notifications@zookeeper.apache.org Received: (qmail 27282 invoked by uid 99); 23 Aug 2019 14:47:44 -0000 Received: from ec2-52-202-80-70.compute-1.amazonaws.com (HELO gitbox.apache.org) (52.202.80.70) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 23 Aug 2019 14:47:44 +0000 From: GitBox To: notifications@zookeeper.apache.org Subject: [GitHub] [zookeeper] symat commented on a change in pull request #1048: ZOOKEEPER-3188: Improve resilience to network Message-ID: <156657166400.18139.685647350175336721.gitbox@gitbox.apache.org> Date: Fri, 23 Aug 2019 14:47:44 -0000 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit symat commented on a change in pull request #1048: ZOOKEEPER-3188: Improve resilience to network URL: https://github.com/apache/zookeeper/pull/1048#discussion_r317167254 ########## File path: zookeeper-server/src/main/java/org/apache/zookeeper/server/ObserverBean.java ########## @@ -49,10 +50,11 @@ public String getQuorumAddress() { public String getLearnerMaster() { QuorumPeer.QuorumServer learnerMaster = observer.getCurrentLearnerMaster(); - if (learnerMaster == null || learnerMaster.addr == null) { + InetSocketAddress address = learnerMaster.addr.getReachableOrOne(); + if (learnerMaster == null || address == null) { Review comment: thanks, nice catch! (actually beside this, we also got a NoSuchElementException if learnerMaster.addr is empty) I will fix this in the next commit ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: users@infra.apache.org With regards, Apache Git Services