ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From alexantone...@apache.org
Subject [1/4] ambari git commit: Revert "AMBARI-15487. Add support for ECS stack (Vijay Srinivasaraghavan via smohanty)"
Date Mon, 21 Mar 2016 14:12:00 GMT
Repository: ambari
Updated Branches:
  refs/heads/branch-2.2 75da576d7 -> f189015a3


http://git-wip-us.apache.org/repos/asf/ambari/blob/f189015a/ambari-server/src/test/resources/stacks/HDP/2.2.0.ECS/services/HDFS/metainfo.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/test/resources/stacks/HDP/2.2.0.ECS/services/HDFS/metainfo.xml
b/ambari-server/src/test/resources/stacks/HDP/2.2.0.ECS/services/HDFS/metainfo.xml
deleted file mode 100644
index ed20968..0000000
--- a/ambari-server/src/test/resources/stacks/HDP/2.2.0.ECS/services/HDFS/metainfo.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0"?>
-<!--
-   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.
--->
-<metainfo>
-  <schemaVersion>2.0</schemaVersion>
-  <services>
-    <service>
-      <name>HDFS</name>
-      <comment>Apache Hadoop Distributed File System</comment>
-      <version>2.1.0.2.0.6.0</version>
-      <deleted>true</deleted>
-    </service>
-  </services>
-</metainfo>

http://git-wip-us.apache.org/repos/asf/ambari/blob/f189015a/ambari-web/app/controllers/wizard/step4_controller.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/controllers/wizard/step4_controller.js b/ambari-web/app/controllers/wizard/step4_controller.js
index 3c549cd..2fef3d3 100644
--- a/ambari-web/app/controllers/wizard/step4_controller.js
+++ b/ambari-web/app/controllers/wizard/step4_controller.js
@@ -278,7 +278,7 @@ App.WizardStep4Controller = Em.ArrayController.extend({
     var dfsServices = ['HDFS', 'GLUSTERFS'];
     var availableServices = this.filterProperty('isInstalled',false);
     availableServices.forEach(function(service){
-      if (dfsServices.contains(service.get('serviceName')) || service.get('serviceType')
== 'HCFS' ) {
+      if (dfsServices.contains(service.get('serviceName'))) {
         console.log("found DFS " + service.get('serviceName'));
         bDFSStack=true;
       }
@@ -294,25 +294,24 @@ App.WizardStep4Controller = Em.ArrayController.extend({
   fileSystemServiceValidation: function(callback) {
     if(this.isDFSStack()){
       var primaryDFS = this.findProperty('isPrimaryDFS',true);
-      if (primaryDFS) {
-        var primaryDfsDisplayName = primaryDFS.get('displayNameOnSelectServicePage');
-        var primaryDfsServiceName = primaryDFS.get('serviceName');
-        if (this.multipleDFSs()) {
-          var dfsServices = this.filterProperty('isDFS',true).filterProperty('isSelected',true).mapProperty('serviceName');
-          var services = dfsServices.map(function (item){
+      var primaryDfsDisplayName = primaryDFS.get('displayNameOnSelectServicePage');
+      var primaryDfsServiceName = primaryDFS.get('serviceName');
+      if (this.multipleDFSs()) {
+        var dfsServices = this.filterProperty('isDFS',true).filterProperty('isSelected',true).mapProperty('serviceName');
+        var services = dfsServices.map(function (item){
           return  {
-                     serviceName: item,
-                     selected: item === primaryDfsServiceName
-                  };
-          });
-          this.addValidationError({
-                     id: 'multipleDFS',
-                     callback: this.needToAddServicePopup,
-                     callbackParams: [services, 'multipleDFS', primaryDfsDisplayName]
-          });
-        }
+            serviceName: item,
+            selected: item === primaryDfsServiceName
+          };
+        });
+        this.addValidationError({
+          id: 'multipleDFS',
+          callback: this.needToAddServicePopup,
+          callbackParams: [services, 'multipleDFS', primaryDfsDisplayName, callback]
+        });
+      }
     }
-  }},
+  },
 
   /**
    * Checks if a dependent service is selected without selecting the main service.

http://git-wip-us.apache.org/repos/asf/ambari/blob/f189015a/ambari-web/app/data/HDP2/site_properties.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/data/HDP2/site_properties.js b/ambari-web/app/data/HDP2/site_properties.js
index d49fcc1..54dfde0 100644
--- a/ambari-web/app/data/HDP2/site_properties.js
+++ b/ambari-web/app/data/HDP2/site_properties.js
@@ -1912,21 +1912,6 @@ var hdp2properties = [
     "category": "Ambari Principals",
     "filename": "storm-env.xml",
     "index": 12
-  },
-//***************************************** ECS stack********************************************
-  {
-    "id": "puppet var",
-    "name": "hdfs_log_dir_prefix",
-    "displayName": "Hadoop Log Dir Prefix",
-    "description": "The parent directory for Hadoop log files.  The HDFS log directory will
be ${hadoop_log_dir_prefix} / ${hdfs_user} and the MapReduce log directory will be ${hadoop_log_dir_prefix}
/ ${mapred_user}.",
-    "recommendedValue": "/var/log/hadoop",
-    "isReconfigurable": false,
-    "displayType": "directory",
-    "isOverridable": false,
-    "isVisible": false,
-    "serviceName": "ECS",
-    "filename": "hadoop-env.xml",
-    "category": "General Hadoop"
   }
 ].concat(require('data/HDP2/alert_notification')).concat(require('data/HDP2/gluster_fs_properties'));
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/f189015a/ambari-web/app/mappers/stack_service_mapper.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/mappers/stack_service_mapper.js b/ambari-web/app/mappers/stack_service_mapper.js
index 8a65055..1af4bdf 100644
--- a/ambari-web/app/mappers/stack_service_mapper.js
+++ b/ambari-web/app/mappers/stack_service_mapper.js
@@ -25,7 +25,6 @@ App.stackServiceMapper = App.QuickDataMapper.create({
     id: 'service_name',
     stack_id: 'stack_id',
     service_name: 'service_name',
-    service_type: 'service_type',
     display_name: 'display_name',
     config_types: 'config_types',
     comments: 'comments',

http://git-wip-us.apache.org/repos/asf/ambari/blob/f189015a/ambari-web/app/mixins/common/configs/configs_saver.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/mixins/common/configs/configs_saver.js b/ambari-web/app/mixins/common/configs/configs_saver.js
index f8b258f..ee00146 100644
--- a/ambari-web/app/mixins/common/configs/configs_saver.js
+++ b/ambari-web/app/mixins/common/configs/configs_saver.js
@@ -389,9 +389,7 @@ App.ConfigsSaverMixin = Em.Mixin.create({
       case 'mapred-queue-acls.xml':
         return false;
       case 'core-site.xml':
-        var serviceName = this.get('content.serviceName');
-        var serviceType = App.StackService.find().findProperty('serviceName',serviceName).get('serviceType');
-        return ['HDFS', 'GLUSTERFS', 'RANGER_KMS'].contains(this.get('content.serviceName'))
|| serviceType === 'HCFS';
+        return ['HDFS', 'GLUSTERFS', 'RANGER_KMS'].contains(this.get('content.serviceName'));
       default :
         return true;
     }

http://git-wip-us.apache.org/repos/asf/ambari/blob/f189015a/ambari-web/app/models/stack_service.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/models/stack_service.js b/ambari-web/app/models/stack_service.js
index ad2c03c..c13bdfc 100644
--- a/ambari-web/app/models/stack_service.js
+++ b/ambari-web/app/models/stack_service.js
@@ -27,7 +27,6 @@ require('models/configs/objects/service_config_category');
  */
 App.StackService = DS.Model.extend({
   serviceName: DS.attr('string'),
-  serviceType: DS.attr('string'),
   displayName: DS.attr('string'),
   comments: DS.attr('string'),
   configTypes: DS.attr('object'),
@@ -54,10 +53,7 @@ App.StackService = DS.Model.extend({
   // Is the service a distributed filesystem
   isDFS: function () {
     var dfsServices = ['HDFS', 'GLUSTERFS'];
-    if( this.get('serviceType') == 'HCFS' || dfsServices.contains(this.get('serviceName'))
)
-    	return true;
-    else
-    	return false;
+    return dfsServices.contains(this.get('serviceName'));
   }.property('serviceName'),
 
   // Primary DFS. used if there is more than one DFS in a stack.

http://git-wip-us.apache.org/repos/asf/ambari/blob/f189015a/ambari-web/test/mixins/common/configs/configs_saver_test.js
----------------------------------------------------------------------
diff --git a/ambari-web/test/mixins/common/configs/configs_saver_test.js b/ambari-web/test/mixins/common/configs/configs_saver_test.js
index 5bf6f26..d8b3cb3 100644
--- a/ambari-web/test/mixins/common/configs/configs_saver_test.js
+++ b/ambari-web/test/mixins/common/configs/configs_saver_test.js
@@ -23,60 +23,27 @@ describe('App.ConfigsSaverMixin', function() {
   var instanceObject = mixinObject.create({});
 
   describe('#allowSaveSite()', function() {
-    var stackServices = [
-      Em.Object.create({
-        serviceName: 'HDFS',
-        serviceType: 'NONHCFS'
-      }),
-      Em.Object.create({
-        serviceName: 'S1',
-        serviceType: 'HCFS'
-      }),
-      Em.Object.create({
-        serviceName: 'S2',
-        serviceType: 'NONHCFS'
-      }),
-      Em.Object.create({
-        serviceName: 'S3'
-      })
-    ];
+
     beforeEach(function() {
       instanceObject.set('content', {});
-      sinon.stub(App.StackService, 'find', function () {
-        return stackServices;
-      });
-    });
-
-    afterEach(function() {
-      App.StackService.find.restore();
     });
 
     it('returns true by default', function() {
       expect(instanceObject.allowSaveSite('some-site')).to.be.true
     });
 
-    it('returns true for core-site and proper service', function() {
-      instanceObject.set('content.serviceName', 'HDFS');
-      expect(instanceObject.allowSaveSite('core-site.xml')).to.be.true
-    });
-
-    it('returns true for core-site and serviceType HCFS', function() {
-      instanceObject.set('content.serviceName', 'S1');
-      expect(instanceObject.allowSaveSite('core-site.xml')).to.be.true
-    });
-
-    it('returns false for core-site and serviceType not HCFS', function() {
-      instanceObject.set('content.serviceName', 'S2');
-      expect(instanceObject.allowSaveSite('core-site.xml')).to.be.false
+    it('returns false for mapred-queue-acls.xml', function() {
+      expect(instanceObject.allowSaveSite('mapred-queue-acls.xml')).to.be.false
     });
 
-    it('returns false for core-site but serviceType undefined', function() {
-      instanceObject.set('content.serviceName', 'S3');
+    it('returns false for core-site but not proper service', function() {
+      instanceObject.set('content.serviceName', 'ANY');
       expect(instanceObject.allowSaveSite('core-site.xml')).to.be.false
     });
 
-    it('returns false for mapred-queue-acls.xml', function() {
-      expect(instanceObject.allowSaveSite('mapred-queue-acls.xml')).to.be.false
+    it('returns true for core-site and proper service', function() {
+      instanceObject.set('content.serviceName', 'HDFS');
+      expect(instanceObject.allowSaveSite('core-site.xml')).to.be.true
     });
   });
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/f189015a/contrib/fast-hdfs-resource/src/main/java/org/apache/ambari/fast_hdfs_resource/Runner.java
----------------------------------------------------------------------
diff --git a/contrib/fast-hdfs-resource/src/main/java/org/apache/ambari/fast_hdfs_resource/Runner.java
b/contrib/fast-hdfs-resource/src/main/java/org/apache/ambari/fast_hdfs_resource/Runner.java
index e4656c7..70870de 100644
--- a/contrib/fast-hdfs-resource/src/main/java/org/apache/ambari/fast_hdfs_resource/Runner.java
+++ b/contrib/fast-hdfs-resource/src/main/java/org/apache/ambari/fast_hdfs_resource/Runner.java
@@ -88,12 +88,8 @@ public class Runner {
           dfs.delete(pathHadoop, true);
         }
       }
-    } 
-    catch(Exception e) {
-       System.out.println("Exception occurred, Reason: " + e.getMessage());
-       e.printStackTrace();
-    }
-    finally {
+
+    } finally {
       dfs.close();
     }
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/f189015a/dev-support/docker/docker/Dockerfile
----------------------------------------------------------------------
diff --git a/dev-support/docker/docker/Dockerfile b/dev-support/docker/docker/Dockerfile
index bf47021..701ed6e 100644
--- a/dev-support/docker/docker/Dockerfile
+++ b/dev-support/docker/docker/Dockerfile
@@ -16,7 +16,7 @@ RUN echo root:changeme | chpasswd
 
 ## Install some basic utilities that aren't in the default image
 RUN yum clean all -y && yum update -y
-RUN yum -y install vim wget rpm-build sudo which telnet tar openssh-server openssh-clients
ntp git python-setuptools python-devel httpd
+RUN yum -y install vim wget rpm-build sudo which telnet tar openssh-server openssh-clients
ntp git python-setuptools httpd
 # phantomjs dependency
 RUN yum -y install fontconfig freetype libfreetype.so.6 libfontconfig.so.1 libstdc++.so.6
 RUN rpm -e --nodeps --justdb glibc-common
@@ -25,8 +25,11 @@ RUN yum -y install glibc-common
 ENV HOME /root
 
 #Install JAVA
-RUN wget --no-check-certificate --no-cookies --header "Cookie:oraclelicense=accept-securebackup-cookie"
http://download.oracle.com/otn-pub/java/jdk/7u55-b13/jdk-7u55-linux-x64.rpm -O jdk-7u55-linux-x64.rpm
-RUN rpm -ivh jdk-7u55-linux-x64.rpm
+# RUN wget --no-check-certificate --no-cookies --header "Cookie:oraclelicense=accept-securebackup-cookie"
http://download.oracle.com/otn-pub/java/jdk/7u55-b13/jdk-7u55-linux-x64.rpm -O jdk-7u55-linux-x64.rpm
+# RUN yum -y install jdk-7u55-linux-x64.rpm
+RUN wget --no-check-certificate --no-cookies --header "Cookie:oraclelicense=accept-securebackup-cookie"
http://download.oracle.com/otn-pub/java/jdk/6u45-b06/jdk-6u45-linux-x64-rpm.bin -O jdk-6u45-linux-x64-rpm.bin
+RUN chmod +x jdk-6u45-linux-x64-rpm.bin
+RUN ./jdk-6u45-linux-x64-rpm.bin
 ENV JAVA_HOME /usr/java/default/
 
 #Install Maven
@@ -47,9 +50,6 @@ RUN cat /root/.ssh/id_rsa.pub > /root/.ssh/authorized_keys
 RUN chmod 600 /root/.ssh/authorized_keys
 RUN sed -ri 's/UsePAM yes/UsePAM no/g' /etc/ssh/sshd_config
 
-#To allow bower install behind proxy. See https://github.com/bower/bower/issues/731
-RUN git config --global url."https://".insteadOf git://
-
 # Install python, nodejs and npm
 RUN yum -y install http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
 RUN yum -y install nodejs npm --enablerepo=epel
@@ -59,8 +59,8 @@ RUN npm install -g brunch@1.7.13
 WORKDIR /tmp
 RUN git clone https://github.com/apache/ambari.git
 WORKDIR /tmp/ambari
-
-RUN mvn -B -X clean install package rpm:rpm -DskipTests -Dpython.ver="python >= 2.6" -Preplaceurl
+RUN mvn versions:set -DnewVersion=1.6.1.0
+RUN mvn -B clean install package rpm:rpm -DskipTests -DnewVersion=1.6.1.0 -Dpython.ver="python
>= 2.6" -Preplaceurl
 
 # clean git code because I want to use the one on local filesystem.
 WORKDIR /tmp


Mime
View raw message