You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@stratos.apache.org by re...@apache.org on 2014/02/13 14:47:22 UTC

[1/2] git commit: fixing STRATOS-445

Updated Branches:
  refs/heads/master 856e8f3c1 -> aada5d63e


fixing STRATOS-445


Project: http://git-wip-us.apache.org/repos/asf/incubator-stratos/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-stratos/commit/9658bd52
Tree: http://git-wip-us.apache.org/repos/asf/incubator-stratos/tree/9658bd52
Diff: http://git-wip-us.apache.org/repos/asf/incubator-stratos/diff/9658bd52

Branch: refs/heads/master
Commit: 9658bd52a8dcc14d95fa718e6a3c4160a028e7de
Parents: c9e2dab
Author: rekathiru <rt...@gmail.com>
Authored: Thu Feb 13 19:17:00 2014 +0530
Committer: rekathiru <rt...@gmail.com>
Committed: Thu Feb 13 19:17:00 2014 +0530

----------------------------------------------------------------------
 .../console/util/utility.jag                    | 46 +++++++++++++-------
 1 file changed, 31 insertions(+), 15 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/9658bd52/components/org.apache.stratos.manager.console/console/util/utility.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/util/utility.jag b/components/org.apache.stratos.manager.console/console/util/utility.jag
index b4f38f8..2bc578c 100644
--- a/components/org.apache.stratos.manager.console/console/util/utility.jag
+++ b/components/org.apache.stratos.manager.console/console/util/utility.jag
@@ -183,17 +183,23 @@ consoleAppUtil = new function(){
     };
     this.getConfigStatus = function(){
         var configStatus = {};
-        if(this.sendReceive("GET","/partition",{}).data.partition.length == 0){
+        var get_status = session.get("get-status");
+        if(get_status == "succeeded") {
+            if(this.sendReceive("GET","/partition",{}).data.partition.length == 0){
             configStatus.first_use = true;
-        }else{
-            if(this.sendReceive("GET","/service",{}).data.serviceDefinitionBean.length == 0){
-                configStatus.first_use = false;
-                configStatus.not_complete = true;
             }else{
-                configStatus.not_complete = false;
-                configStatus.first_use = false;
+                if(this.sendReceive("GET","/service",{}).data.serviceDefinitionBean.length == 0){
+                    configStatus.first_use = false;
+                    configStatus.not_complete = true;
+                }else{
+                    configStatus.not_complete = false;
+                    configStatus.first_use = false;
+                }
             }
+        } else {
+
         }
+
         return configStatus;
     };
 
@@ -239,7 +245,11 @@ consoleAppUtil = new function(){
             default :
                 log.error("Error in the programme flow.");
         }
-        log.info("recieved data is: " + stringify(response.data));
+        if(response.data.Error) {
+            session.put("get-status", response.data.Error.errorMessage);
+        } else {
+            session.put("get-status", "succeeded");
+        }
         return response;
     };
 
@@ -253,23 +263,29 @@ consoleAppUtil = new function(){
         var response;
         switch (httpMethod){
             case  "GET":
-                response = get(endpoint,{},headers);
+                response = get(endpoint,{},headers, 'json');
                 break;
             case   "POST":
-                response = post(endpoint,data,headers);
+                response = post(endpoint,data,headers, 'json');
                 break;
             case    "PUT":
-                response = put(endpoint,data,headers);
+                response = put(endpoint,data,headers, 'json');
                 break;
             case    "DELETE":
-                response = del(endpoint,data,headers);
+                response = del(endpoint,data,headers, 'json');
                 break;
             default :
                 log.error("Error in the programme flow.");
         }
-        log.info("sent response is: " + stringify(response.data));
-        return response;
-    };
+        if(response.data.stratosAdminResponse) {
+            session.put("deploy-status", "succeeded");
+        } else if (response.data.Error) {
+            session.put("deploy-status", response.data.Error.errorMessage);
+        } else {
+            session.put("deploy-status", "Error occurred while deploying...");
+        }
+            return response;
+        };
 
 
 


[2/2] git commit: Merge branch 'master' of https://git-wip-us.apache.org/repos/asf/incubator-stratos

Posted by re...@apache.org.
Merge branch 'master' of https://git-wip-us.apache.org/repos/asf/incubator-stratos


Project: http://git-wip-us.apache.org/repos/asf/incubator-stratos/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-stratos/commit/aada5d63
Tree: http://git-wip-us.apache.org/repos/asf/incubator-stratos/tree/aada5d63
Diff: http://git-wip-us.apache.org/repos/asf/incubator-stratos/diff/aada5d63

Branch: refs/heads/master
Commit: aada5d63e58e3d82ca8a1525a6024d09b4fa852b
Parents: 9658bd5 856e8f3
Author: rekathiru <rt...@gmail.com>
Authored: Thu Feb 13 19:17:28 2014 +0530
Committer: rekathiru <rt...@gmail.com>
Committed: Thu Feb 13 19:17:28 2014 +0530

----------------------------------------------------------------------
 .../apache/stratos/cli/GenericRestClient.java   |   2 +-
 .../java/org/apache/stratos/cli/RestClient.java |   7 +-
 .../stratos/cli/RestCommandLineService.java     | 147 ++++++++-------
 .../apache/stratos/cli/StratosApplication.java  |  16 +-
 .../stratos/cli/beans/cartridge/Cartridge.java  |   9 +
 .../controller/pojo/PersistanceMapping.java     |  27 +--
 .../client/CloudControllerServiceClient.java    |   6 +-
 .../apache/stratos/manager/dto/Cartridge.java   |   8 +
 .../manager/CartridgeSubscriptionManager.java   | 102 ++++-------
 .../manager/service/RepositoryInfoBean.java     |   3 +-
 .../subscription/CartridgeSubscription.java     |  17 +-
 .../manager/subscription/SubscriptionData.java  | 180 +++++++++++++++++++
 .../utils/ApplicationManagementUtil.java        |   3 +-
 .../rest/endpoint/bean/CartridgeInfoBean.java   |  12 ++
 .../definition/PersistanceMappingBean.java      |   4 +-
 .../bean/util/converter/PojoConverter.java      |   2 +-
 .../rest/endpoint/services/ServiceUtils.java    | 137 ++++++++++----
 .../rest/endpoint/services/StratosAdmin.java    |  11 +-
 .../distribution/src/main/bin/stratos.sh        |   2 +-
 .../main/resources/CloudControllerService.wsdl  |   6 +-
 .../puppet/etc/puppet/files/cartridge-agent.sh  |  13 ++
 tools/puppet/manifests/classes/lb_cartridge.pp  |  12 +-
 tools/puppet/manifests/classes/mysql.pp         |   4 +-
 tools/puppet/manifests/classes/php_cartridge.pp |  12 +-
 tools/puppet/manifests/nodes.pp                 | 104 +++++++----
 tools/stratos-installer/README.txt              |  17 +-
 tools/stratos-installer/conf/setup.conf         |  52 +-----
 .../cc/repository/conf/cloud-controller.xml     |   1 -
 .../config/cep/repository/conf/jndi.properties  |  16 +-
 .../repository/conf/cartridge-config.properties |  27 ---
 tools/stratos-installer/ec2.sh                  |  12 --
 tools/stratos-installer/openstack.sh            |   9 -
 tools/stratos-installer/setup.sh                |  80 +++------
 33 files changed, 625 insertions(+), 435 deletions(-)
----------------------------------------------------------------------