Selaa lähdekoodia

AMBARI-5768. Create a different global for hive heapsize -> hive_heapsize for hive-env.sh.(vbrodetskyi)

Vitaly Brodetskyi 11 vuotta sitten
vanhempi
commit
b7c9651ec1

+ 7 - 0
ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HIVE/configuration/hive-site.xml

@@ -18,6 +18,13 @@ limitations under the License.
 -->
 
 <configuration>
+
+  <property>
+    <name>hive.heapsize</name>
+    <value>1024</value>
+    <description>Hive Java heap size</description>
+  </property>
+
   <property>
     <name>ambari.hive.db.schema.name</name>
     <value>hive</value>

+ 1 - 0
ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HIVE/package/scripts/params.py

@@ -99,6 +99,7 @@ start_metastore_path = "/tmp/start_metastore_script"
 
 hive_aux_jars_path = config['configurations']['global']['hive_aux_jars_path']
 hadoop_heapsize = config['configurations']['global']['hadoop_heapsize']
+hive_heapsize = config['configurations']['hive-site']['hive.heapsize']
 java64_home = config['hostLevelParams']['java_home']
 
 ##### MYSQL

+ 1 - 1
ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HIVE/package/templates/hive-env.sh.j2

@@ -55,7 +55,7 @@
 
 # The heap size of the jvm stared by hive shell script can be controlled via:
 
-export HADOOP_HEAPSIZE="{{hadoop_heapsize}}"
+export HADOOP_HEAPSIZE="{{hive_heapsize}}"
 export HADOOP_CLIENT_OPTS="-Xmx${HADOOP_HEAPSIZE}m $HADOOP_CLIENT_OPTS"
 
 # Larger heap size may be required when running queries over large number of files or partitions.

+ 6 - 0
ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/configuration/hive-site.xml

@@ -19,6 +19,12 @@ limitations under the License.
 
 <configuration>
 
+  <property>
+    <name>hive.heapsize</name>
+    <value>1024</value>
+    <description>Hive Java heap size</description>
+  </property>
+
   <property>
     <name>ambari.hive.db.schema.name</name>
     <value>hive</value>

+ 1 - 0
ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/package/scripts/params.py

@@ -102,6 +102,7 @@ start_metastore_path = "/tmp/start_metastore_script"
 
 hive_aux_jars_path = config['configurations']['global']['hive_aux_jars_path']
 hadoop_heapsize = config['configurations']['global']['hadoop_heapsize']
+hive_heapsize = config['configurations']['hive-site']['hive.heapsize']
 java64_home = config['hostLevelParams']['java_home']
 
 ##### MYSQL

+ 1 - 1
ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/package/templates/hive-env.sh.j2

@@ -54,7 +54,7 @@
 
 # The heap size of the jvm stared by hive shell script can be controlled via:
 
-export HADOOP_HEAPSIZE="{{hadoop_heapsize}}"
+export HADOOP_HEAPSIZE="{{hive_heapsize}}"
 export HADOOP_CLIENT_OPTS="-Xmx${HADOOP_HEAPSIZE}m $HADOOP_CLIENT_OPTS"
 
 # Larger heap size may be required when running queries over large number of files or partitions.

+ 6 - 0
ambari-server/src/main/resources/stacks/HDP/2.1/services/HIVE/configuration/hive-site.xml

@@ -19,6 +19,12 @@ limitations under the License.
 
 <configuration>
 
+  <property>
+    <name>hive.heapsize</name>
+    <value>1024</value>
+    <description>Hive Java heap size</description>
+  </property>
+
   <property>
     <name>ambari.hive.db.schema.name</name>
     <value>hive</value>

+ 13 - 0
ambari-web/app/data/HDP2/site_properties.js

@@ -429,6 +429,19 @@ module.exports =
       "serviceName": "HIVE",
       "index": 7
     },
+    {
+      "id": "site property",
+      "name": "hive.heapsize",
+      "displayName": "Hive heap size",
+      "description": "Maximum Java heap size for HIVE service (Java option -Xmx)",
+      "defaultValue": "1024",
+      "displayType": "int",
+      "unit": "MB",
+      "isOverridable": false,
+      "serviceName": "HIVE",
+      "category": "General",
+      "index": 9
+    },
     {
       "id": "site property",
       "name": "javax.jdo.option.ConnectionUserName",

+ 1 - 0
ambari-web/app/data/service_configs.js

@@ -122,6 +122,7 @@ module.exports = [
     defaultsProviders: [App.HiveDefaultsProvider.create()],
     configCategories: [
       App.ServiceConfigCategory.create({ name: 'Hive Metastore', displayName : 'Hive Metastore'}),
+      App.ServiceConfigCategory.create({ name: 'General', displayName : 'General'}),
       App.ServiceConfigCategory.create({ name: 'Advanced', displayName : 'Advanced'}),
       App.ServiceConfigCategory.create({ name: 'AdvancedHiveSite', displayName : 'Custom hive-site.xml', siteFileName: 'hive-site.xml', canAddProperty: true}),
       App.ServiceConfigCategory.create({ name: 'AdvancedHiveLog4j', displayName : 'Custom log4j.properties', siteFileName: 'hive-log4j.xml', canAddProperty: false}),

+ 13 - 0
ambari-web/app/data/site_properties.js

@@ -427,6 +427,19 @@ module.exports =
       "serviceName": "HIVE",
       "index": 7
     },
+    {
+      "id": "site property",
+      "name": "hive.heapsize",
+      "displayName": "Hive heap size",
+      "description": "Maximum Java heap size for HIVE service (Java option -Xmx)",
+      "defaultValue": "1024",
+      "displayType": "int",
+      "unit": "MB",
+      "isOverridable": false,
+      "serviceName": "HIVE",
+      "category": "General",
+      "index": 9
+    },
     {
       "id": "site property",
       "name": "javax.jdo.option.ConnectionUserName",