Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 402C2200C25 for ; Fri, 24 Feb 2017 23:43:05 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 3ED55160B69; Fri, 24 Feb 2017 22:43:05 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 8793A160B62 for ; Fri, 24 Feb 2017 23:43:04 +0100 (CET) Received: (qmail 16467 invoked by uid 500); 24 Feb 2017 22:43:03 -0000 Mailing-List: contact reviews-help@mesos.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: reviews@mesos.apache.org Delivered-To: mailing list reviews@mesos.apache.org Received: (qmail 16451 invoked by uid 99); 24 Feb 2017 22:43:03 -0000 Received: from reviews-vm.apache.org (HELO reviews.apache.org) (140.211.11.40) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 24 Feb 2017 22:43:03 +0000 Received: from reviews.apache.org (localhost [127.0.0.1]) by reviews.apache.org (Postfix) with ESMTP id 4662231B088; Fri, 24 Feb 2017 22:43:03 +0000 (UTC) Content-Type: multipart/alternative; boundary="===============8380728163224275235==" MIME-Version: 1.0 Subject: Re: Review Request 57032: Added allocation role validation for Create operation. From: Benjamin Mahler To: Benjamin Mahler Cc: Jay Guo , mesos Date: Fri, 24 Feb 2017 22:43:03 -0000 Message-ID: <20170224224303.13823.82138@reviews.apache.org> X-ReviewBoard-URL: https://reviews.apache.org/ Auto-Submitted: auto-generated Sender: Benjamin Mahler X-ReviewGroup: mesos X-Auto-Response-Suppress: DR, RN, OOF, AutoReply X-ReviewRequest-URL: https://reviews.apache.org/r/57032/ X-Sender: Benjamin Mahler X-ReviewBoard-ShipIt: 1 References: <20170224110540.1738.40107@reviews.apache.org> In-Reply-To: <20170224110540.1738.40107@reviews.apache.org> Reply-To: Benjamin Mahler X-ReviewRequest-Repository: mesos archived-at: Fri, 24 Feb 2017 22:43:05 -0000 --===============8380728163224275235== MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/57032/#review166766 ----------------------------------------------------------- Fix it, then Ship it! src/master/validation.cpp (lines 1797 - 1801) Let's check this only if there is a framework info. Also, as a follow up we could introduce the allocation info checking much like we did for the reserve operation. That is, ensure it's unallocated if there is no framework info. src/master/validation.cpp (line 1800) No need for putting this on a new line? src/tests/master_validation_tests.cpp (line 883) Should pass in the frameworkInfo here? - Benjamin Mahler On Feb. 24, 2017, 11:05 a.m., Jay Guo wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/57032/ > ----------------------------------------------------------- > > (Updated Feb. 24, 2017, 11:05 a.m.) > > > Review request for mesos and Benjamin Mahler. > > > Bugs: MESOS-6636 > https://issues.apache.org/jira/browse/MESOS-6636 > > > Repository: mesos > > > Description > ------- > > With support for multi-role frameworks, we need to make sure that > individual create operation cannot mix allocation roles. > > > Diffs > ----- > > src/master/validation.cpp b8c6b49ca5ca1f15e58a2967adc335436a35071f > src/tests/master_validation_tests.cpp 45254739e2a62fed7008ceada7a8f64bb9ee4e31 > > Diff: https://reviews.apache.org/r/57032/diff/ > > > Testing > ------- > > make check > > > Thanks, > > Jay Guo > > --===============8380728163224275235==--