ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From smoha...@apache.org
Subject ambari git commit: Revert "AMBARI-17113. Add user home directory verification as part of Service Check (pallavkul)"
Date Fri, 10 Jun 2016 20:36:37 GMT
Repository: ambari
Updated Branches:
  refs/heads/branch-2.4 0038e3bd9 -> 80adb61a4


Revert "AMBARI-17113. Add user home directory verification as part of Service Check (pallavkul)"

This reverts commit 5e56e509779f3fd90b56268c6633539582a66ae9.


Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/80adb61a
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/80adb61a
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/80adb61a

Branch: refs/heads/branch-2.4
Commit: 80adb61a487d682e55d2d34e853b07f39464416a
Parents: 0038e3b
Author: Sumit Mohanty <smohanty@hortonworks.com>
Authored: Fri Jun 10 13:33:29 2016 -0700
Committer: Sumit Mohanty <smohanty@hortonworks.com>
Committed: Fri Jun 10 13:33:29 2016 -0700

----------------------------------------------------------------------
 .../main/resources/ui/app/templates/splash.hbs  |  3 ++-
 contrib/views/hive/pom.xml                      |  5 -----
 .../apache/ambari/view/hive/HelpService.java    | 12 ----------
 .../view/hive/resources/files/FileService.java  | 16 --------------
 .../ui/hive-web/app/controllers/splash.js       | 19 ++++++----------
 .../resources/ui/hive-web/app/routes/splash.js  |  4 +---
 .../ui/hive-web/app/templates/splash.hbs        | 23 ++++----------------
 contrib/views/pig/pom.xml                       |  5 -----
 .../view/pig/resources/files/FileService.java   | 18 ---------------
 .../ambari/view/pig/services/HelpService.java   | 14 ------------
 .../ui/pig-web/app/controllers/splash.js        |  8 +++----
 .../resources/ui/pig-web/app/routes/splash.js   |  4 +---
 .../ui/pig-web/app/templates/splash.hbs         | 17 ++-------------
 .../resources/ui/pig-web/app/translations.js    |  3 +--
 14 files changed, 22 insertions(+), 129 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/80adb61a/contrib/views/files/src/main/resources/ui/app/templates/splash.hbs
----------------------------------------------------------------------
diff --git a/contrib/views/files/src/main/resources/ui/app/templates/splash.hbs b/contrib/views/files/src/main/resources/ui/app/templates/splash.hbs
index 26dbff0..4a45366 100644
--- a/contrib/views/files/src/main/resources/ui/app/templates/splash.hbs
+++ b/contrib/views/files/src/main/resources/ui/app/templates/splash.hbs
@@ -18,6 +18,7 @@
 
 <div class="spinner"></div>
 <div class="container-fluid">
+  <h1>Welcome to the File Browser View</h1>
   {{#if allTestsCompleted }}
     <h3>Service checks completed.</h3>
   {{else}}
@@ -48,7 +49,7 @@
           <i class="fa fa-arrow-right"></i>
         {{/if}}
       </td>
-      <td>HDFS test</td>
+      <td>hdfs service test</td>
     </tr>
     </tbody>
   </table>

http://git-wip-us.apache.org/repos/asf/ambari/blob/80adb61a/contrib/views/hive/pom.xml
----------------------------------------------------------------------
diff --git a/contrib/views/hive/pom.xml b/contrib/views/hive/pom.xml
index 26e0525..6c931ae 100644
--- a/contrib/views/hive/pom.xml
+++ b/contrib/views/hive/pom.xml
@@ -226,11 +226,6 @@
       <artifactId>commons-csv</artifactId>
       <version>1.1</version>
     </dependency>
-    <dependency>
-      <groupId>org.apache.ambari.contrib.views</groupId>
-      <artifactId>ambari-views-commons</artifactId>
-      <version>2.0.0.0-SNAPSHOT</version>
-    </dependency>
   </dependencies>
 
   <properties>

http://git-wip-us.apache.org/repos/asf/ambari/blob/80adb61a/contrib/views/hive/src/main/java/org/apache/ambari/view/hive/HelpService.java
----------------------------------------------------------------------
diff --git a/contrib/views/hive/src/main/java/org/apache/ambari/view/hive/HelpService.java
b/contrib/views/hive/src/main/java/org/apache/ambari/view/hive/HelpService.java
index f18a422..3a7f823 100644
--- a/contrib/views/hive/src/main/java/org/apache/ambari/view/hive/HelpService.java
+++ b/contrib/views/hive/src/main/java/org/apache/ambari/view/hive/HelpService.java
@@ -79,18 +79,6 @@ public class HelpService extends BaseService {
   }
 
   /**
-   * HomeDirectory Status
-   * @return status
-   */
-  @GET
-  @Path("/userhomeStatus")
-  @Produces(MediaType.APPLICATION_JSON)
-  public Response userhomeStatus (){
-    FileService.userhomeSmokeTest(context);
-    return getOKResponse();
-  }
-
-  /**
    * ATS Status
    * @return status
    */

http://git-wip-us.apache.org/repos/asf/ambari/blob/80adb61a/contrib/views/hive/src/main/java/org/apache/ambari/view/hive/resources/files/FileService.java
----------------------------------------------------------------------
diff --git a/contrib/views/hive/src/main/java/org/apache/ambari/view/hive/resources/files/FileService.java
b/contrib/views/hive/src/main/java/org/apache/ambari/view/hive/resources/files/FileService.java
index 4e1d24f..ab2b933 100644
--- a/contrib/views/hive/src/main/java/org/apache/ambari/view/hive/resources/files/FileService.java
+++ b/contrib/views/hive/src/main/java/org/apache/ambari/view/hive/resources/files/FileService.java
@@ -45,7 +45,6 @@ import java.io.IOException;
 import java.io.InputStream;
 import java.net.URL;
 import java.util.HashMap;
-import org.apache.ambari.view.commons.hdfs.UserService;
 
 /**
  * File access resource
@@ -236,21 +235,6 @@ public class FileService extends BaseService {
   }
 
   /**
-   * Checks connection to User HomeDirectory
-   * @param context View Context
-   */
-  public static void userhomeSmokeTest(ViewContext context) {
-    try {
-      UserService  userservice = new UserService(context);
-      userservice.homeDir();
-    } catch (WebApplicationException ex) {
-      throw ex;
-    } catch (Exception ex) {
-      throw new ServiceFormattedException(ex.getMessage(), ex);
-    }
-  }
-
-  /**
    * Wrapper object for json mapping
    */
   public static class FileResourceRequest {

http://git-wip-us.apache.org/repos/asf/ambari/blob/80adb61a/contrib/views/hive/src/main/resources/ui/hive-web/app/controllers/splash.js
----------------------------------------------------------------------
diff --git a/contrib/views/hive/src/main/resources/ui/hive-web/app/controllers/splash.js b/contrib/views/hive/src/main/resources/ui/hive-web/app/controllers/splash.js
index 6f495ed..5db93f7 100644
--- a/contrib/views/hive/src/main/resources/ui/hive-web/app/controllers/splash.js
+++ b/contrib/views/hive/src/main/resources/ui/hive-web/app/controllers/splash.js
@@ -60,11 +60,12 @@ export default Ember.Controller.extend({
       }
 
       model.set(name + 'TestDone', true);
+
       var percent = model.get('percent');
-      model.set('percent', percent + 25);
+      model.set('percent', percent + 33.33);
     };
 
-    var promises = ['hdfs', 'hiveserver', 'ats', 'userhome'].map(function(name) {
+    var promises = ['hdfs', 'hiveserver', 'ats'].map(function(name) {
 
       var finalurl = ((name == 'hiveserver') ? self.get('databaseService.baseUrl') : (url
+ name + 'Status')) || '' ;
 
@@ -87,17 +88,13 @@ export default Ember.Controller.extend({
   }.property("model.percent"),
 
   allTestsCompleted: function(){
-    return this.get('modelhdfsTestDone') && this.get('modelhiveserverTestDone') &&
this.get('modelatsTestDone') && this.get('modeluserhomeTestDone');
-  }.property('modelhdfsTestDone', 'modelhiveserverTestDone', 'modelatsTestDone', 'modeluserhomeTestDone'),
+    return this.get('modelhdfsTestDone') && this.get('modelhiveserverTestDone') &&
this.get('modelatsTestDone');
+  }.property('modelhdfsTestDone', 'modelhiveserverTestDone', 'modelatsTestDone'),
 
   modelhdfsTestDone: function() {
     return this.get('model.hdfsTestDone');
   }.property('model.hdfsTestDone' ),
 
-  modeluserhomeTestDone: function() {
-    return this.get('model.userhomeTestDone');
-  }.property('model.userhomeTestDone' ),
-
   modelhiveserverTestDone: function() {
     return this.get('model.hiveserverTestDone');
   }.property('model.hiveserverTestDone' ),
@@ -110,10 +107,6 @@ export default Ember.Controller.extend({
     return this.get('model.hdfsTest');
   }.property('model.hdfsTest' ),
 
-  modeluserhomeTest: function() {
-    return this.get('model.userhomeTest');
-  }.property('model.userhomeTest' ),
-
   modelhiveserverTest: function() {
     return this.get('model.hiveserverTest');
   }.property('model.hiveserverTest' ),
@@ -129,3 +122,5 @@ export default Ember.Controller.extend({
     }
   }
 });
+
+

http://git-wip-us.apache.org/repos/asf/ambari/blob/80adb61a/contrib/views/hive/src/main/resources/ui/hive-web/app/routes/splash.js
----------------------------------------------------------------------
diff --git a/contrib/views/hive/src/main/resources/ui/hive-web/app/routes/splash.js b/contrib/views/hive/src/main/resources/ui/hive-web/app/routes/splash.js
index 463a1c6..05bcbcf 100644
--- a/contrib/views/hive/src/main/resources/ui/hive-web/app/routes/splash.js
+++ b/contrib/views/hive/src/main/resources/ui/hive-web/app/routes/splash.js
@@ -28,8 +28,6 @@ export default Ember.Route.extend({
       hiveserverTestDone: null,
       atsTest: null,
       atsTestDone: null,
-      userhomeTest: null,
-      userhomeTestDone: null,
       percent: 0
     });
   },
@@ -44,7 +42,7 @@ export default Ember.Route.extend({
     var self = this;
     controller.startTests().then(function() {
 
-    if (model.get("hiveserverTest") && model.get("hdfsTest") && model.get("atsTest")
&& model.get("userhomeTest")) {
+    if (model.get("hiveserverTest") && model.get("hdfsTest") && model.get("atsTest"))
{
       Ember.run.later(this, function() {
         self.send('transition');
       }, 2000);

http://git-wip-us.apache.org/repos/asf/ambari/blob/80adb61a/contrib/views/hive/src/main/resources/ui/hive-web/app/templates/splash.hbs
----------------------------------------------------------------------
diff --git a/contrib/views/hive/src/main/resources/ui/hive-web/app/templates/splash.hbs b/contrib/views/hive/src/main/resources/ui/hive-web/app/templates/splash.hbs
index 5612542..84c7a71 100644
--- a/contrib/views/hive/src/main/resources/ui/hive-web/app/templates/splash.hbs
+++ b/contrib/views/hive/src/main/resources/ui/hive-web/app/templates/splash.hbs
@@ -18,6 +18,7 @@
 
 <div class="spinner"></div>
 <div class="container-fluid">
+  <h1>Welcome to the Hive View</h1>
   {{#if allTestsCompleted }}
     <h3>Service checks completed.</h3>
   {{else}}
@@ -48,7 +49,7 @@
           <i class="fa fa-arrow-right"></i>
         {{/if}}
       </td>
-      <td>HDFS test</td>
+      <td>hdfs service test</td>
     </tr>
     <tr>
       <td>
@@ -62,7 +63,7 @@
           <i class="fa fa-arrow-right"></i>
         {{/if}}
       </td>
-      <td>HiveServer test</td>
+      <td>hiveserver service test</td>
     </tr>
     <tr>
       <td>
@@ -76,24 +77,8 @@
           <i class="fa fa-arrow-right"></i>
         {{/if}}
       </td>
-      <td>ATS test</td>
+      <td>ats service test</td>
     </tr>
-
-    <tr>
-      <td>
-        {{#if modeluserhomeTestDone}}
-          {{#if modeluserhomeTest}}
-            <i class="fa fa-check"></i>
-          {{else}}
-            <i class="fa fa-remove"></i>
-          {{/if}}
-        {{else}}
-          <i class="fa fa-arrow-right"></i>
-        {{/if}}
-      </td>
-      <td>User Home Directory test</td>
-    </tr>
-
     </tbody>
   </table>
   {{#if errors}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/80adb61a/contrib/views/pig/pom.xml
----------------------------------------------------------------------
diff --git a/contrib/views/pig/pom.xml b/contrib/views/pig/pom.xml
index 55fa426..ae87f84 100644
--- a/contrib/views/pig/pom.xml
+++ b/contrib/views/pig/pom.xml
@@ -140,11 +140,6 @@
       <artifactId>ambari-views-utils</artifactId>
       <version>2.4.0.0.0</version>
     </dependency>
-    <dependency>
-      <groupId>org.apache.ambari.contrib.views</groupId>
-      <artifactId>ambari-views-commons</artifactId>
-      <version>2.0.0.0-SNAPSHOT</version>
-    </dependency>
   </dependencies>
 
   <properties>

http://git-wip-us.apache.org/repos/asf/ambari/blob/80adb61a/contrib/views/pig/src/main/java/org/apache/ambari/view/pig/resources/files/FileService.java
----------------------------------------------------------------------
diff --git a/contrib/views/pig/src/main/java/org/apache/ambari/view/pig/resources/files/FileService.java
b/contrib/views/pig/src/main/java/org/apache/ambari/view/pig/resources/files/FileService.java
index 4791103..40bc9a7 100644
--- a/contrib/views/pig/src/main/java/org/apache/ambari/view/pig/resources/files/FileService.java
+++ b/contrib/views/pig/src/main/java/org/apache/ambari/view/pig/resources/files/FileService.java
@@ -25,7 +25,6 @@ import org.apache.ambari.view.pig.services.BaseService;
 import org.apache.ambari.view.pig.utils.*;
 import org.apache.ambari.view.utils.hdfs.HdfsApi;
 import org.apache.ambari.view.utils.hdfs.HdfsUtil;
-import org.apache.ambari.view.commons.hdfs.UserService;
 import org.apache.hadoop.fs.FSDataOutputStream;
 import org.apache.hadoop.fs.FileAlreadyExistsException;
 import org.apache.hadoop.fs.FileStatus;
@@ -41,7 +40,6 @@ import java.io.IOException;
 import java.util.LinkedList;
 import java.util.List;
 
-
 /**
  * File access resource
  * API:
@@ -198,22 +196,6 @@ public class FileService extends BaseService {
     }
   }
 
-
-  /**
-   * Checks connection to User HomeDirectory
-   * @param context View Context
-   */
-  public static void userhomeSmokeTest(ViewContext context) {
-    try {
-      UserService  userservice = new UserService(context);
-      userservice.homeDir();
-    } catch (WebApplicationException ex) {
-      throw ex;
-    } catch (Exception ex) {
-      throw new ServiceFormattedException(ex.getMessage(), ex);
-    }
-  }
-
   /**
    * Wrapper object for json mapping
    */

http://git-wip-us.apache.org/repos/asf/ambari/blob/80adb61a/contrib/views/pig/src/main/java/org/apache/ambari/view/pig/services/HelpService.java
----------------------------------------------------------------------
diff --git a/contrib/views/pig/src/main/java/org/apache/ambari/view/pig/services/HelpService.java
b/contrib/views/pig/src/main/java/org/apache/ambari/view/pig/services/HelpService.java
index a67bfc5..eb363a0 100644
--- a/contrib/views/pig/src/main/java/org/apache/ambari/view/pig/services/HelpService.java
+++ b/contrib/views/pig/src/main/java/org/apache/ambari/view/pig/services/HelpService.java
@@ -92,20 +92,6 @@ public class HelpService extends BaseService {
     return getOKResponse();
   }
 
-
-  /**
-   * HomeDirectory Status
-   * @return status
-   */
-  @GET
-  @Path("/userhomeStatus")
-  @Produces(MediaType.APPLICATION_JSON)
-  public Response userhomeStatus (){
-    FileService.userhomeSmokeTest(context);
-    return getOKResponse();
-  }
-
-
   /**
    * WebHCat Status
    * @return status

http://git-wip-us.apache.org/repos/asf/ambari/blob/80adb61a/contrib/views/pig/src/main/resources/ui/pig-web/app/controllers/splash.js
----------------------------------------------------------------------
diff --git a/contrib/views/pig/src/main/resources/ui/pig-web/app/controllers/splash.js b/contrib/views/pig/src/main/resources/ui/pig-web/app/controllers/splash.js
index d1b571d..f58d437 100644
--- a/contrib/views/pig/src/main/resources/ui/pig-web/app/controllers/splash.js
+++ b/contrib/views/pig/src/main/resources/ui/pig-web/app/controllers/splash.js
@@ -57,9 +57,9 @@ App.SplashController = Ember.ObjectController.extend({
       }
       model.set(name + 'TestDone', true);
       var percent = model.get('percent');
-      model.set('percent', percent + 25);
+      model.set('percent', percent + 33.33);
     };
-    var promises = ['storage', 'webhcat', 'hdfs', 'userhome'].map(function(name) {
+    var promises = ['storage', 'webhcat', 'hdfs'].map(function(name) {
       return Ember.$.getJSON('/' + url + name + 'Status')
                .then(
                  function(data) {
@@ -78,7 +78,7 @@ App.SplashController = Ember.ObjectController.extend({
   }.property("model.percent"),
 
   allTestsCompleted: function(){
-    return this.get("model").get("hdfsTestDone") && this.get("model").get("webhcatTestDone")
&& this.get("model").get("storageTestDone") && this.get("model").get("userhomeTestDone");
-  }.property('model.hdfsTestDone', 'model.webhcatTestDone', 'model.storageTestDone', 'model.userhomeTestDone')
+    return this.get("model").get("hdfsTestDone") && this.get("model").get("webhcatTestDone")
&& this.get("model").get("storageTestDone");
+  }.property('model.hdfsTestDone', 'model.webhcatTestDone', 'model.storageTestDone')
 
 });

http://git-wip-us.apache.org/repos/asf/ambari/blob/80adb61a/contrib/views/pig/src/main/resources/ui/pig-web/app/routes/splash.js
----------------------------------------------------------------------
diff --git a/contrib/views/pig/src/main/resources/ui/pig-web/app/routes/splash.js b/contrib/views/pig/src/main/resources/ui/pig-web/app/routes/splash.js
index b30552d..1d848e3 100644
--- a/contrib/views/pig/src/main/resources/ui/pig-web/app/routes/splash.js
+++ b/contrib/views/pig/src/main/resources/ui/pig-web/app/routes/splash.js
@@ -27,8 +27,6 @@ App.SplashRoute = Em.Route.extend({
       webhcatTestDone: null,
       hdfsTest: null,
       hdfsTestDone: null,
-      userhomeTest: null,
-      userhomeTestDone: null,
       percent: 0
     });
   },
@@ -39,7 +37,7 @@ App.SplashRoute = Em.Route.extend({
     controller.set('model', model);
     var self = this;
     controller.startTests(model).then(function() {
-      if (model.get("storageTest") && model.get("webhcatTest") && model.get("hdfsTest")
&& model.get("userhomeTest")) {
+      if (model.get("storageTest") && model.get("webhcatTest") && model.get("hdfsTest"))
{
         Ember.run.later(this, function() {
           previousTransition = App.get('previousTransition');
           if (previousTransition) {

http://git-wip-us.apache.org/repos/asf/ambari/blob/80adb61a/contrib/views/pig/src/main/resources/ui/pig-web/app/templates/splash.hbs
----------------------------------------------------------------------
diff --git a/contrib/views/pig/src/main/resources/ui/pig-web/app/templates/splash.hbs b/contrib/views/pig/src/main/resources/ui/pig-web/app/templates/splash.hbs
index c97d724..d635a91 100644
--- a/contrib/views/pig/src/main/resources/ui/pig-web/app/templates/splash.hbs
+++ b/contrib/views/pig/src/main/resources/ui/pig-web/app/templates/splash.hbs
@@ -17,6 +17,8 @@
 }}
 
 <div class="container-fluid">
+  <h1>{{t 'splash.welcome'}}</h1>
+
   {{#if allTestsCompleted }}
     <h3>Service checks completed.</h3>
   {{else}}
@@ -80,21 +82,6 @@
         <td>{{t 'splash.webhcat_test'}}</td>
       </tr>
 
-      <tr>
-        <td>
-          {{#if userhomeTestDone}}
-            {{#if userhomeTest}}
-              <span class="glyphicon glyphicon-ok green"></span>
-            {{else}}
-              <span class="glyphicon glyphicon-remove red"></span>
-            {{/if}}
-          {{else}}
-            <span class="glyphicon glyphicon-arrow-right"></span>
-          {{/if}}
-        </td>
-        <td>{{t 'splash.userhome_test'}}</td>
-      </tr>
-
     </tbody>
   </table>
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/80adb61a/contrib/views/pig/src/main/resources/ui/pig-web/app/translations.js
----------------------------------------------------------------------
diff --git a/contrib/views/pig/src/main/resources/ui/pig-web/app/translations.js b/contrib/views/pig/src/main/resources/ui/pig-web/app/translations.js
index 151c88c..072b5c7 100644
--- a/contrib/views/pig/src/main/resources/ui/pig-web/app/translations.js
+++ b/contrib/views/pig/src/main/resources/ui/pig-web/app/translations.js
@@ -173,7 +173,6 @@ Ember.I18n.translations = {
     'please_wait':'Testing connection to services...please wait.',
     'storage_test':'Storage test',
     'hdfs_test':'HDFS test',
-    'webhcat_test':'WebHCat test',
-    'userhome_test':'User Home Directory test'
+    'webhcat_test':'WebHCat test'
   }
 };


Mime
View raw message