----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/48894/ -----------------------------------------------------------
(Updated June 21, 2016, 12:24 a.m.) Review request for Ambari, Alejandro Fernandez and Sumit Mohanty. Changes ------- - Set default value for 'hive.llap.daemon.yarn.container.mb'. - Fixed RAT build issue, by putting .txt files in ignore list. Bugs: AMBARI-17306 https://issues.apache.org/jira/browse/AMBARI-17306 Repository: ambari Description ------- Background: ========== 'llapstatus' command is use to fgure out the current running state of llap app. ISSUE: ===== Example of expected response from 'llapstatus' command which can be JSON parsed: CASE A: =============================== =============================== { "amInfo" : { "appName" : "llap0", "appType" : "org-apache-slider", "appId" : "application_1466036628595_0010", "containerId" : "container_1466036628595_0010_01_000001", "hostname" : "hostname", "amWebUrl" : "http://hostname:60865/" }, "state" : "LAUNCHING", "originalConfigurationPath" : "hdfs://hostname:8020/user/hive/.slider/cluster/llap0/snapshot", "generatedConfigurationPath" : "hdfs://hostname:8020/user/hive/.slider/cluster/llap0/generated", "desiredInstances" : 1, "liveInstances" : 0, "appStartTime" : 1466123287309 } =============================== The same output with MOTD message (Can't be JSON parsed directly): =============================== This is MOTD message This is MOTD message1 { "amInfo" : { "appName" : "llap0", "appType" : "org-apache-slider", "appId" : "application_1466036628595_0010", "containerId" : "container_1466036628595_0010_01_000001", "hostname" : "hostname", "amWebUrl" : "http://hostname:60865/" }, "state" : "LAUNCHING", "originalConfigurationPath" : "hdfs://hostname:8020/user/hive/.slider/cluster/llap0/snapshot", "generatedConfigurationPath" : "hdfs://hostname:8020/user/hive/.slider/cluster/llap0/generated", "desiredInstances" : 1, "liveInstances" : 0, "appStartTime" : 1466123287309 } =============================== Other scenario can be (eg: APP_NOTFOUND): CASE B: ====== =============================== This is MOTD message This is MOTD message1 { "state" : "APP_NOT_FOUND" } =============================== We need to filter out extra lines initially added by MOTD, on top of JSON parseable string. RESOLUTION: ========== So, for CASE A, check for filtering is as follows : - the current line to be : "{", and - next line to be *""amInfo" : {"* - And last line to be *"}"* OR == for CASE B, check for filtering is as follows: - the current line to be : *" {"*, and - next line to be *"state" :* - And next to next line to be *"}"* and line is the last one. To figure out the start of JSON output. So, the lines above it will be removed, to make the output JSOn parseable. - Alos, fixes the issue of some users not having access to '/home/hive' for accessing the LLAP package created. Now, package would be created in tmp location provided by : Script.get_tmp_dir() (Generally, /var/lib/ambari-agent/tmp) ==================== Diffs (updated) ----- ambari-server/pom.xml d1696ae ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/alerts/alert_llap_app_status.py d65322d ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive_server_interactive.py c055cf1 ambari-server/src/main/resources/stacks/HDP/2.5/services/HIVE/configuration/hive-interactive-site.xml 9c7e865 ambari-server/src/test/python/stacks/2.5/HIVE/appComplete_withMOTDmsg.txt PRE-CREATION ambari-server/src/test/python/stacks/2.5/HIVE/invalidApp_withMOTDmsg.txt PRE-CREATION ambari-server/src/test/python/stacks/2.5/HIVE/oneContainerDown_withMOTDmsg.txt PRE-CREATION ambari-server/src/test/python/stacks/2.5/HIVE/running_withMOTDmsg.txt PRE-CREATION ambari-server/src/test/python/stacks/2.5/HIVE/starting_withMOTDmsg.txt PRE-CREATION ambari-server/src/test/python/stacks/2.5/HIVE/test_hive_server_int.py 348a17d Diff: https://reviews.apache.org/r/48894/diff/ Testing ------- Python UT added. - Python UT passes. Thanks, Swapan Shridhar