You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by pa...@apache.org on 2016/07/11 14:29:21 UTC
ambari git commit: AMBARI-17632. Zeppelin service: Dependencies for
phoenix in JDBC interpreter are not configured by default (Renjith Kamath via
pallavkul)
Repository: ambari
Updated Branches:
refs/heads/trunk 17ae4230d -> e5350040d
AMBARI-17632. Zeppelin service: Dependencies for phoenix in JDBC interpreter are not configured by default (Renjith Kamath via pallavkul)
Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/e5350040
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/e5350040
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/e5350040
Branch: refs/heads/trunk
Commit: e5350040d4742cd1eaef62372a306f4c5d25403d
Parents: 17ae423
Author: Pallav Kulshreshtha <pa...@gmail.com>
Authored: Mon Jul 11 19:58:13 2016 +0530
Committer: Pallav Kulshreshtha <pa...@gmail.com>
Committed: Mon Jul 11 19:58:13 2016 +0530
----------------------------------------------------------------------
.../0.6.0.2.5/package/scripts/master.py | 57 +++++++++++---------
.../0.6.0.2.5/package/scripts/params.py | 4 ++
2 files changed, 36 insertions(+), 25 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ambari/blob/e5350040/ambari-server/src/main/resources/common-services/ZEPPELIN/0.6.0.2.5/package/scripts/master.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/common-services/ZEPPELIN/0.6.0.2.5/package/scripts/master.py b/ambari-server/src/main/resources/common-services/ZEPPELIN/0.6.0.2.5/package/scripts/master.py
index 632f983..57082da 100644
--- a/ambari-server/src/main/resources/common-services/ZEPPELIN/0.6.0.2.5/package/scripts/master.py
+++ b/ambari-server/src/main/resources/common-services/ZEPPELIN/0.6.0.2.5/package/scripts/master.py
@@ -249,31 +249,38 @@ class Master(Script):
interpreter_settings = config_data['interpreterSettings']
for notebooks in interpreter_settings:
- notebook = interpreter_settings[notebooks]
- if notebook['group'] == 'jdbc':
- notebook['dependencies'] = []
- if params.hive_server_host:
- notebook['properties']['hive.url'] = 'jdbc:hive2://' + \
- params.hive_server_host + \
- ':' + params.hive_server_port
- notebook['dependencies'].append(
- {"groupArtifactVersion": "org.apache.hive:hive-jdbc:2.0.1", "local": "false"})
- notebook['dependencies'].append(
- {"groupArtifactVersion": "org.apache.hadoop:hadoop-common:2.7.2", "local": "false"})
-
- elif params.zookeeper_znode_parent \
- and params.hbase_zookeeper_quorum:
- notebook['properties']['phoenix.url'] = "jdbc:phoenix:" + \
- params.hbase_zookeeper_quorum + ':' + \
- params.zookeeper_znode_parent
- notebook['dependencies'].append(
- {"groupArtifactVersion": "org.apache.phoenix:phoenix-core:4.4.0-HBase-1.0", "local": "false"})
- elif notebook['group'] == 'livy' and params.livy_livyserver_host:
- notebook['properties']['livy.spark.master'] = "yarn-cluster"
- notebook['properties']['zeppelin.livy.url'] = "http://" + params.livy_livyserver_host +\
- ":" + params.livy_livyserver_port
- elif notebook['group'] == 'spark':
- notebook['properties']['master'] = "yarn-client"
+ notebook = interpreter_settings[notebooks]
+ if notebook['group'] == 'jdbc':
+ notebook['dependencies'] = []
+ if params.hive_server_host:
+ if params.hive_server2_support_dynamic_service_discovery:
+ notebook['properties']['hive.url'] = 'jdbc:hive2://' + \
+ params.hive_zookeeper_quorum + \
+ '/;' + 'serviceDiscoveryMode=zooKeeper;zooKeeperNamespace=hiveserver2'
+ else:
+ notebook['properties']['hive.url'] = 'jdbc:hive2://' + \
+ params.hive_server_host + \
+ ':' + params.hive_server_port
+ notebook['dependencies'].append(
+ {"groupArtifactVersion": "org.apache.hive:hive-jdbc:2.0.1", "local": "false"})
+ notebook['dependencies'].append(
+ {"groupArtifactVersion": "org.apache.hadoop:hadoop-common:2.7.2", "local": "false"})
+ notebook['dependencies'].append(
+ {"groupArtifactVersion": "org.apache.hive.shims:hive-shims-0.23:2.1.0", "local": "false"})
+
+ if params.zookeeper_znode_parent \
+ and params.hbase_zookeeper_quorum:
+ notebook['properties']['phoenix.url'] = "jdbc:phoenix:" + \
+ params.hbase_zookeeper_quorum + ':' + \
+ params.zookeeper_znode_parent
+ notebook['dependencies'].append(
+ {"groupArtifactVersion": "org.apache.phoenix:phoenix-core:4.7.0-HBase-1.1", "local": "false"})
+ elif notebook['group'] == 'livy' and params.livy_livyserver_host:
+ notebook['properties']['livy.spark.master'] = "yarn-cluster"
+ notebook['properties']['zeppelin.livy.url'] = "http://" + params.livy_livyserver_host +\
+ ":" + params.livy_livyserver_port
+ elif notebook['group'] == 'spark':
+ notebook['properties']['master'] = "yarn-client"
self.set_interpreter_settings(config_data)
if __name__ == "__main__":
http://git-wip-us.apache.org/repos/asf/ambari/blob/e5350040/ambari-server/src/main/resources/common-services/ZEPPELIN/0.6.0.2.5/package/scripts/params.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/common-services/ZEPPELIN/0.6.0.2.5/package/scripts/params.py b/ambari-server/src/main/resources/common-services/ZEPPELIN/0.6.0.2.5/package/scripts/params.py
index 6016ae1..85e6fcf 100644
--- a/ambari-server/src/main/resources/common-services/ZEPPELIN/0.6.0.2.5/package/scripts/params.py
+++ b/ambari-server/src/main/resources/common-services/ZEPPELIN/0.6.0.2.5/package/scripts/params.py
@@ -102,12 +102,16 @@ hive_server_host = None
hive_metastore_host = '0.0.0.0'
hive_metastore_port = None
hive_server_port = None
+hive_zookeeper_quorum = None
+hive_server2_support_dynamic_service_discovery = None
if 'hive_server_host' in master_configs and len(master_configs['hive_server_host']) != 0:
hive_server_host = str(master_configs['hive_server_host'][0])
hive_metastore_host = str(master_configs['hive_metastore_host'][0])
hive_metastore_port = str(
get_port_from_url(config['configurations']['hive-site']['hive.metastore.uris']))
hive_server_port = str(config['configurations']['hive-site']['hive.server2.thrift.http.port'])
+ hive_zookeeper_quorum = config['configurations']['hive-site']['hive.zookeeper.quorum']
+ hive_server2_support_dynamic_service_discovery = config['configurations']['hive-site']['hive.server2.support.dynamic.service.discovery']
# detect hbase details if installed
zookeeper_znode_parent = None