From 96e8753e5647100138b87ae27036e407a0cef818 Mon Sep 17 00:00:00 2001 From: Andrew MacBean Date: Wed, 30 Jul 2014 12:57:04 +0000 Subject: QPID-5928: [Java Broker] Further enhancements and feedback changes for initial implementation git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1614644 13f79535-47bb-0310-9956-ffa450edef68 --- .../js/qpid/management/virtualhost/bdb_ha/show.js | 65 +++++++++++++--------- .../java/resources/virtualhost/bdb_ha/show.html | 46 +++++---------- .../java/resources/virtualhostnode/bdb/add.html | 14 ----- .../bdb_ha/add/existinggroup/add.html | 16 +----- .../virtualhostnode/bdb_ha/add/newgroup/add.html | 15 +---- .../java/resources/virtualhostnode/derby/add.html | 14 ----- .../js/qpid/management/virtualhost/jdbc/add.js | 1 + .../js/qpid/management/virtualhostnode/jdbc/add.js | 1 + .../main/java/resources/virtualhost/jdbc/add.html | 1 + .../java/resources/virtualhostnode/jdbc/add.html | 14 ----- .../addVirtualHostNodeAndVirtualHost.html | 14 +++++ .../src/main/java/resources/css/common.css | 10 +++- .../js/qpid/management/VirtualHostNode.js | 25 +++++++++ .../management/addVirtualHostNodeAndVirtualHost.js | 11 ++-- .../management/virtualhost/providedstore/add.js | 5 ++ .../src/main/java/resources/showVirtualHost.html | 63 ++++++++++----------- .../main/java/resources/showVirtualHostNode.html | 3 + .../resources/virtualhost/providedstore/add.html | 3 + .../resources/virtualhost/sizemonitoring/add.html | 1 + .../java/resources/virtualhostnode/json/add.html | 14 ----- .../java/resources/virtualhost/memory/add.html | 1 + .../java/resources/virtualhostnode/memory/add.html | 14 ----- 22 files changed, 152 insertions(+), 199 deletions(-) (limited to 'qpid/java') diff --git a/qpid/java/bdbstore/src/main/java/resources/js/qpid/management/virtualhost/bdb_ha/show.js b/qpid/java/bdbstore/src/main/java/resources/js/qpid/management/virtualhost/bdb_ha/show.js index d95d223e2d..9cf6bdea66 100644 --- a/qpid/java/bdbstore/src/main/java/resources/js/qpid/management/virtualhost/bdb_ha/show.js +++ b/qpid/java/bdbstore/src/main/java/resources/js/qpid/management/virtualhost/bdb_ha/show.js @@ -20,47 +20,60 @@ define(["qpid/common/util", "dojo/query", "dojo/domReady!"], function (util, query) { - var fields = [ "storeUnderfullSize", "storeOverfullSize", "permittedNodes"]; - var syncPolicies = ["sync", "no_sync", "write_no_sync"]; var localTransactionSynchronizationPolicy = "localTransactionSynchronizationPolicy"; var remoteTransactionSynchronizationPolicy = "remoteTransactionSynchronizationPolicy"; + var fields = [ "storeUnderfullSize", "storeOverfullSize"]; + function BDB(data) { util.buildUI(data.containerNode, data.parent, "virtualhost/bdb_ha/show.html", fields, this); - for(var i=0; i"; + } + } + this["permittedNodes"].innerHTML = permittedNodesMarkup ; + var localSyncPolicy = data[localTransactionSynchronizationPolicy].toLowerCase(); var remoteSyncPolicy = data[remoteTransactionSynchronizationPolicy].toLowerCase(); - for(var i=0; i
Permitted Nodes:
-
+

-
Before each transaction commit returns to the caller the following will be true:
-
-
At the master node, the node will have received the required minimum number of acknowledgements from the replica nodes and the transaction will have been:
-
- - -
- -
- - -
- -
- - +
+
Local Transaction Sync Policy:
+
+ SYNC (the transaction will be written and synchronized to the disk; highest durability) + WRITE_NO_SYNC (the transaction will be written only; the synchronization will be performed later) + NO_SYNC (write later; the transaction will be written and synchronized later; lowest durability)
-
-
At the required minimum number od replica nodes, the transaction will have been:
-
- - -
- -
- - -
- -
- - +
+
Remote Transaction Sync Policy:
+
+ SYNC (the transaction will be written and synchronized to the disk; highest durability) + WRITE_NO_SYNC (the transaction will be written only; the synchronization will be performed later) + NO_SYNC (write later; the transaction will be written and synchronized later; lowest durability)
-
diff --git a/qpid/java/bdbstore/src/main/java/resources/virtualhostnode/bdb/add.html b/qpid/java/bdbstore/src/main/java/resources/virtualhostnode/bdb/add.html index b47a0b0cf2..a12c910ab1 100644 --- a/qpid/java/bdbstore/src/main/java/resources/virtualhostnode/bdb/add.html +++ b/qpid/java/bdbstore/src/main/java/resources/virtualhostnode/bdb/add.html @@ -19,20 +19,6 @@ - -->
-
-
Name*:
-
- -
-
Store path*:
diff --git a/qpid/java/bdbstore/src/main/java/resources/virtualhostnode/bdb_ha/add/existinggroup/add.html b/qpid/java/bdbstore/src/main/java/resources/virtualhostnode/bdb_ha/add/existinggroup/add.html index fc1b979d70..de38b553e8 100644 --- a/qpid/java/bdbstore/src/main/java/resources/virtualhostnode/bdb_ha/add/existinggroup/add.html +++ b/qpid/java/bdbstore/src/main/java/resources/virtualhostnode/bdb_ha/add/existinggroup/add.html @@ -41,7 +41,7 @@
New node details -
-
Node Name*:
-
- -
-
Address*:
diff --git a/qpid/java/bdbstore/src/main/java/resources/virtualhostnode/bdb_ha/add/newgroup/add.html b/qpid/java/bdbstore/src/main/java/resources/virtualhostnode/bdb_ha/add/newgroup/add.html index 4517675835..02542a28ce 100644 --- a/qpid/java/bdbstore/src/main/java/resources/virtualhostnode/bdb_ha/add/newgroup/add.html +++ b/qpid/java/bdbstore/src/main/java/resources/virtualhostnode/bdb_ha/add/newgroup/add.html @@ -17,20 +17,7 @@ ~ under the License. -->
-
-
Node name*:
-
- -
-
+
Group name*:
diff --git a/qpid/java/broker-plugins/derby-store/src/main/java/resources/virtualhostnode/derby/add.html b/qpid/java/broker-plugins/derby-store/src/main/java/resources/virtualhostnode/derby/add.html index 0d24fa0c9e..8e50267ec7 100644 --- a/qpid/java/broker-plugins/derby-store/src/main/java/resources/virtualhostnode/derby/add.html +++ b/qpid/java/broker-plugins/derby-store/src/main/java/resources/virtualhostnode/derby/add.html @@ -19,20 +19,6 @@ - -->
-
-
Name*:
-
- -
-
Store path*:
diff --git a/qpid/java/broker-plugins/jdbc-store/src/main/java/resources/js/qpid/management/virtualhost/jdbc/add.js b/qpid/java/broker-plugins/jdbc-store/src/main/java/resources/js/qpid/management/virtualhost/jdbc/add.js index 12279f2455..1d9fff5571 100644 --- a/qpid/java/broker-plugins/jdbc-store/src/main/java/resources/js/qpid/management/virtualhost/jdbc/add.js +++ b/qpid/java/broker-plugins/jdbc-store/src/main/java/resources/js/qpid/management/virtualhost/jdbc/add.js @@ -47,6 +47,7 @@ define(["dojo/_base/xhr", var poolTypesStore = new Memory({ data: poolTypesData }); var poolTypeControl = registry.byId("addVirtualHost.connectionPoolType"); poolTypeControl.set("store", poolTypesStore); + poolTypeControl.set("value", "NONE"); var poolTypeFieldsDiv = dom.byId("addVirtualHost.poolSpecificDiv"); poolTypeControl.on("change", diff --git a/qpid/java/broker-plugins/jdbc-store/src/main/java/resources/js/qpid/management/virtualhostnode/jdbc/add.js b/qpid/java/broker-plugins/jdbc-store/src/main/java/resources/js/qpid/management/virtualhostnode/jdbc/add.js index 96e96eb454..adf28f1f6e 100644 --- a/qpid/java/broker-plugins/jdbc-store/src/main/java/resources/js/qpid/management/virtualhostnode/jdbc/add.js +++ b/qpid/java/broker-plugins/jdbc-store/src/main/java/resources/js/qpid/management/virtualhostnode/jdbc/add.js @@ -49,6 +49,7 @@ define(["dojo/_base/xhr", var poolTypesStore = new Memory({ data: poolTypesData }); var poolTypeControl = registry.byId("addVirtualHostNode.connectionPoolType"); poolTypeControl.set("store", poolTypesStore); + poolTypeControl.set("value", "NONE"); var poolTypeFieldsDiv = dom.byId("addVirtualHostNode.poolSpecificDiv"); poolTypeControl.on("change", diff --git a/qpid/java/broker-plugins/jdbc-store/src/main/java/resources/virtualhost/jdbc/add.html b/qpid/java/broker-plugins/jdbc-store/src/main/java/resources/virtualhost/jdbc/add.html index cb4ae1fb04..cca86d8c54 100644 --- a/qpid/java/broker-plugins/jdbc-store/src/main/java/resources/virtualhost/jdbc/add.html +++ b/qpid/java/broker-plugins/jdbc-store/src/main/java/resources/virtualhost/jdbc/add.html @@ -73,4 +73,5 @@
+
The virtual host will have the same name as the node.
diff --git a/qpid/java/broker-plugins/jdbc-store/src/main/java/resources/virtualhostnode/jdbc/add.html b/qpid/java/broker-plugins/jdbc-store/src/main/java/resources/virtualhostnode/jdbc/add.html index eefc0071d3..194a1130b4 100644 --- a/qpid/java/broker-plugins/jdbc-store/src/main/java/resources/virtualhostnode/jdbc/add.html +++ b/qpid/java/broker-plugins/jdbc-store/src/main/java/resources/virtualhostnode/jdbc/add.html @@ -19,20 +19,6 @@ - -->
-
-
Name*:
-
- -
-
JDBC Url*:
diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/addVirtualHostNodeAndVirtualHost.html b/qpid/java/broker-plugins/management-http/src/main/java/resources/addVirtualHostNodeAndVirtualHost.html index c616ab0ac8..0a9067aa42 100644 --- a/qpid/java/broker-plugins/management-http/src/main/java/resources/addVirtualHostNodeAndVirtualHost.html +++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/addVirtualHostNodeAndVirtualHost.html @@ -27,6 +27,20 @@
Virtual Host Node +
+
Name*:
+
+ +
+
Type*:
diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/css/common.css b/qpid/java/broker-plugins/management-http/src/main/java/resources/css/common.css index de22b164a2..d8ef0b30b6 100644 --- a/qpid/java/broker-plugins/management-http/src/main/java/resources/css/common.css +++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/css/common.css @@ -218,4 +218,12 @@ div .messages { display: none } - +.alignLeft { + float: left; +} +.alignRight { + float: right; +} +.multiLineValue { + display: inline-block; +} diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/VirtualHostNode.js b/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/VirtualHostNode.js index 78ef2e89df..2bf60a9c92 100644 --- a/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/VirtualHostNode.js +++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/VirtualHostNode.js @@ -101,12 +101,32 @@ define(["dojo/_base/xhr", "PUT", {desiredState: "STOPPED"}); } }); + + this.vhostsGrid = new UpdatableStore([], query(".virtualHost", containerNode)[0], + [ + { name: "Name", field: "name", width: "40%"}, + { name: "State", field: "state", width: "30%"}, + { name: "Type", field: "type", width: "30%"} + ], function(obj) { + connect.connect(obj.grid, "onRowDblClick", obj.grid, + function(evt){ + var idx = evt.rowIndex, + theItem = this.getItem(idx); + that.showVirtualHost(theItem); + }); + }, {height: 200, canSort : function(col) {return false;} }); + this.vhostNodeUpdater = new Updater(containerNode, this.modelObj, this); this.vhostNodeUpdater.update(); updater.add( this.vhostNodeUpdater ); } + VirtualHostNode.prototype.showVirtualHost=function(item) + { + this.controller.show("virtualhost", item.name, this.modelObj, item.id); + } + VirtualHostNode.prototype.close = function() { updater.remove( this.vhostNodeUpdater ); @@ -178,6 +198,11 @@ define(["dojo/_base/xhr", { this.details.update(data); } + + if (data.virtualhosts) + { + this.virtualHostNode.vhostsGrid.update(data.virtualhosts); + } } return VirtualHostNode; diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/addVirtualHostNodeAndVirtualHost.js b/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/addVirtualHostNodeAndVirtualHost.js index 19854d92cf..884290eed4 100644 --- a/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/addVirtualHostNodeAndVirtualHost.js +++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/addVirtualHostNodeAndVirtualHost.js @@ -107,6 +107,7 @@ define(["dojo/_base/xhr", this.virtualHostForm.reset(); this.virtualHostType.set("value", null); + this.dialog.show(); }, destroy: function() @@ -170,14 +171,12 @@ define(["dojo/_base/xhr", } else { - if (this.virtualHostType.value == "BDB_HA") + if (this.virtualHostTypeStore.get("BDB_HA")) { - if (this.virtualHostTypeStore.get("BDB_HA")) - { - this.virtualHostTypeStore.remove("BDB_HA"); - } - this.virtualHostType.set("value", ""); + this.virtualHostTypeStore.remove("BDB_HA"); } + this.virtualHostType.set("value", ""); + this.virtualHostType.set("disabled", false); } }, diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/virtualhost/providedstore/add.js b/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/virtualhost/providedstore/add.js index 512b8de875..e2f3fe35b7 100644 --- a/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/virtualhost/providedstore/add.js +++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/virtualhost/providedstore/add.js @@ -33,6 +33,11 @@ define(["dojo/_base/xhr", { this.containerNode = domConstruct.create("div", {innerHTML: template}, data.containerNode); parser.parse(this.containerNode); + + if (data.parent.virtualHostNodeType.value == "JDBC") + { + dom.byId("addVirtualHost.diskFlowControls").style.display = "none"; + } } }; } diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/showVirtualHost.html b/qpid/java/broker-plugins/management-http/src/main/java/resources/showVirtualHost.html index 185daa40f0..ed9d0acc60 100644 --- a/qpid/java/broker-plugins/management-http/src/main/java/resources/showVirtualHost.html +++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/showVirtualHost.html @@ -22,14 +22,37 @@
-
-
Name:
-
+
+
+
Name:
+
+
+
+
Type:
+
+
-
-
Type:
-
+
+
+
Inbound:
+
+ + msg/s + + +
+
+
+
Outbound:
+
+ + msg/s + + +
+
+
State:
@@ -55,22 +78,18 @@
Idle timeout before a warning (ms) :
-
The time a transaction can be idle for after which a warning alert will be issued
Idle timeout before closing (ms) :
-
The time a transaction can be idle for before the connection it is on is closed
Open timeout before warning (ms) :
-
The time a transaction can be open for after which a warning alert will be issued
Open timeout before closing (ms) :
-
The time a transaction can be open for before the connection it is on is closed
@@ -98,30 +117,6 @@
-
- -
-
-
Inbound:
-
- - msg/s - - -
-
-
-
Outbound:
-
- - msg/s - - -
-
-
-
-
diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/showVirtualHostNode.html b/qpid/java/broker-plugins/management-http/src/main/java/resources/showVirtualHostNode.html index 45a8447cda..9957f3ede4 100644 --- a/qpid/java/broker-plugins/management-http/src/main/java/resources/showVirtualHostNode.html +++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/showVirtualHostNode.html @@ -45,5 +45,8 @@

+
+
+
diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhost/providedstore/add.html b/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhost/providedstore/add.html index 8886bf9adf..dee80f857b 100644 --- a/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhost/providedstore/add.html +++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhost/providedstore/add.html @@ -18,6 +18,7 @@ -->
+
Store overfull size:
@@ -44,5 +45,7 @@ constraints:{min:0,places:0}" />
+
+
The virtual host will have the same name as the node.
diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhost/sizemonitoring/add.html b/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhost/sizemonitoring/add.html index fe45fde389..e8f523b320 100644 --- a/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhost/sizemonitoring/add.html +++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhost/sizemonitoring/add.html @@ -58,4 +58,5 @@
+
The virtual host will have the same name as the node.
diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhostnode/json/add.html b/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhostnode/json/add.html index fbe26745dd..0d8556f192 100644 --- a/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhostnode/json/add.html +++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhostnode/json/add.html @@ -19,20 +19,6 @@ - -->
-
-
Name*:
-
- -
-
Store path*:
diff --git a/qpid/java/broker-plugins/memory-store/src/main/java/resources/virtualhost/memory/add.html b/qpid/java/broker-plugins/memory-store/src/main/java/resources/virtualhost/memory/add.html index bfb5037b09..56577083e0 100644 --- a/qpid/java/broker-plugins/memory-store/src/main/java/resources/virtualhost/memory/add.html +++ b/qpid/java/broker-plugins/memory-store/src/main/java/resources/virtualhost/memory/add.html @@ -18,4 +18,5 @@ -->
+
The virtual host will have the same name as the node.
diff --git a/qpid/java/broker-plugins/memory-store/src/main/java/resources/virtualhostnode/memory/add.html b/qpid/java/broker-plugins/memory-store/src/main/java/resources/virtualhostnode/memory/add.html index 89f842cfc7..9a3bc91e77 100644 --- a/qpid/java/broker-plugins/memory-store/src/main/java/resources/virtualhostnode/memory/add.html +++ b/qpid/java/broker-plugins/memory-store/src/main/java/resources/virtualhostnode/memory/add.html @@ -19,19 +19,5 @@ - -->
-
-
Name*:
-
- -
-
-- cgit v1.2.1