You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@stratos.apache.org by la...@apache.org on 2014/12/11 07:50:49 UTC

[01/18] stratos git commit: add new workflow to menu.json

Repository: stratos
Updated Branches:
  refs/heads/4.1.0-test eb8224c46 -> c6f2dc31b


add new workflow to menu.json


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

Branch: refs/heads/4.1.0-test
Commit: 16ea8a553a0dc377fa5470e132a220d71bf867ad
Parents: ff1d57a
Author: Dakshika Jayathilaka <si...@gmail.com>
Authored: Wed Dec 10 13:19:01 2014 +0530
Committer: Dakshika Jayathilaka <si...@gmail.com>
Committed: Wed Dec 10 13:19:01 2014 +0530

----------------------------------------------------------------------
 .../console/controllers/menu/menu.json          | 56 ++++----------------
 1 file changed, 9 insertions(+), 47 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/16ea8a55/components/org.apache.stratos.manager.console/console/controllers/menu/menu.json
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/menu/menu.json b/components/org.apache.stratos.manager.console/console/controllers/menu/menu.json
index 7cc4d1f..e900040 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/menu/menu.json
+++ b/components/org.apache.stratos.manager.console/console/controllers/menu/menu.json
@@ -10,24 +10,6 @@
             "description": "Configure partitions, deployment and scaling policies, cartridges and manage docker groups",
             "sub-menu": [
                 {
-                    "link": "configure/partitions/",
-                    "linkexternal": false,
-                    "context": "/configure",
-                    "title": "Partitions",
-                    "icon": "fa-th-large",
-                    "permissionPaths": ["/permission", "/permission/admin"],
-                    "description": "Define partitions/partition groups to be used in autoscaling and deployment policies."
-                },
-                {
-                    "link": "configure/deployments/",
-                    "linkexternal": false,
-                    "context": "/configure",
-                    "title": "Deployment Policies",
-                    "icon": "fa-road",
-                    "permissionPaths": ["/permission", "/permission/admin", "/permission/admin/manage/view/deploymentpolicy"],
-                    "description": "Define specific policies for cartridge deployment."
-                },
-                {
                     "link": "configure/autoscalingpolicies/",
                     "linkexternal": false,
                     "context": "/configure",
@@ -37,15 +19,6 @@
                     "description": "Define policies which specify inbound requests, memory usage and CPU usage etc."
                 },
                 {
-                    "link": "configure/loadbalancer/",
-                    "linkexternal": false,
-                    "context": "/configure",
-                    "title": "Load Balancers",
-                    "icon": "fa-tasks",
-                    "permissionPaths": ["/permission", "/permission/admin"],
-                    "description": "Define load balancer for cartridges."
-                },
-                {
                     "link": "configure/cartridges/",
                     "linkexternal": false,
                     "context": "/configure",
@@ -63,17 +36,6 @@
                     "permissionPaths": ["/permission", "/permission/admin"],
                     "description": "Define and manage multitenant services."
                 }
-                /*     ,
-                 {
-                 "link": "configure/application/",
-                 "linkexternal":false,
-                 "context":"/configure",
-                 "title": "Application Deployment",
-                 "icon": "fa-archive ",
-                 "permissionPaths": ["/permission","/permission/admin"],
-                 "description": "Define and manage multitenant services."
-                 }
-                 */
             ]
         },
         {
@@ -131,18 +93,18 @@
                     "icon": "fa-archive",
                     "permissionPaths": ["/permission", "/permission/admin","/permission/admin/manage/view/subscription" ],
                     "description": "Add applications"
+                },
+                {
+                    "link": "applications/deployments/",
+                    "linkexternal": false,
+                    "context": "/applications",
+                    "title": "Deployment Policies",
+                    "icon": "fa-road",
+                    "permissionPaths": ["/permission", "/permission/admin", "/permission/admin/manage/view/deploymentpolicy"],
+                    "description": "Define specific policies for application deployment."
                 }
             ]
         },
-//        {
-//            "link": "mycartridges/",
-//            "linkexternal": false,
-//            "context": "/",
-//            "title": "Instances",
-//            "icon": "fa-inbox",
-//            "permissionPaths": ["/permission", "/permission/admin/manage/view/subscription"],
-//            "description": "Your Instances"
-//        },
         {
             "link": "https://issues.apache.org/jira/",
             "linkexternal": true,


[06/18] stratos git commit: fix cartridge definition with REST API changes

Posted by la...@apache.org.
fix cartridge definition  with REST API changes


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

Branch: refs/heads/4.1.0-test
Commit: d4da3e89989c3161b9f631262b1f910df0fd1243
Parents: 0d807d9
Author: Dakshika Jayathilaka <si...@gmail.com>
Authored: Wed Dec 10 16:56:31 2014 +0530
Committer: Dakshika Jayathilaka <si...@gmail.com>
Committed: Wed Dec 10 16:56:31 2014 +0530

----------------------------------------------------------------------
 .../console/controllers/rest/rest_calls.jag      | 19 ++-----------------
 1 file changed, 2 insertions(+), 17 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/d4da3e89/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
index cfc8fac..7a403de 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
+++ b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
@@ -23,18 +23,6 @@
 RESTCalls = new function(){
     var log = new Log('RESTCalls');
 
-    this.getAvailableSingleTenantCartridges = function(){
-        return this.sendReceive("GET","/cartridge/list",{});
-    };
-
-    this.getAvailableMultiTenantCartridges = function(){
-        return this.sendReceive("GET","/cartridge/tenanted/list",{});
-    };
-
-    this.getSubscribedCartridges = function(){
-        return this.sendReceive("GET","/cartridge/list/subscribed",{});
-    }
-
     this.getTenants = function(){
         return this.sendReceive("GET","/tenant/list",{});
     };
@@ -44,7 +32,7 @@ RESTCalls = new function(){
     };
 
     this.deployCartridgeDefinition = function(cartridgeDefinition){
-        return this.send("POST","/cartridge/definition",cartridgeDefinition);
+        return this.send("POST","/cartridges", cartridgeDefinition);
     };
 
     this.deployServiceDefinition = function(serviceDefinition){
@@ -139,7 +127,7 @@ RESTCalls = new function(){
         return this.send("POST","/cartridge/unsubscribe",alias);
     };
     this.getCartridges = function(){
-        return this.sendReceive("GET","/cartridge/available/list",{});
+        return this.sendReceive("GET","/cartridges",{});
     };
 
     this.getGroups = function(){
@@ -164,9 +152,6 @@ RESTCalls = new function(){
     this.getCartridgeInfo = function(alias){
         return this.sendReceive("GET","/cartridge/info/"+alias,{});
     };
-    this.getCartridgeServiceGroup = function(serviceGroup){
-        return this.sendReceive("GET","/cartridge/list/subscribed/group/"+serviceGroup,{});
-    };
     this.validateCaptcha = function(captchaText){
         return this.sendReceive("POST","/captcha",captchaText);
     };


[13/18] stratos git commit: fix groups with REST API

Posted by la...@apache.org.
fix groups with REST API


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

Branch: refs/heads/4.1.0-test
Commit: 767d0bbd1170c646e460662e14efae10101f6fe7
Parents: afbee0a
Author: Dakshika Jayathilaka <si...@gmail.com>
Authored: Thu Dec 11 10:10:43 2014 +0530
Committer: Dakshika Jayathilaka <si...@gmail.com>
Committed: Thu Dec 11 10:10:43 2014 +0530

----------------------------------------------------------------------
 .../console/controllers/rest/rest_calls.jag                        | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/767d0bbd/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
index 2e6913a..c02aca5 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
+++ b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
@@ -64,7 +64,7 @@ RESTCalls = new function(){
     };
 
     this.deployGroupDefinition = function(groupDefinition){
-        return this.send("POST","/group/definition", groupDefinition);
+        return this.send("POST","/groups", groupDefinition);
     };
 
     this.deployApplicationDefinition = function(applicationDefinition){


[11/18] stratos git commit: User delete option added

Posted by la...@apache.org.
User delete option added


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

Branch: refs/heads/4.1.0-test
Commit: 8a75e1e5e1ed99585cc891ae427238dcbdd7aae4
Parents: e2ef87a
Author: Dakshika Jayathilaka <si...@gmail.com>
Authored: Thu Dec 11 08:07:13 2014 +0530
Committer: Dakshika Jayathilaka <si...@gmail.com>
Committed: Thu Dec 11 08:07:13 2014 +0530

----------------------------------------------------------------------
 .../controllers/users/users_requests.jag        |  3 +-
 .../themes/theme0/partials/users_form.hbs       | 77 +++++++++++++++++---
 2 files changed, 68 insertions(+), 12 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/8a75e1e5/components/org.apache.stratos.manager.console/console/controllers/users/users_requests.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/users/users_requests.jag b/components/org.apache.stratos.manager.console/console/controllers/users/users_requests.jag
index b5c6c9e..a4eec80 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/users/users_requests.jag
+++ b/components/org.apache.stratos.manager.console/console/controllers/users/users_requests.jag
@@ -31,9 +31,10 @@ include('/controllers/login/validator.jag');
 try {
     if(formtype == 'users'){
         formSubmit = util.RESTCalls.addUser(JSON.parse(formPayload));
-
     }else if(formtype == 'tenants'){
         formSubmit = util.RESTCalls.addTenant(JSON.parse(formPayload));
+    }else if(formtype == 'deleteusers'){
+        formSubmit = util.RESTCalls.deleteUser(JSON.parse(formPayload));
     }
 
 }catch(e){

http://git-wip-us.apache.org/repos/asf/stratos/blob/8a75e1e5/components/org.apache.stratos.manager.console/console/themes/theme0/partials/users_form.hbs
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/themes/theme0/partials/users_form.hbs b/components/org.apache.stratos.manager.console/console/themes/theme0/partials/users_form.hbs
index c2c4317..697a48a 100644
--- a/components/org.apache.stratos.manager.console/console/themes/theme0/partials/users_form.hbs
+++ b/components/org.apache.stratos.manager.console/console/themes/theme0/partials/users_form.hbs
@@ -74,8 +74,21 @@
                         </div>
                         <h2>{{userName}} </h2>
 
-                        <div class="toggle-menu-description">{{role}}
+                        <div class="toggle-menu-description">{{role}}</div>
+                        {{#ifCond userName "!=" "admin"}}
+                        <div class="list-button" style="display: none;">
+                            <button class="btn btn-danger btn-lg hover-details" type="button" id="details_list_{{id}}"
+                                    data-user="{{userName}}" > Delete
+                            </button>
+                        </div>
+                        <div class="bottom-bar-wrapper">
+                            <div class="bottom-bar">
+                                <button class="btn btn-danger btn-lg hover-details" type="button" id="details_{{id}}"
+                                        data-user="{{userName}}" > Delete
+                                </button>
+                            </div>
                         </div>
+                        {{/ifCond}}
                     </div>
                 {{/each}}
                 {{#each content_body.sections.tenantInfoBean}}
@@ -126,17 +139,59 @@
                 // Get an array of errors from the validator
                 var errors = editor.validate();
                 //       var indicator = document.getElementById('valid_indicator');
+            });
+
+        {{else}}
+            $('.general-table .grid-group-item').hover(function () {
+                if($(this).hasClass('grid-group-item')) {
+                    $(this).find('.bottom-bar').stop().animate({bottom: '37px'}, 'slow');
+                }
+            }, function () {
+                if($(this).hasClass('grid-group-item')) {
+                    $(this).find('.bottom-bar').stop().animate({bottom: '-32px'}, 'slow');
+                }
+            });
 
-//        // Not valid
-//        if(errors.length) {
-//            indicator.className = 'label alert';
-//            indicator.textContent = 'not valid';
-//        }
-//        // Valid
-//        else {
-//            indicator.className = 'label success';
-//            indicator.textContent = 'valid';
-//        }
+            $('.general-table').on('click', '.hover-details', function (event) {
+                var payload =$(this).attr("data-user");
+                noty({
+                    layout: 'bottomRight',
+                    type: 'warning',
+                    text: 'Are you sure you want to delete user '+$(this).attr("data-user"),
+                    buttons: [
+                        {addClass: 'btn btn-primary', text: 'Yes', onClick: function($noty) {
+                            var formtype = 'deleteusers';
+                            $noty.close();
+
+                            $.ajax({
+                                type: "POST",
+                                url: caramel.context + "/controllers/users/users_requests.jag",
+                                dataType: 'json',
+                                data: { "formPayload": JSON.stringify(payload), "formtype": formtype },
+                                success: function (data) {
+                                    if (data.status == 'error') {
+                                        var n = noty({text: data.message, layout: 'bottomRight', type: 'error'});
+                                    } else if (data.status == 'warning') {
+                                        var n = noty({text: data.message, layout: 'bottomRight', type: 'warning'});
+                                    } else {
+                                        var n = noty({text: data.message, layout: 'bottomRight', type: 'success'});
+                                    }
+                                    window.setTimeout(function(){
+                                        location.reload();
+                                    }, 1000);
+                                }
+                                }).always(function () {
+
+                             });
+
+                        }
+                        },
+                        {addClass: 'btn btn-danger', text: 'No', onClick: function($noty) {
+                            $noty.close();
+                        }
+                        }
+                    ]
+                });
             });
         {{/if}}
 


[08/18] stratos git commit: fix docker(kubernetes) definition with REST API changes

Posted by la...@apache.org.
fix docker(kubernetes) definition  with REST API changes


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

Branch: refs/heads/4.1.0-test
Commit: 8220c67f9553f73ed2661e028e2992dd6b1410a7
Parents: 915b3e3
Author: Dakshika Jayathilaka <si...@gmail.com>
Authored: Wed Dec 10 17:10:38 2014 +0530
Committer: Dakshika Jayathilaka <si...@gmail.com>
Committed: Wed Dec 10 17:10:38 2014 +0530

----------------------------------------------------------------------
 .../console/configure_form.jag                                   | 4 ++--
 .../console/controllers/menu/menu.json                           | 2 +-
 .../console/controllers/rest/rest_calls.jag                      | 4 ++--
 3 files changed, 5 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/8220c67f/components/org.apache.stratos.manager.console/console/configure_form.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/configure_form.jag b/components/org.apache.stratos.manager.console/console/configure_form.jag
index d545d2d..495b4af 100644
--- a/components/org.apache.stratos.manager.console/console/configure_form.jag
+++ b/components/org.apache.stratos.manager.console/console/configure_form.jag
@@ -107,8 +107,8 @@ switch (formtype) {
 
     case "docker":
         list_data = util.RESTCalls.getKubernetesGroups();
-        if(list_data.kubernetesGroup && list_data.kubernetesGroup.length === 0){
-            list_data = null;
+        if(list_data == null){
+            list_data = null; //TODO endpoint doesn't return correct info
         }else{
             formDataEdit = list_data.kubernetesGroup;
             for (specNumber in list_data.kubernetesGroup) {

http://git-wip-us.apache.org/repos/asf/stratos/blob/8220c67f/components/org.apache.stratos.manager.console/console/controllers/menu/menu.json
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/menu/menu.json b/components/org.apache.stratos.manager.console/console/controllers/menu/menu.json
index e900040..7e9fdfd 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/menu/menu.json
+++ b/components/org.apache.stratos.manager.console/console/controllers/menu/menu.json
@@ -34,7 +34,7 @@
                     "title": "Docker Clusters",
                     "icon": "fa-sitemap",
                     "permissionPaths": ["/permission", "/permission/admin"],
-                    "description": "Define and manage multitenant services."
+                    "description": "Define and manage docker clusters."
                 }
             ]
         },

http://git-wip-us.apache.org/repos/asf/stratos/blob/8220c67f/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
index b8a3176..9b3fca4 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
+++ b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
@@ -56,7 +56,7 @@ RESTCalls = new function(){
     };
 
     this.deployKubernetesGroupDefinition = function(groupDefinition){
-        return this.send("POST","/kubernetes/deploy/group",groupDefinition);
+        return this.send("POST","/kubernetesClusters",groupDefinition);
     };
 
     this.deployGroupDefinition = function(groupDefinition){
@@ -93,7 +93,7 @@ RESTCalls = new function(){
     };
 
     this.getKubernetesGroups = function(){
-        return this.sendReceive("GET","/kubernetes/group",{});
+        return this.sendReceive("GET","/kubernetesClusters",{});
     };
 
     this.getApplicableDeploymentPolicies = function(cartridgeType){


[14/18] stratos git commit: fix Deployment policy for REST API changes

Posted by la...@apache.org.
fix Deployment policy for REST API changes


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

Branch: refs/heads/4.1.0-test
Commit: e1c536b777100b1c889ee110e78bff3e5d5665c7
Parents: 767d0bb
Author: Dakshika Jayathilaka <si...@gmail.com>
Authored: Thu Dec 11 10:39:42 2014 +0530
Committer: Dakshika Jayathilaka <si...@gmail.com>
Committed: Thu Dec 11 10:39:42 2014 +0530

----------------------------------------------------------------------
 .../console/controllers/rest/rest_calls.jag                      | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/e1c536b7/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
index c02aca5..4fac98f 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
+++ b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
@@ -52,7 +52,7 @@ RESTCalls = new function(){
     };
 
     this.deployDeploymentPolicyDefinition = function(policyDefinition){
-        return this.send("POST","/policy/deployment",policyDefinition);
+        return this.send("POST","/deploymentPolicies",policyDefinition);
     };
 
     this.deployAutoscalePolicyDefinition = function(policyDefinition){
@@ -117,7 +117,7 @@ RESTCalls = new function(){
     };
 
     this.getPolicyDeployment = function(){
-        return this.sendReceive("GET","/policy/deployment",{});
+        return this.sendReceive("GET","/deploymentPolicies",{});
     };
     this.unsubscribeCartridge = function(alias){
         return this.send("POST","/cartridge/unsubscribe",alias);


[17/18] stratos git commit: text changes on menu json

Posted by la...@apache.org.
text changes on menu json


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

Branch: refs/heads/4.1.0-test
Commit: bd932e21c39494326ec186e5f24f4ab419a94ff6
Parents: 5c5ba14
Author: Dakshika Jayathilaka <si...@gmail.com>
Authored: Thu Dec 11 11:28:27 2014 +0530
Committer: Dakshika Jayathilaka <si...@gmail.com>
Committed: Thu Dec 11 11:28:27 2014 +0530

----------------------------------------------------------------------
 .../console/controllers/menu/menu.json                         | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/bd932e21/components/org.apache.stratos.manager.console/console/controllers/menu/menu.json
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/menu/menu.json b/components/org.apache.stratos.manager.console/console/controllers/menu/menu.json
index 7e9fdfd..e972496 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/menu/menu.json
+++ b/components/org.apache.stratos.manager.console/console/controllers/menu/menu.json
@@ -7,7 +7,7 @@
             "title": "Configurations",
             "icon": "fa-gears",
             "permissionPaths": ["/permission", "/permission/admin"],
-            "description": "Configure partitions, deployment and scaling policies, cartridges and manage docker groups",
+            "description": "Configure Auto-scaling policies, cartridges and manage docker groups",
             "sub-menu": [
                 {
                     "link": "configure/autoscalingpolicies/",
@@ -80,10 +80,10 @@
                     "link": "applications/groups/",
                     "linkexternal": false,
                     "context": "/applications",
-                    "title": "Application Groups",
+                    "title": "Groups",
                     "icon": "fa-briefcase",
                     "permissionPaths": ["/permission", "/permission/admin", "/permission/admin/manage/view/subscription"],
-                    "description": "Add application groups."
+                    "description": "Add cartridge groups."
                 },
                 {
                     "link": "applications/applications/",


[02/18] stratos git commit: remove partitions from configurations

Posted by la...@apache.org.
remove partitions from configurations


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

Branch: refs/heads/4.1.0-test
Commit: 118078644c8bc0e666a8370df6c5397c104fa613
Parents: 16ea8a5
Author: Dakshika Jayathilaka <si...@gmail.com>
Authored: Wed Dec 10 14:02:11 2014 +0530
Committer: Dakshika Jayathilaka <si...@gmail.com>
Committed: Wed Dec 10 14:02:11 2014 +0530

----------------------------------------------------------------------
 .../console/configure_form.jag                       | 15 ---------------
 .../controllers/configure/configure_requests.jag     |  3 ---
 .../console/controllers/rest/rest_calls.jag          |  8 --------
 3 files changed, 26 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/11807864/components/org.apache.stratos.manager.console/console/configure_form.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/configure_form.jag b/components/org.apache.stratos.manager.console/console/configure_form.jag
index 83e7892..cb56aca 100644
--- a/components/org.apache.stratos.manager.console/console/configure_form.jag
+++ b/components/org.apache.stratos.manager.console/console/configure_form.jag
@@ -69,21 +69,6 @@ if (elements.action != 'new' && isEdit) {
 var formtype = elements.formtype;
 
 switch (formtype) {
-    case "partitions":
-        list_data = util.RESTCalls.getPartitions();
-        if (list_data.partition && list_data.partition.length === 0) {
-            list_data = null;
-        } else {
-            formDataEdit = list_data.partition;
-            for (specNumber in list_data.partition) {
-                if (list_data.partition[specNumber].id == elements.action) {
-                    formDataEdit = list_data.partition[specNumber];
-                }
-
-            }
-
-        }
-        break;
 
     case "autoscalingpolicies":
         list_data = util.RESTCalls.getPolicyAutoScale();

http://git-wip-us.apache.org/repos/asf/stratos/blob/11807864/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag b/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag
index 593a734..30b2263 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag
+++ b/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag
@@ -30,9 +30,6 @@ include('/controllers/login/validator.jag');
 
 try {
     switch (formtype) {
-        case "partitions":
-            formSubmit = util.RESTCalls.deployPartitionDefinition(formPayload);
-            break;
         case "autoscalingpolicies":
             formSubmit = util.RESTCalls.deployAutoscalePolicyDefinition(formPayload);
             break;

http://git-wip-us.apache.org/repos/asf/stratos/blob/11807864/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
index 331d3a8..5292321 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
+++ b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
@@ -71,10 +71,6 @@ RESTCalls = new function(){
         return this.send("POST","/tenant/availability/" + tenantDomain,{});
     };
 
-    this.deployPartitionDefinition = function(partitionDefinition){
-        return this.send("POST","/policy/deployment/partition",partitionDefinition);
-    };
-
     this.deployDeploymentPolicyDefinition = function(policyDefinition){
         return this.send("POST","/policy/deployment",policyDefinition);
     };
@@ -128,10 +124,6 @@ RESTCalls = new function(){
         return this.sendReceive("GET","/" + cartridgeType + "/policy/deployment/",{});
     };
 
-    this.getPartitions = function(){
-        return this.sendReceive("GET","/partition",{});
-    };
-
     this.getSingleTenantCartridgeInfo = function(cartridgeType){
         return this.sendReceive("GET","/cartridge/available/info/" + cartridgeType,{});
     };


[16/18] stratos git commit: fix issues on Application adding with REST API changes

Posted by la...@apache.org.
fix issues on Application adding with REST API changes


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

Branch: refs/heads/4.1.0-test
Commit: 5c5ba142f5ae068694864779fd61211c9c5c5771
Parents: 97295ac
Author: Dakshika Jayathilaka <si...@gmail.com>
Authored: Thu Dec 11 11:17:22 2014 +0530
Committer: Dakshika Jayathilaka <si...@gmail.com>
Committed: Thu Dec 11 11:17:22 2014 +0530

----------------------------------------------------------------------
 .../console/applications_form.jag                              | 2 +-
 .../console/controllers/rest/rest_calls.jag                    | 6 +++---
 2 files changed, 4 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/5c5ba142/components/org.apache.stratos.manager.console/console/applications_form.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/applications_form.jag b/components/org.apache.stratos.manager.console/console/applications_form.jag
index 6402620..c4f5b6a 100644
--- a/components/org.apache.stratos.manager.console/console/applications_form.jag
+++ b/components/org.apache.stratos.manager.console/console/applications_form.jag
@@ -86,7 +86,7 @@ switch (formtype) {
         }
         break;
     case "deployments":
-        list_data = util.RESTCalls.getPolicyDeployment();
+        list_data = util.RESTCalls.getPolicyDeployment(); //TODO fix with correct JSON
         if(list_data == null) {
             list_data = null;
         }else{

http://git-wip-us.apache.org/repos/asf/stratos/blob/5c5ba142/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
index 4fac98f..dab4509 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
+++ b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
@@ -68,7 +68,7 @@ RESTCalls = new function(){
     };
 
     this.deployApplicationDefinition = function(applicationDefinition){
-        return this.send("POST","/application/definition", applicationDefinition);
+        return this.send("POST","/applications", applicationDefinition);
     };
 
     this.subscribeToCartridge = function(cartridgeBeanInfo){
@@ -131,11 +131,11 @@ RESTCalls = new function(){
     };
 
     this.getApplications = function(){
-        return this.sendReceive("GET","/application",{});
+        return this.sendReceive("GET","/applications",{});
     };
 
     this.getApplicationTopology = function(appId){
-        return this.sendReceive("GET","/application/" + appId,{});
+        return this.sendReceive("GET","/applications/" + appId,{});
     };
 
     this.getClusterInfo = function(clusterId){


[15/18] stratos git commit: Depoloyment policy added to application section

Posted by la...@apache.org.
Depoloyment policy added to application section


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

Branch: refs/heads/4.1.0-test
Commit: 97295ac9913e68baf7fba275898163c9a156e8d6
Parents: e1c536b
Author: Dakshika Jayathilaka <si...@gmail.com>
Authored: Thu Dec 11 10:40:21 2014 +0530
Committer: Dakshika Jayathilaka <si...@gmail.com>
Committed: Thu Dec 11 10:40:21 2014 +0530

----------------------------------------------------------------------
 .../console/applications_form.jag               |  15 +++
 .../applications/application_requests.jag       |   3 +
 .../forms/default/applications/deployments.json |  17 +++
 .../forms/default/configure/deployments.json    |  17 ---
 .../forms/schema/applications/deployments.json  | 103 +++++++++++++++++++
 .../forms/schema/configure/deployments.json     | 103 -------------------
 6 files changed, 138 insertions(+), 120 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/97295ac9/components/org.apache.stratos.manager.console/console/applications_form.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/applications_form.jag b/components/org.apache.stratos.manager.console/console/applications_form.jag
index cd24ef1..6402620 100644
--- a/components/org.apache.stratos.manager.console/console/applications_form.jag
+++ b/components/org.apache.stratos.manager.console/console/applications_form.jag
@@ -85,6 +85,21 @@ switch (formtype) {
             list_data = null;
         }
         break;
+    case "deployments":
+        list_data = util.RESTCalls.getPolicyDeployment();
+        if(list_data == null) {
+            list_data = null;
+        }else{
+            formDataEdit = list_data.deploymentPolicy;
+            for (specNumber in list_data.deploymentPolicy) {
+                if (list_data.deploymentPolicy[specNumber].id == elements.action) {
+                    formDataEdit = list_data.deploymentPolicy[specNumber];
+                }
+
+            }
+            //TODO need to add listing with corrected JSON
+        }
+        break;
     default:
         error.push({"errorMessage":"Incorrect resource path found"});
 }

http://git-wip-us.apache.org/repos/asf/stratos/blob/97295ac9/components/org.apache.stratos.manager.console/console/controllers/applications/application_requests.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/applications/application_requests.jag b/components/org.apache.stratos.manager.console/console/controllers/applications/application_requests.jag
index bde0b9e..6d583b0 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/applications/application_requests.jag
+++ b/components/org.apache.stratos.manager.console/console/controllers/applications/application_requests.jag
@@ -36,6 +36,9 @@ try {
         case "applications":
             formSubmit = util.RESTCalls.deployApplicationDefinition(formPayload);
             break;
+        case "deployments":
+            formSubmit = util.RESTCalls.deployDeploymentPolicyDefinition(formPayload);
+            break;
         default:
             session.put("deploy-status", { "message": "Sorry Endpoint Error", "status": "error" });
 

http://git-wip-us.apache.org/repos/asf/stratos/blob/97295ac9/components/org.apache.stratos.manager.console/console/controllers/forms/default/applications/deployments.json
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/forms/default/applications/deployments.json b/components/org.apache.stratos.manager.console/console/controllers/forms/default/applications/deployments.json
new file mode 100644
index 0000000..feb94cb
--- /dev/null
+++ b/components/org.apache.stratos.manager.console/console/controllers/forms/default/applications/deployments.json
@@ -0,0 +1,17 @@
+{
+    "id":"dakshika-ec2",
+    "description":"Deployment policy description",
+    "isPublic":false,
+    "partitionGroup":{
+        "id":"ec2",
+        "partitionAlgo":"one-after-another",
+        "partition":[
+            {
+                "id":"P1",
+                "description":"description",
+                "partitionMax":"3",
+                "partitionMin":"1"
+            }
+        ]
+    }
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/stratos/blob/97295ac9/components/org.apache.stratos.manager.console/console/controllers/forms/default/configure/deployments.json
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/forms/default/configure/deployments.json b/components/org.apache.stratos.manager.console/console/controllers/forms/default/configure/deployments.json
deleted file mode 100644
index feb94cb..0000000
--- a/components/org.apache.stratos.manager.console/console/controllers/forms/default/configure/deployments.json
+++ /dev/null
@@ -1,17 +0,0 @@
-{
-    "id":"dakshika-ec2",
-    "description":"Deployment policy description",
-    "isPublic":false,
-    "partitionGroup":{
-        "id":"ec2",
-        "partitionAlgo":"one-after-another",
-        "partition":[
-            {
-                "id":"P1",
-                "description":"description",
-                "partitionMax":"3",
-                "partitionMin":"1"
-            }
-        ]
-    }
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/stratos/blob/97295ac9/components/org.apache.stratos.manager.console/console/controllers/forms/schema/applications/deployments.json
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/forms/schema/applications/deployments.json b/components/org.apache.stratos.manager.console/console/controllers/forms/schema/applications/deployments.json
new file mode 100644
index 0000000..c73b81f
--- /dev/null
+++ b/components/org.apache.stratos.manager.console/console/controllers/forms/schema/applications/deployments.json
@@ -0,0 +1,103 @@
+{
+    "type":"object",
+    "$schema": "http://json-schema.org/draft-04/schema",
+    "id": "root",
+    "title": "Deployment Definition",
+    "name": "Deployment Policy",
+    "options": {
+        "disable_properties": true,
+        "disable_collapse": true
+    },
+    "required":["id","partitionGroup"],
+    "properties":{
+        "id": {
+            "type":"string",
+            "id": "root/id",
+            "title": "Deployment Policy ID",
+            "name": "Deployment Policy ID",
+            "default": "isuruh-ec2",
+            "maxItems":1
+        },
+        "description": {
+            "type":"string",
+            "id": "root/description",
+            "title": "Description",
+            "name": "Description",
+            "maxItems":1
+        },
+        "isPublic": {
+            "type":"boolean",
+            "id": "root/isPublic",
+            "title": "Is Public",
+            "name": "Is Public",
+            "default": false,
+            "maxItems":1
+        },
+        "partitionGroup": {
+            "type":"object",
+            "id": "root/partitionGroup",
+            "title": "Partition Group",
+            "name": "Partition Group",
+            "required":["id","partitionAlgo","partition"],
+            "properties":{
+                "id": {
+                    "type":"string",
+                    "id": "root/partitionGroup/id",
+                    "title": "Partition Group ID",
+                    "name": "Partition Group ID",
+                    "default": "ec2",
+                    "maxItems":1
+                },
+                "partitionAlgo": {
+                    "type":"string",
+                    "id": "root/partitionGroup/partitionAlgo",
+                    "title": "Partition Algorithm",
+                    "name": "Partition Algorithm",
+                    "default": "one-after-another",
+                    "enum": ["round-robin", "one-after-another"],
+                    "maxItems":1
+                },
+                "partition": {
+                    "type":"array",
+                    "id": "root/partitionGroup/partition",
+                    "title": "Partition",
+                    "name": "Partition",
+                    "minItems":1,
+                    "items":
+                    {
+                        "type":"object",
+                        "id": "root/partitionGroup/partition/0",
+                        "required":["id","partitionMin","partitionMax"],
+                        "format": "grid",
+                        "properties":{
+                            "id": {
+                                "type":"string",
+                                "id": "root/partitionGroup/partition/0/id",
+                                "default": "P1",
+
+                            },
+                            "partitionMax": {
+                                "type":"string",
+                                "id": "root/partitionGroup/partition/0/partitionMax",
+                                "default": "3",
+                            },
+                            "partitionMin": {
+                                "type":"string",
+                                "id": "root/partitionGroup/partition/0/partitionMin",
+                                "default": "1",
+                            },
+                            "description": {
+                                "type": "string",
+                                "id": "root/partitionGroup/partition/0/description",
+                                "default": "description",
+
+                            }
+                        }
+                    }
+
+
+                }
+            }
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/stratos/blob/97295ac9/components/org.apache.stratos.manager.console/console/controllers/forms/schema/configure/deployments.json
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/forms/schema/configure/deployments.json b/components/org.apache.stratos.manager.console/console/controllers/forms/schema/configure/deployments.json
deleted file mode 100644
index c73b81f..0000000
--- a/components/org.apache.stratos.manager.console/console/controllers/forms/schema/configure/deployments.json
+++ /dev/null
@@ -1,103 +0,0 @@
-{
-    "type":"object",
-    "$schema": "http://json-schema.org/draft-04/schema",
-    "id": "root",
-    "title": "Deployment Definition",
-    "name": "Deployment Policy",
-    "options": {
-        "disable_properties": true,
-        "disable_collapse": true
-    },
-    "required":["id","partitionGroup"],
-    "properties":{
-        "id": {
-            "type":"string",
-            "id": "root/id",
-            "title": "Deployment Policy ID",
-            "name": "Deployment Policy ID",
-            "default": "isuruh-ec2",
-            "maxItems":1
-        },
-        "description": {
-            "type":"string",
-            "id": "root/description",
-            "title": "Description",
-            "name": "Description",
-            "maxItems":1
-        },
-        "isPublic": {
-            "type":"boolean",
-            "id": "root/isPublic",
-            "title": "Is Public",
-            "name": "Is Public",
-            "default": false,
-            "maxItems":1
-        },
-        "partitionGroup": {
-            "type":"object",
-            "id": "root/partitionGroup",
-            "title": "Partition Group",
-            "name": "Partition Group",
-            "required":["id","partitionAlgo","partition"],
-            "properties":{
-                "id": {
-                    "type":"string",
-                    "id": "root/partitionGroup/id",
-                    "title": "Partition Group ID",
-                    "name": "Partition Group ID",
-                    "default": "ec2",
-                    "maxItems":1
-                },
-                "partitionAlgo": {
-                    "type":"string",
-                    "id": "root/partitionGroup/partitionAlgo",
-                    "title": "Partition Algorithm",
-                    "name": "Partition Algorithm",
-                    "default": "one-after-another",
-                    "enum": ["round-robin", "one-after-another"],
-                    "maxItems":1
-                },
-                "partition": {
-                    "type":"array",
-                    "id": "root/partitionGroup/partition",
-                    "title": "Partition",
-                    "name": "Partition",
-                    "minItems":1,
-                    "items":
-                    {
-                        "type":"object",
-                        "id": "root/partitionGroup/partition/0",
-                        "required":["id","partitionMin","partitionMax"],
-                        "format": "grid",
-                        "properties":{
-                            "id": {
-                                "type":"string",
-                                "id": "root/partitionGroup/partition/0/id",
-                                "default": "P1",
-
-                            },
-                            "partitionMax": {
-                                "type":"string",
-                                "id": "root/partitionGroup/partition/0/partitionMax",
-                                "default": "3",
-                            },
-                            "partitionMin": {
-                                "type":"string",
-                                "id": "root/partitionGroup/partition/0/partitionMin",
-                                "default": "1",
-                            },
-                            "description": {
-                                "type": "string",
-                                "id": "root/partitionGroup/partition/0/description",
-                                "default": "description",
-
-                            }
-                        }
-                    }
-
-
-                }
-            }
-        }
-    }
-}


[05/18] stratos git commit: remove LB definition from configuration section

Posted by la...@apache.org.
remove LB definition from configuration section


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

Branch: refs/heads/4.1.0-test
Commit: 0d807d9c1e85a64710fe7bc673631992cae50113
Parents: 6f20cbe
Author: Dakshika Jayathilaka <si...@gmail.com>
Authored: Wed Dec 10 16:42:23 2014 +0530
Committer: Dakshika Jayathilaka <si...@gmail.com>
Committed: Wed Dec 10 16:42:23 2014 +0530

----------------------------------------------------------------------
 .../console/configure_form.jag                       | 15 ---------------
 .../controllers/configure/configure_requests.jag     |  3 ---
 .../console/controllers/rest/rest_calls.jag          | 12 ------------
 3 files changed, 30 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/0d807d9c/components/org.apache.stratos.manager.console/console/configure_form.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/configure_form.jag b/components/org.apache.stratos.manager.console/console/configure_form.jag
index 4464298..58b0651 100644
--- a/components/org.apache.stratos.manager.console/console/configure_form.jag
+++ b/components/org.apache.stratos.manager.console/console/configure_form.jag
@@ -85,21 +85,6 @@ switch (formtype) {
         }
         break;
 
-    case "loadbalancer":
-        list_data = util.RESTCalls.getLbCartridges();
-        if (list_data.cartridge && list_data.cartridge.length === 0) {
-            list_data = null;
-        }else{
-            formDataEdit = list_data.cartridge;
-            for (specNumber in list_data.cartridge) {
-                if (list_data.cartridge[specNumber].cartridgeType == elements.action) {
-                    formDataEdit = list_data.cartridge[specNumber];
-                }
-
-            }
-        }
-        break;
-
     case "cartridges":
         list_data = util.RESTCalls.getCartridges();
 

http://git-wip-us.apache.org/repos/asf/stratos/blob/0d807d9c/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag b/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag
index feb01cd..38717dc 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag
+++ b/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag
@@ -33,9 +33,6 @@ try {
         case "autoscalingpolicies":
             formSubmit = util.RESTCalls.deployAutoscalePolicyDefinition(formPayload);
             break;
-        case "loadbalancer":
-            formSubmit = util.RESTCalls.deployLbDefinition(formPayload);
-            break;
         case "cartridges":
             formSubmit = util.RESTCalls.deployCartridgeDefinition(formPayload);
             break;

http://git-wip-us.apache.org/repos/asf/stratos/blob/0d807d9c/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
index 77cce58..cfc8fac 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
+++ b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
@@ -51,10 +51,6 @@ RESTCalls = new function(){
         return this.send("POST","/service/definition",serviceDefinition);
     };
 
-    this.deployLbDefinition = function(lbDefinition){
-        return this.send("POST","/cartridge/definition",lbDefinition);
-    };
-
     this.activateTenant = function(tenantDomain){
         return this.send("POST","/tenant/activate/" + tenantDomain,{});
     };
@@ -146,10 +142,6 @@ RESTCalls = new function(){
         return this.sendReceive("GET","/cartridge/available/list",{});
     };
 
-    this.getLbCartridges = function(){
-        return this.sendReceive("GET","/cartridge/lb",{});
-    };
-
     this.getGroups = function(){
         return this.sendReceive("GET","/groups",{});
     };
@@ -166,10 +158,6 @@ RESTCalls = new function(){
         return this.sendReceive("GET","/cluster/clusterId/" + clusterId,{});
     };
 
-    this.getLBClusterInfo = function(){
-        return this.sendReceive("GET","/cluster/lb",{});
-    };
-
     this.getClusterInfoWithAlias = function(cartridgeType, alias){
         return this.sendReceive("GET","/cluster/" + cartridgeType + "/" + alias,{});
     };


[04/18] stratos git commit: remove deployment policies from configuration section

Posted by la...@apache.org.
remove deployment policies from configuration section


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

Branch: refs/heads/4.1.0-test
Commit: 6f20cbe96294f404686ea78e46a169def831dc73
Parents: e6d8c6a
Author: Dakshika Jayathilaka <si...@gmail.com>
Authored: Wed Dec 10 16:23:29 2014 +0530
Committer: Dakshika Jayathilaka <si...@gmail.com>
Committed: Wed Dec 10 16:23:29 2014 +0530

----------------------------------------------------------------------
 .../console/configure_form.jag                  | 22 --------------------
 .../configure/configure_requests.jag            |  3 ---
 2 files changed, 25 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/6f20cbe9/components/org.apache.stratos.manager.console/console/configure_form.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/configure_form.jag b/components/org.apache.stratos.manager.console/console/configure_form.jag
index cb56aca..4464298 100644
--- a/components/org.apache.stratos.manager.console/console/configure_form.jag
+++ b/components/org.apache.stratos.manager.console/console/configure_form.jag
@@ -85,28 +85,6 @@ switch (formtype) {
         }
         break;
 
-    case "deployments":
-        list_data = util.RESTCalls.getPolicyDeployment();
-        if(list_data == null) {
-            list_data = util.RESTCalls.getPartitions()
-            if(list_data.partition && list_data.partition.length === 0){
-                list_data = null;
-                dependancy = 'partitions';
-            }else{
-                list_data = null;
-            }
-        }else{
-            formDataEdit = list_data.deploymentPolicy;
-            for (specNumber in list_data.deploymentPolicy) {
-                if (list_data.deploymentPolicy[specNumber].id == elements.action) {
-                    formDataEdit = list_data.deploymentPolicy[specNumber];
-                }
-
-            }
-            //TODO need to add listing with corrected JSON
-        }
-        break;
-
     case "loadbalancer":
         list_data = util.RESTCalls.getLbCartridges();
         if (list_data.cartridge && list_data.cartridge.length === 0) {

http://git-wip-us.apache.org/repos/asf/stratos/blob/6f20cbe9/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag b/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag
index 30b2263..feb01cd 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag
+++ b/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag
@@ -33,9 +33,6 @@ try {
         case "autoscalingpolicies":
             formSubmit = util.RESTCalls.deployAutoscalePolicyDefinition(formPayload);
             break;
-        case "deployments":
-            formSubmit = util.RESTCalls.deployDeploymentPolicyDefinition(formPayload);
-            break;
         case "loadbalancer":
             formSubmit = util.RESTCalls.deployLbDefinition(formPayload);
             break;


[09/18] stratos git commit: fix user definition with REST API changes

Posted by la...@apache.org.
fix user definition  with REST API changes


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

Branch: refs/heads/4.1.0-test
Commit: 98b5ed5a3b28f19839843c3f17c0080f6c7def89
Parents: 8220c67
Author: Dakshika Jayathilaka <si...@gmail.com>
Authored: Wed Dec 10 17:26:48 2014 +0530
Committer: Dakshika Jayathilaka <si...@gmail.com>
Committed: Wed Dec 10 17:26:48 2014 +0530

----------------------------------------------------------------------
 .../console/controllers/rest/rest_calls.jag                      | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/98b5ed5a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
index 9b3fca4..4481167 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
+++ b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
@@ -77,7 +77,7 @@ RESTCalls = new function(){
 
 
     this.addUser = function(userInfoBean){
-        return this.sendReceive("POST","/user", userInfoBean);
+        return this.sendReceive("POST","/users", userInfoBean);
     };
 
     this.syncRepo = function(alias){
@@ -154,7 +154,7 @@ RESTCalls = new function(){
         return this.sendReceive("DELETE","/cartridge/definition/"+cartridgeType,{});
     };
     this.getUserList = function(){
-        return this.sendReceive("GET", "/user/list", {});
+        return this.sendReceive("GET", "/users", {});
     }
     this.getConfigStatus = function(){
         var configStatus = {};


[03/18] stratos git commit: fix autoscaling policies with REST API changes

Posted by la...@apache.org.
fix autoscaling policies with REST API changes


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

Branch: refs/heads/4.1.0-test
Commit: e6d8c6a489df92fa9b012bc14f82041251a149ae
Parents: 1180786
Author: Dakshika Jayathilaka <si...@gmail.com>
Authored: Wed Dec 10 14:14:05 2014 +0530
Committer: Dakshika Jayathilaka <si...@gmail.com>
Committed: Wed Dec 10 14:14:05 2014 +0530

----------------------------------------------------------------------
 .../console/controllers/rest/rest_calls.jag                      | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/e6d8c6a4/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
index 5292321..77cce58 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
+++ b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
@@ -76,7 +76,7 @@ RESTCalls = new function(){
     };
 
     this.deployAutoscalePolicyDefinition = function(policyDefinition){
-        return this.send("POST","/policy/autoscale",policyDefinition);
+        return this.send("POST","/autoscalingPolicies",policyDefinition);
     };
 
     this.deployKubernetesGroupDefinition = function(groupDefinition){
@@ -133,7 +133,7 @@ RESTCalls = new function(){
     };
 
     this.getPolicyAutoScale = function(){
-        return this.sendReceive("GET","/policy/autoscale",{});
+        return this.sendReceive("GET","/autoscalingPolicies",{});
     };
 
     this.getPolicyDeployment = function(){


[12/18] stratos git commit: update tenant section with new REST API

Posted by la...@apache.org.
 update tenant section with new REST API


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

Branch: refs/heads/4.1.0-test
Commit: afbee0ac160c7c5964523db80982621452e1d2d0
Parents: 8a75e1e
Author: Dakshika Jayathilaka <si...@gmail.com>
Authored: Thu Dec 11 08:30:38 2014 +0530
Committer: Dakshika Jayathilaka <si...@gmail.com>
Committed: Thu Dec 11 08:30:38 2014 +0530

----------------------------------------------------------------------
 .../console/controllers/rest/rest_calls.jag                      | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/afbee0ac/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
index 60abd4b..2e6913a 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
+++ b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
@@ -24,7 +24,7 @@ RESTCalls = new function(){
     var log = new Log('RESTCalls');
 
     this.getTenants = function(){
-        return this.sendReceive("GET","/tenant/list",{});
+        return this.sendReceive("GET","/tenants",{});
     };
 
     this.deployCartridgeDefinition = function(cartridgeDefinition){
@@ -76,7 +76,7 @@ RESTCalls = new function(){
     };
 
     this.addTenant = function(tenantInfoBean){
-        return this.sendReceive("POST","/tenant",tenantInfoBean);
+        return this.sendReceive("POST","/tenants",tenantInfoBean);
     };
 
 


[10/18] stratos git commit: update user section with new REST API

Posted by la...@apache.org.
update user section with new REST API


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

Branch: refs/heads/4.1.0-test
Commit: e2ef87a659d6bacdb066674fe597281b145a28d8
Parents: 98b5ed5
Author: Dakshika Jayathilaka <si...@gmail.com>
Authored: Thu Dec 11 08:05:43 2014 +0530
Committer: Dakshika Jayathilaka <si...@gmail.com>
Committed: Thu Dec 11 08:05:43 2014 +0530

----------------------------------------------------------------------
 .../console/controllers/rest/rest_calls.jag                      | 4 ++++
 1 file changed, 4 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/e2ef87a6/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
index 4481167..60abd4b 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
+++ b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
@@ -43,6 +43,10 @@ RESTCalls = new function(){
         return this.send("DELETE","/tenant/" + tenantDomain,{});
     };
 
+    this.deleteUser = function(userName){
+        return this.send("DELETE","/users/" + userName,{});
+    };
+
     this.checkAvailability = function(tenantDomain){
         return this.send("POST","/tenant/availability/" + tenantDomain,{});
     };


[07/18] stratos git commit: remove multitenant definition from configuration section

Posted by la...@apache.org.
remove multitenant definition from configuration section


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

Branch: refs/heads/4.1.0-test
Commit: 915b3e3becebc1e3525975de9d3db92f51f2fbac
Parents: d4da3e8
Author: Dakshika Jayathilaka <si...@gmail.com>
Authored: Wed Dec 10 17:01:46 2014 +0530
Committer: Dakshika Jayathilaka <si...@gmail.com>
Committed: Wed Dec 10 17:01:46 2014 +0530

----------------------------------------------------------------------
 .../console/configure_form.jag                               | 7 -------
 .../console/controllers/configure/configure_requests.jag     | 3 ---
 .../console/controllers/rest/rest_calls.jag                  | 8 --------
 3 files changed, 18 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/915b3e3b/components/org.apache.stratos.manager.console/console/configure_form.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/configure_form.jag b/components/org.apache.stratos.manager.console/console/configure_form.jag
index 58b0651..d545d2d 100644
--- a/components/org.apache.stratos.manager.console/console/configure_form.jag
+++ b/components/org.apache.stratos.manager.console/console/configure_form.jag
@@ -105,13 +105,6 @@ switch (formtype) {
         }
         break;
 
-    case "multitenant":
-        list_data = util.RESTCalls.getServices();
-        if (list_data.serviceDefinitionBean && list_data.serviceDefinitionBean.length === 0) {
-            list_data = null;
-        }
-        break;
-
     case "docker":
         list_data = util.RESTCalls.getKubernetesGroups();
         if(list_data.kubernetesGroup && list_data.kubernetesGroup.length === 0){

http://git-wip-us.apache.org/repos/asf/stratos/blob/915b3e3b/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag b/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag
index 38717dc..8d6690e 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag
+++ b/components/org.apache.stratos.manager.console/console/controllers/configure/configure_requests.jag
@@ -36,9 +36,6 @@ try {
         case "cartridges":
             formSubmit = util.RESTCalls.deployCartridgeDefinition(formPayload);
             break;
-        case "multitenant":
-            formSubmit = util.RESTCalls.deployServiceDefinition(formPayload);
-            break;
         case "docker":
             formSubmit = util.RESTCalls.deployKubernetesGroupDefinition(formPayload);
             break;

http://git-wip-us.apache.org/repos/asf/stratos/blob/915b3e3b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
index 7a403de..b8a3176 100644
--- a/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
+++ b/components/org.apache.stratos.manager.console/console/controllers/rest/rest_calls.jag
@@ -27,18 +27,10 @@ RESTCalls = new function(){
         return this.sendReceive("GET","/tenant/list",{});
     };
 
-    this.getServices = function(){
-        return this.sendReceive("GET","/service",{});
-    };
-
     this.deployCartridgeDefinition = function(cartridgeDefinition){
         return this.send("POST","/cartridges", cartridgeDefinition);
     };
 
-    this.deployServiceDefinition = function(serviceDefinition){
-        return this.send("POST","/service/definition",serviceDefinition);
-    };
-
     this.activateTenant = function(tenantDomain){
         return this.send("POST","/tenant/activate/" + tenantDomain,{});
     };


[18/18] stratos git commit: Merge branch 'flow-fix' of https://github.com/dakshika/stratos into 4.1.0-test

Posted by la...@apache.org.
Merge branch 'flow-fix' of https://github.com/dakshika/stratos into 4.1.0-test


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

Branch: refs/heads/4.1.0-test
Commit: c6f2dc31b2ddb2cdf285370b2e023ee46f243fe7
Parents: eb8224c bd932e2
Author: Lahiru Sandaruwan <la...@apache.org>
Authored: Thu Dec 11 12:22:33 2014 +0530
Committer: Lahiru Sandaruwan <la...@apache.org>
Committed: Thu Dec 11 12:22:33 2014 +0530

----------------------------------------------------------------------
 .../console/applications_form.jag               |  15 +++
 .../console/configure_form.jag                  |  63 +-----------
 .../applications/application_requests.jag       |   3 +
 .../configure/configure_requests.jag            |  12 ---
 .../forms/default/applications/deployments.json |  17 +++
 .../forms/default/configure/deployments.json    |  17 ---
 .../forms/schema/applications/deployments.json  | 103 +++++++++++++++++++
 .../forms/schema/configure/deployments.json     | 103 -------------------
 .../console/controllers/menu/menu.json          |  64 +++---------
 .../console/controllers/rest/rest_calls.jag     |  79 ++++----------
 .../controllers/users/users_requests.jag        |   3 +-
 .../themes/theme0/partials/users_form.hbs       |  77 ++++++++++++--
 12 files changed, 241 insertions(+), 315 deletions(-)
----------------------------------------------------------------------