Return-Path: X-Original-To: apmail-incubator-mesos-dev-archive@minotaur.apache.org Delivered-To: apmail-incubator-mesos-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id ECB48955F for ; Mon, 18 Jun 2012 20:54:40 +0000 (UTC) Received: (qmail 88174 invoked by uid 500); 18 Jun 2012 20:54:40 -0000 Delivered-To: apmail-incubator-mesos-dev-archive@incubator.apache.org Received: (qmail 88131 invoked by uid 500); 18 Jun 2012 20:54:40 -0000 Mailing-List: contact mesos-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: mesos-dev@incubator.apache.org Delivered-To: mailing list mesos-dev@incubator.apache.org Received: (qmail 88118 invoked by uid 99); 18 Jun 2012 20:54:40 -0000 Received: from reviews-vm.apache.org (HELO reviews.apache.org) (140.211.11.40) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 18 Jun 2012 20:54:40 +0000 Received: from reviews.apache.org (localhost [127.0.0.1]) by reviews.apache.org (Postfix) with ESMTP id 3BE6E1C0839; Mon, 18 Jun 2012 20:54:40 +0000 (UTC) Content-Type: multipart/alternative; boundary="===============2450580988252810409==" MIME-Version: 1.0 Subject: Re: Review Request: Add whitelist slaves option to master From: "Benjamin Hindman" To: "Benjamin Hindman" Cc: "Vinod Kone" , "mesos" Date: Mon, 18 Jun 2012 20:54:40 -0000 Message-ID: <20120618205440.28904.47002@reviews.apache.org> X-ReviewBoard-URL: https://reviews.apache.org Auto-Submitted: auto-generated Sender: "Benjamin Hindman" X-ReviewGroup: mesos X-ReviewRequest-URL: https://reviews.apache.org/r/5396/ X-Sender: "Benjamin Hindman" References: <20120618185305.28905.46388@reviews.apache.org> In-Reply-To: <20120618185305.28905.46388@reviews.apache.org> Reply-To: "Benjamin Hindman" --===============2450580988252810409== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/5396/#review8352 ----------------------------------------------------------- src/master/master.hpp Code related to allocations is being moved into the allocator. Putting = the whitelist (and related constructs) in the master is creating more work = for the people that are working on that! src/master/master.cpp Newline before comment please. src/master/master.cpp These seem like esoteric semantics. You should use Option> for the type of whitelist instead. Having "no" whitelist (i.e., whiteli= st.isNone()) seems better than checking for whitelist.contains("*"). src/master/master.cpp Wrap line please. You can put the first '<<' on a newline. src/master/master.cpp Use strlen here please. Also, fix spaces around '-'. src/master/master.cpp Please put this on the previous line. src/master/master.cpp const & src/master/master.cpp Indentation looks wrong. Also, you use 'whitelist', 'white list' and no= w 'white-list'. Please pick one and be consistent (my vote is for 'whitelis= t'). src/master/master.cpp If you don't support this yet, please don't mislead users. src/master/master.cpp What about slaves that were previously on the whitelist but are not any= longer? This seems to be the crux condition of a dynamic whitelist. src/master/master.cpp Right, this is where it seems nicer to just do: if (whitelist.isSome() = && whitelist.contains(slave->info.hostname()) { src/tests/master_tests.cpp Newline please. src/tests/master_tests.cpp Why not const? src/tests/master_tests.cpp I'd like it if we didn't introduce possible assertion violations in our= tests. src/tests/master_tests.cpp Spaces. - Benjamin Hindman On June 18, 2012, 6:53 p.m., Vinod Kone wrote: > = > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/5396/ > ----------------------------------------------------------- > = > (Updated June 18, 2012, 6:53 p.m.) > = > = > Review request for mesos and Benjamin Hindman. > = > = > Description > ------- > = > Adds the ability to startup a master with a list of whitelisted slaves to= send offers for. > = > = > This addresses bug mesos-208. > https://issues.apache.org/jira/browse/mesos-208 > = > = > Diffs > ----- > = > src/master/constants.hpp c3b0b25 = > src/master/master.hpp 886f79c = > src/master/master.cpp 89cdaf6 = > src/master/simple_allocator.cpp 1c54feb = > src/tests/master_tests.cpp fcaf7dc = > src/tests/utils_tests.cpp 0e3374e = > = > Diff: https://reviews.apache.org/r/5396/diff/ > = > = > Testing > ------- > = > make check > = > = > Thanks, > = > Vinod Kone > = > --===============2450580988252810409==--