From mapreduce-dev-return-8411-apmail-hadoop-mapreduce-dev-archive=hadoop.apache.org@hadoop.apache.org Wed Oct 10 04:12:34 2012 Return-Path: X-Original-To: apmail-hadoop-mapreduce-dev-archive@minotaur.apache.org Delivered-To: apmail-hadoop-mapreduce-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 B80ACDB19 for ; Wed, 10 Oct 2012 04:12:34 +0000 (UTC) Received: (qmail 87237 invoked by uid 500); 10 Oct 2012 04:12:34 -0000 Delivered-To: apmail-hadoop-mapreduce-dev-archive@hadoop.apache.org Received: (qmail 86753 invoked by uid 500); 10 Oct 2012 04:12:27 -0000 Mailing-List: contact mapreduce-dev-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: mapreduce-dev@hadoop.apache.org Delivered-To: mailing list mapreduce-dev@hadoop.apache.org Received: (qmail 86701 invoked by uid 99); 10 Oct 2012 04:12:25 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 10 Oct 2012 04:12:25 +0000 X-ASF-Spam-Status: No, hits=-0.7 required=5.0 tests=RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of saptarshi.guha@gmail.com designates 209.85.220.176 as permitted sender) Received: from [209.85.220.176] (HELO mail-vc0-f176.google.com) (209.85.220.176) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 10 Oct 2012 04:12:19 +0000 Received: by mail-vc0-f176.google.com with SMTP id gb22so201488vcb.35 for ; Tue, 09 Oct 2012 21:11:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:reply-to:from:date:message-id:subject:to:content-type; bh=4oYHHgXCjVHDalM5Qx5Gm4GepmuA5Yn3mIY89hmN9WQ=; b=v/wfXrfuKuq9L9CYmQp9OjZCq3yEo5ShDp0ZpJUhv949UpDrboPfW5sib9AYyKKshI Os0TRB8TPqZ2dOFls3Q2T5ZT58a8Zi+blSJYU4jhpiHJnz7cL5ikIeukQbqhvnGuWkeF XFoG3VYsKy1y8Xj+CtxZfoFRKziyL0fZ+0VIMtCYXTH+fTGhQiRK/3DUilmArxPueFon IUMWAab5maHdKkoj9ovJtkK3OkIyN+x0kKr99u1is5nxsjGUiYILWD8BTl6KuoI5aVV3 ctxyEYkCIWuJ/jvbILIbGZ9OwMpZyzFHB+nBdzQTMw36UM9ca72uQRoCazQDzgf2HSlN 4elA== Received: by 10.52.23.199 with SMTP id o7mr10645633vdf.129.1349842318281; Tue, 09 Oct 2012 21:11:58 -0700 (PDT) MIME-Version: 1.0 Received: by 10.220.14.40 with HTTP; Tue, 9 Oct 2012 21:11:38 -0700 (PDT) Reply-To: saptarshi.guha@gmail.com From: Saptarshi Guha Date: Tue, 9 Oct 2012 21:11:38 -0700 Message-ID: Subject: API Design: getClusterMetrics To: mapreduce-dev@hadoop.apache.org Content-Type: text/plain; charset=UTF-8 X-Virus-Checked: Checked by ClamAV on apache.org Hello (sorry for cross post) I am reading the DistributedShell code and came across GetClusterMetricsRequest clusterMetricsReq = Records.newRecord(GetClusterMetricsRequest.class); GetClusterMetricsResponse clusterMetricsResp = applicationsManager.getClusterMetrics(clusterMetricsReq); In the page: http://hadoop.apache.org/docs/current/api/org/apache/hadoop/yarn/api/ClientRMProtocol.html#getClusterMetrics%28org.apache.hadoop.yarn.api.protocolrecords.GetClusterMetricsRequest%29 I can't find any other function getClusterMetrics. Why was the choice made to pass a GetClusterMetricsRequest object to getClusterMetrics? why couldn't the programmer invoke applicationsManager.getClusterMetrics() and the method would reply with a GetClusterMetricsResponse? Regards Sapsi (P.S I havent used YARN or even written code with it, i'm just reading some sources and my reading is incomplete, so apologies if this comes across as stupid)