Return-Path: X-Original-To: apmail-ambari-dev-archive@www.apache.org Delivered-To: apmail-ambari-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 5C1FE11AFE for ; Fri, 6 Jun 2014 14:30:04 +0000 (UTC) Received: (qmail 42226 invoked by uid 500); 6 Jun 2014 14:30:04 -0000 Delivered-To: apmail-ambari-dev-archive@ambari.apache.org Received: (qmail 42200 invoked by uid 500); 6 Jun 2014 14:30:04 -0000 Mailing-List: contact dev-help@ambari.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@ambari.apache.org Delivered-To: mailing list dev@ambari.apache.org Received: (qmail 42183 invoked by uid 99); 6 Jun 2014 14:30:04 -0000 Received: from reviews-vm.apache.org (HELO reviews.apache.org) (140.211.11.40) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 06 Jun 2014 14:30:04 +0000 Received: from reviews.apache.org (localhost [127.0.0.1]) by reviews.apache.org (Postfix) with ESMTP id 0F3091D7964; Fri, 6 Jun 2014 14:29:55 +0000 (UTC) Content-Type: multipart/alternative; boundary="===============3492588631590805145==" MIME-Version: 1.0 Subject: Re: Review Request 22271: ZK should not be required to be restarted after adding a host From: "Jonathan Hurley" To: "Mahadev Konar" , "Dmytro Sen" , "Jonathan Hurley" Cc: "Ambari" , "Florian Barca" Date: Fri, 06 Jun 2014 14:29:55 -0000 Message-ID: <20140606142955.10017.17184@reviews.apache.org> X-ReviewBoard-URL: https://reviews.apache.org Auto-Submitted: auto-generated Sender: "Jonathan Hurley" X-ReviewGroup: Ambari X-ReviewRequest-URL: https://reviews.apache.org/r/22271/ X-Sender: "Jonathan Hurley" References: <20140605174411.12450.96564@reviews.apache.org> In-Reply-To: <20140605174411.12450.96564@reviews.apache.org> Reply-To: "Jonathan Hurley" X-ReviewRequest-Repository: ambari --===============3492588631590805145== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/22271/#review44895 ----------------------------------------------------------- ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java I don't think that this if-statement matches your comment. If you add host components to an existing host in the cluster, then for ZooKeeper, the host component map will contain hostName. This statement will pass when deleting a host and when adding new components to an existing host. Is this the side-effect you wanted? I still seems that ZooKeeper is indicating a restart in this case. ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java Any reason you removed logging? ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java This method only acts on YARN/NODEMANAGER, yet it doesn't indicate that in the method name or the comments. Also, you're hard coding service/component names and a DECOMISSION request; seems like this method is very specific to a remove host component request. - Jonathan Hurley On June 5, 2014, 1:44 p.m., Florian Barca wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/22271/ > ----------------------------------------------------------- > > (Updated June 5, 2014, 1:44 p.m.) > > > Review request for Ambari, Dmytro Sen, Jonathan Hurley, and Mahadev Konar. > > > Bugs: AMBARI-6039 > https://issues.apache.org/jira/browse/AMBARI-6039 > > > Repository: ambari > > > Description > ------- > > Added a filtering layer by host name. When adding a host, this is the new host name, which is not yet available in the configuration, so the filtering avoids setting the stale flag on the applicable services. > > Remarks: > - The code gets called whenever we add a host, including at cluster setup time. Didn't notice a change in behavior though. > - The code is trying to cover all the possible situations with one general approach. There is a potential for future bugs due to new services' potentially different behavior. > > > Diffs > ----- > > ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java 1297f6c > ambari-server/src/test/java/org/apache/ambari/server/controller/AmbariManagementControllerTest.java 8fbf207 > > Diff: https://reviews.apache.org/r/22271/diff/ > > > Testing > ------- > > Unit test code added in the existing test case. Also, ran the end-to-end test on the local cluster and confirmed that the ZK service does not appear stale after adding a host to the existing configuration. > > > Thanks, > > Florian Barca > > --===============3492588631590805145==--