Return-Path: X-Original-To: apmail-ambari-dev-archive@www.apache.org Delivered-To: apmail-ambari-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 3B57411233 for ; Thu, 26 Jun 2014 13:11:18 +0000 (UTC) Received: (qmail 5031 invoked by uid 500); 26 Jun 2014 13:11:18 -0000 Delivered-To: apmail-ambari-dev-archive@ambari.apache.org Received: (qmail 5001 invoked by uid 500); 26 Jun 2014 13:11:18 -0000 Mailing-List: contact dev-help@ambari.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@ambari.apache.org Delivered-To: mailing list dev@ambari.apache.org Received: (qmail 4984 invoked by uid 99); 26 Jun 2014 13:11:17 -0000 Received: from reviews-vm.apache.org (HELO reviews.apache.org) (140.211.11.40) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 26 Jun 2014 13:11:17 +0000 Received: from reviews.apache.org (localhost [127.0.0.1]) by reviews.apache.org (Postfix) with ESMTP id 1CC891DB3A1; Thu, 26 Jun 2014 13:11:07 +0000 (UTC) Content-Type: multipart/alternative; boundary="===============5316376061719898619==" MIME-Version: 1.0 Subject: Review Request 23011: Get rid of using macros as enviroment variables for nagios From: "Andrew Onischuk" To: "Dmitro Lisnichenko" Cc: "Andrew Onischuk" , "Ambari" Date: Thu, 26 Jun 2014 13:11:07 -0000 Message-ID: <20140626131107.22596.79520@reviews.apache.org> X-ReviewBoard-URL: https://reviews.apache.org Auto-Submitted: auto-generated Sender: "Andrew Onischuk" X-ReviewGroup: Ambari X-ReviewRequest-URL: https://reviews.apache.org/r/23011/ X-Sender: "Andrew Onischuk" Reply-To: "Andrew Onischuk" X-ReviewRequest-Repository: ambari --===============5316376061719898619== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/23011/ ----------------------------------------------------------- Review request for Ambari and Dmitro Lisnichenko. Bugs: AMBARI-6286 https://issues.apache.org/jira/browse/AMBARI-6286 Repository: ambari Description ------- Macros are normally made available to check, notification, event handler, etc. commands as environment variables. This can be a problem in a large Nagios installation, as it consumes some additional memory and (more importantly) more CPU. If your scripts don't need to access the macros as environment variables (e.g. you pass all necessary macros on the command line), you don't need this feature. You can prevent macros from being made available as environment variables by using the enable_environment_macros option. we have 3 enviroment macros used in check_wrapper.sh, and some in other scripts, we can excplicetely set them to env by editting hadoop-commands.cfg Benefit: we can stop using expensive enable_environment_macros, and have alerts working on large cluster. Diffs ----- ambari-server/src/main/resources/stacks/HDP/1.3.2/services/NAGIOS/package/scripts/params.py ac955cd ambari-server/src/main/resources/stacks/HDP/1.3.2/services/NAGIOS/package/templates/hadoop-commands.cfg.j2 fe7495f ambari-server/src/main/resources/stacks/HDP/1.3.2/services/NAGIOS/package/templates/nagios.cfg.j2 05d94b5 ambari-server/src/main/resources/stacks/HDP/2.0.6/services/NAGIOS/package/scripts/params.py 8fcdd14 ambari-server/src/main/resources/stacks/HDP/2.0.6/services/NAGIOS/package/templates/hadoop-commands.cfg.j2 fa38a06 ambari-server/src/main/resources/stacks/HDP/2.0.6/services/NAGIOS/package/templates/nagios.cfg.j2 528ddc2 Diff: https://reviews.apache.org/r/23011/diff/ Testing ------- mvn clean test Thanks, Andrew Onischuk --===============5316376061719898619==--