AMBARI-21751. Fix regression caused by AMBARI-21045. (yusaku) (cherry picked from commit da9ea1cfb3efb7fd538acbfd8f38f0a8a2c580df)
Change-Id: I72fc722312ff6ae3bbc305051ccf9a7a0ae96efe Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/99a0714f Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/99a0714f Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/99a0714f Branch: refs/heads/2.5-maint Commit: 99a0714f0020e6586c83da17242c7c2e1d3ac736 Parents: c0648e1 Author: Yusaku Sako <[email protected]> Authored: Fri Aug 18 02:54:36 2017 -0700 Committer: [email protected] <[email protected]> Committed: Fri Aug 18 10:36:18 2017 +0000 ---------------------------------------------------------------------- .../stacks/HDP/2.6/services/stack_advisor.py | 31 -------------------- 1 file changed, 31 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/ambari/blob/99a0714f/ambari-server/src/main/resources/stacks/HDP/2.6/services/stack_advisor.py ---------------------------------------------------------------------- diff --git a/ambari-server/src/main/resources/stacks/HDP/2.6/services/stack_advisor.py b/ambari-server/src/main/resources/stacks/HDP/2.6/services/stack_advisor.py index 974b10c..577e4f5 100644 --- a/ambari-server/src/main/resources/stacks/HDP/2.6/services/stack_advisor.py +++ b/ambari-server/src/main/resources/stacks/HDP/2.6/services/stack_advisor.py @@ -42,7 +42,6 @@ class HDP26StackAdvisor(HDP25StackAdvisor): "HBASE": self.recommendHBASEConfigurations, "YARN": self.recommendYARNConfigurations, "KAFKA": self.recommendKAFKAConfigurations, - "BEACON": self.recommendBEACONConfigurations, "STORM": self.recommendSTORMConfigurations } parentRecommendConfDict.update(childRecommendConfDict) @@ -96,36 +95,6 @@ class HDP26StackAdvisor(HDP25StackAdvisor): putStormSiteProperty("nimbus.credential.renewers.classes", "['org.apache.storm.hdfs.security.AutoHDFS', 'org.apache.storm.hbase.security.AutoHBase', 'org.apache.storm.hive.security.AutoHive']") putStormSiteProperty("nimbus.credential.renewers.freq.secs", "82800") pass - - def recommendBEACONConfigurations(self, configurations, clusterData, services, hosts): - beaconEnvProperties = self.getSiteProperties(services['configurations'], 'beacon-env') - putbeaconEnvProperty = self.putProperty(configurations, "beacon-env", services) - - # database URL and driver class recommendations - if beaconEnvProperties and self.checkSiteProperties(beaconEnvProperties, 'beacon_store_driver') and self.checkSiteProperties(beaconEnvProperties, 'beacon_database'): - putbeaconEnvProperty('beacon_store_driver', self.getDBDriver(beaconEnvProperties['beacon_database'])) - if beaconEnvProperties and self.checkSiteProperties(beaconEnvProperties, 'beacon_store_db_name', 'beacon_store_url') and self.checkSiteProperties(beaconEnvProperties, 'beacon_database'): - beaconServerHost = self.getHostWithComponent('BEACON', 'BEACON_SERVER', services, hosts) - beaconDBConnectionURL = beaconEnvProperties['beacon_store_url'] - protocol = self.getProtocol(beaconEnvProperties['beacon_database']) - oldSchemaName = getOldValue(self, services, "beacon-env", "beacon_store_db_name") - oldDBType = getOldValue(self, services, "beacon-env", "beacon_database") - # under these if constructions we are checking if beacon server hostname available, - # if it's default db connection url with "localhost" or if schema name was changed or if db type was changed (only for db type change from default mysql to existing mysql) - # or if protocol according to current db type differs with protocol in db connection url(other db types changes) - if beaconServerHost is not None: - if (beaconDBConnectionURL and "//localhost" in beaconDBConnectionURL) or oldSchemaName or oldDBType or (protocol and beaconDBConnectionURL and not beaconDBConnectionURL.startswith(protocol)): - dbConnection = self.getDBConnectionStringBeacon(beaconEnvProperties['beacon_database']).format(beaconServerHost['Hosts']['host_name'], beaconEnvProperties['beacon_store_db_name']) - putbeaconEnvProperty('beacon_store_url', dbConnection) - - def getDBConnectionStringBeacon(self, databaseType): - driverDict = { - 'NEW DERBY DATABASE': 'jdbc:derby:${{beacon.data.dir}}/${{beacon.store.db.name}}-db;create=true', - 'EXISTING MYSQL DATABASE': 'jdbc:mysql://{0}/{1}', - 'EXISTING MYSQL / MARIADB DATABASE': 'jdbc:mysql://{0}/{1}', - 'EXISTING ORACLE DATABASE': 'jdbc:oracle:thin:@//{0}:1521/{1}' - } - return driverDict.get(databaseType.upper()) def recommendAtlasConfigurations(self, configurations, clusterData, services, hosts): super(HDP26StackAdvisor, self).recommendAtlasConfigurations(configurations, clusterData, services, hosts)
