Browse Source

AMBARI-2093. Add Tez as a configurable Service in Hadoop 2.0 stack. (swagle)

git-svn-id: https://svn.apache.org/repos/asf/incubator/ambari/trunk@1480137 13f79535-47bb-0310-9956-ffa450edef68
Siddharth Wagle 12 years ago
parent
commit
aa934afb2a

+ 2 - 0
CHANGES.txt

@@ -12,6 +12,8 @@ Trunk (unreleased changes):
 
  NEW FEATURES
 
+ AMBARI-2093. Add Tez as a configurable Service in Hadoop 2.0 stack. (swagle)
+
  AMBARI-2031. AMBARI-2031. Add clover code coverage profile. 
  (Giridharan Kesavan via swagle)
 

+ 24 - 0
ambari-agent/src/main/puppet/modules/hdp-tez/manifests/init.pp

@@ -0,0 +1,24 @@
+#
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+#
+
+class hdp-tez::initialize()
+{
+}

+ 40 - 0
ambari-agent/src/main/puppet/modules/hdp-tez/manifests/tez_client.pp

@@ -0,0 +1,40 @@
+#
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+#
+class hdp-tez::tez_client(
+  $service_state = $hdp::params::cluster_service_state,
+  $opts = {}
+)
+{
+  if ($service_state == 'no_op') {
+  } elsif ($service_state in 'installed_and_configured') {
+
+    include hdp-tez::initialize
+
+    $package_name = 'tez_client'
+
+    hdp::package{ $package_name :
+      ensure       => present,
+      package_type => $package_name
+    }
+  } else {
+    hdp_fail("TODO not implemented yet: service_state = ${service_state}")
+  }
+}

+ 8 - 0
ambari-agent/src/main/puppet/modules/hdp/manifests/params.pp

@@ -444,6 +444,14 @@ class hdp::params()
       }
     },
 
+    tez_client => { 
+      'ALL' => {
+        64 => {
+          'ALL' => ['tez']
+        }
+      }
+    },
+
     lzo => {
       'ALL' => {
         'ALL' => {

+ 2 - 1
ambari-agent/src/main/python/ambari_agent/AmbariConfig.py

@@ -124,7 +124,8 @@ rolesToClass = {
   'DASHBOARD_SERVICE_CHECK': 'hdp-dashboard::dashboard::service_check',
   'DECOMMISSION_DATANODE': 'hdp-hadoop::hdfs::decommission',
   'HUE_SERVICE_CHECK': 'hdp-hue::service_check',
-  'RESOURCEMANAGER_SERVICE_CHECK': 'hdp-yarn::resourcemanager::service_check'
+  'RESOURCEMANAGER_SERVICE_CHECK': 'hdp-yarn::resourcemanager::service_check',
+  'TEZ_CLIENT': 'hdp-tez::tez_client'
 }
 
 serviceStates = {

+ 2 - 1
ambari-server/src/main/java/org/apache/ambari/server/Role.java

@@ -74,5 +74,6 @@ public enum Role {
   RESOURCEMANAGER_SERVICE_CHECK,
   NODEMANAGER,
   YARN_CLIENT,
-  HISTORYSERVER
+  HISTORYSERVER,
+  TEZ_CLIENT
 }

+ 2 - 2
ambari-server/src/main/resources/stacks/HDP/2.0.1/services/TEZ/metainfo.xml

@@ -17,12 +17,12 @@
 -->
 <metainfo>
     <user>root</user>
-    <comment>This is comment for TEZ service</comment>
+    <comment>Tez is the next generation Hadoop Query Processing framework written on top of YARN</comment>
     <version>0.1.0.22-1</version>
 
     <components>
         <component>
-            <name>TEZ</name>
+            <name>TEZ_CLIENT</name>
             <category>CLIENT</category>
         </component>
     </components>