From reviews-return-90442-apmail-mesos-reviews-archive=mesos.apache.org@mesos.apache.org Fri Nov 22 18:16:26 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 [207.244.88.153]) by minotaur.apache.org (Postfix) with SMTP id 2384F19BBE for ; Fri, 22 Nov 2019 18:16:26 +0000 (UTC) Received: (qmail 52495 invoked by uid 500); 22 Nov 2019 18:16:25 -0000 Delivered-To: apmail-mesos-reviews-archive@mesos.apache.org Received: (qmail 52482 invoked by uid 500); 22 Nov 2019 18:16:25 -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 52458 invoked by uid 99); 22 Nov 2019 18:16:25 -0000 Received: from mailrelay1-us-west.apache.org (HELO mailrelay1-us-west.apache.org) (209.188.14.139) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 22 Nov 2019 18:16:25 +0000 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 6BB92E0F34; Fri, 22 Nov 2019 18:16:24 +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 300BCC40061; Fri, 22 Nov 2019 18:16:24 +0000 (UTC) Content-Type: multipart/alternative; boundary="===============5102048534734942390==" MIME-Version: 1.0 Subject: Re: Review Request 71748: Support jsonifying v0 protobuf to v1 protobuf. From: Benjamin Mahler To: Meng Zhu , Andrei Sekretenko , Greg Mann Cc: Benjamin Mahler , mesos Date: Fri, 22 Nov 2019 18:16:23 -0000 Message-ID: <20191122181623.60074.37053@reviews-vm2.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/71748/ X-Sender: Benjamin Mahler References: <20191111235941.61125.90860@reviews-vm2.apache.org> In-Reply-To: <20191111235941.61125.90860@reviews-vm2.apache.org> Reply-To: Benjamin Mahler X-ReviewRequest-Repository: mesos --===============5102048534734942390== 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/71748/ ----------------------------------------------------------- (Updated Nov. 22, 2019, 6:16 p.m.) Review request for mesos, Andrei Sekretenko, Greg Mann, and Meng Zhu. Changes ------- Split out the lower and upper cases. Bugs: MESOS-10026 https://issues.apache.org/jira/browse/MESOS-10026 Repository: mesos Description ------- This allows us to jsonify a v0 protobuf directly to a v1 protobuf efficiently, with no need to `evolve()` the message (which is rather expensive). The way this works is by converting all "slave" and "SLAVE" strings in fields and enum values, respectively, to "agent" and "AGENT". Our current v0 to v1 conversion for the v1 operator API simply serializes the v0 message and de-serializes into a v1 message, which means all field tags and message structures are the same, except for field names. The only difference with field names is the use of "agent" in place of "slave". Diffs (updated) ----- src/common/http.hpp 062586c0a5a339c7e63c89a3a893ae015d3fd26e src/common/http.cpp b79074f823d3bce2a15736c0ef4739ad13db8d9c Diff: https://reviews.apache.org/r/71748/diff/2/ Changes: https://reviews.apache.org/r/71748/diff/1-2/ Testing ------- Added a test in the subsequent patch. Thanks, Benjamin Mahler --===============5102048534734942390==--