From reviews-return-85967-apmail-mesos-reviews-archive=mesos.apache.org@mesos.apache.org Wed Mar 6 02:29:14 2019 Return-Path: X-Original-To: apmail-mesos-reviews-archive@minotaur.apache.org Delivered-To: apmail-mesos-reviews-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id B658018C00 for ; Wed, 6 Mar 2019 02:29:14 +0000 (UTC) Received: (qmail 82247 invoked by uid 500); 6 Mar 2019 02:29:14 -0000 Delivered-To: apmail-mesos-reviews-archive@mesos.apache.org Received: (qmail 82216 invoked by uid 500); 6 Mar 2019 02:29:14 -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 82205 invoked by uid 99); 6 Mar 2019 02:29:13 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 06 Mar 2019 02:29:13 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id 53C7CC042A; Wed, 6 Mar 2019 02:29:13 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 0.952 X-Spam-Level: X-Spam-Status: No, score=0.952 tagged_above=-999 required=6.31 tests=[HEADER_FROM_DIFFERENT_DOMAINS=0.001, HTML_MESSAGE=2, KAM_LAZY_DOMAIN_SECURITY=1, KAM_LOTSOFHASH=0.25, RCVD_IN_DNSWL_MED=-2.3, URIBL_BLOCKED=0.001] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id l7nCje3Ful_2; Wed, 6 Mar 2019 02:29:11 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id 18EFA5F1EE; Wed, 6 Mar 2019 02:29:10 +0000 (UTC) Received: from reviews.apache.org (unknown [10.41.0.12]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 4370AE092E; Wed, 6 Mar 2019 02:29:09 +0000 (UTC) Received: from reviews-vm2.apache.org (localhost [IPv6:::1]) by reviews.apache.org (ASF Mail Server at reviews-vm2.apache.org) with ESMTP id 26822C4027D; Wed, 6 Mar 2019 02:29:09 +0000 (UTC) Content-Type: multipart/alternative; boundary="===============1821103617194209057==" MIME-Version: 1.0 Subject: Re: Review Request 70132: Do not implicitly refuse speculatively converted resources. From: Meng Zhu To: Meng Zhu , Benjamin Mahler Cc: Chun-Hung Hsiao , mesos Date: Wed, 06 Mar 2019 02:29:09 -0000 Message-ID: <20190306022909.23706.40237@reviews-vm2.apache.org> X-ReviewBoard-URL: https://reviews.apache.org/ Auto-Submitted: auto-generated Sender: Meng Zhu X-ReviewGroup: mesos X-Auto-Response-Suppress: DR, RN, OOF, AutoReply X-ReviewRequest-URL: https://reviews.apache.org/r/70132/ X-Sender: Meng Zhu References: <20190306005358.50225.72753@reviews-vm2.apache.org> In-Reply-To: <20190306005358.50225.72753@reviews-vm2.apache.org> Reply-To: Meng Zhu X-ReviewRequest-Repository: mesos --===============1821103617194209057== 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/70132/#review213453 ----------------------------------------------------------- src/master/master.cpp Lines 5918-5920 (patched) Not sure what value the comment has. Maybe you want to express its dependency on certain `Resources` subtraction semantics such as dropping negatives? Is so, either spit that out or I think you can just remove the comment. src/master/master.cpp Lines 5920 (patched) how about just name it `updatedResources` which is easier to grasp. In this particular context, it's just the diff after the operation update (as opppose to "unused" below) whether it is speculative or not does not matter. src/master/master.cpp Lines 5921-5928 (original), 5928-5937 (patched) hmm, I wonder if it is better to also not implicitly filter `unusedResources` if `speculativeResources` is not empty. If a framework wants to consume the updated resources e.g. volume, it probably also wants other resources such as cpu/mem (unless it can consume disk only resource). In that case, the above code would not improve the situation because the framework still needs to wait for the filtered cpu/mem. Also I am a little uncomfortable that, we now have *two* recoverResources calls which could increase agent resource fragmentation (if an offer is sent out in between). what do you think? - Meng Zhu On March 5, 2019, 4:53 p.m., Chun-Hung Hsiao wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/70132/ > ----------------------------------------------------------- > > (Updated March 5, 2019, 4:53 p.m.) > > > Review request for mesos, Benjamin Mahler and Meng Zhu. > > > Bugs: MESOS-9616 > https://issues.apache.org/jira/browse/MESOS-9616 > > > Repository: mesos > > > Description > ------- > > Currently if a framework accepts an offer to perform pipelined > operations, e.g., reserving resource, without a final consumer, the > converted resources will be implicitly refused. This is an undesired > behavior as the framework might want to reserve one resource first but > launch a task later in the next allocation cycle. This patch fixes this > behavior. > > But, if the framework accepts an offers with multiple operations that > cancel out each other, the resources consumed by these operations are > still considered unused and will be refused. > > > Diffs > ----- > > docs/scheduler-http-api.md 8384336bbecf2ca38a3cd203f9db28d931812d65 > src/master/master.cpp 015da54583448a8d102d8e401e48bd228baf6dd6 > src/tests/slave_tests.cpp 22a0295086ae4f4ec26df00a0e077eecfa27f1fb > > > Diff: https://reviews.apache.org/r/70132/diff/1/ > > > Testing > ------- > > make check > > > Thanks, > > Chun-Hung Hsiao > > --===============1821103617194209057==--