From 400d9be252bcc666fe43b1be582f34202faf23f7 Mon Sep 17 00:00:00 2001 From: Alex Rudyy Date: Fri, 1 Aug 2014 18:08:31 +0000 Subject: QPID-5928: [Java Broker] Add UI into web management console for editing of virtual host nodes and virtual hosts The work is done by Andrew MacBean and Alex Rudyy. git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1615187 13f79535-47bb-0310-9956-ffa450edef68 --- .../src/main/java/resources/css/common.css | 17 +- .../src/main/java/resources/editVirtualHost.html | 176 ++++++++++++--------- .../main/java/resources/editVirtualHostNode.html | 48 ++++++ .../src/main/java/resources/js/qpid/common/util.js | 108 ++++++++++--- .../resources/js/qpid/management/VirtualHost.js | 2 +- .../js/qpid/management/VirtualHostNode.js | 17 +- .../js/qpid/management/editVirtualHost.js | 90 +++++++---- .../js/qpid/management/editVirtualHostNode.js | 170 ++++++++++++++++++++ .../qpid/management/virtualhostnode/json/edit.js | 30 ++++ .../resources/virtualhost/providedstore/show.html | 8 +- .../resources/virtualhost/sizemonitoring/edit.html | 68 ++++++++ .../resources/virtualhost/sizemonitoring/show.html | 10 +- .../resources/virtualhostnode/filebased/edit.html | 38 +++++ .../java/resources/virtualhostnode/json/show.html | 2 +- 14 files changed, 625 insertions(+), 159 deletions(-) create mode 100644 qpid/java/broker-plugins/management-http/src/main/java/resources/editVirtualHostNode.html create mode 100644 qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/editVirtualHostNode.js create mode 100644 qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/virtualhostnode/json/edit.js create mode 100644 qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhost/sizemonitoring/edit.html create mode 100644 qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhostnode/filebased/edit.html (limited to 'qpid/java/broker-plugins/management-http/src') 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 d8ef0b30b6..2e1033c15e 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 @@ -128,10 +128,6 @@ div .messages { width: 100%; } -.formBoxButtons { - float : right; -} - .formLabel-controlCell { padding: 1px; float: left; @@ -213,11 +209,6 @@ div .messages { font-style: italic; } -.dijitDialogPaneActionBar .editNodeButton -{ - display: none -} - .alignLeft { float: left; } @@ -227,3 +218,11 @@ div .messages { .multiLineValue { display: inline-block; } +.haOptionLabel { + font-weight: bold; + margin-left: 5px; +} +.editNoteBanner { + font-style: italic; + margin: 0px 0px 10px 5px; +} \ No newline at end of file diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/editVirtualHost.html b/qpid/java/broker-plugins/management-http/src/main/java/resources/editVirtualHost.html index eac16d0acf..1be5c5d29c 100644 --- a/qpid/java/broker-plugins/management-http/src/main/java/resources/editVirtualHost.html +++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/editVirtualHost.html @@ -19,94 +19,118 @@
- -
- +
NOTE: All changes will only take effect after Virtual Host restart.
-
Dead letter queue enabled:
-
- - +
Name*:
+
+
-
-
Store Transaction Idle Timeout Warn:
-
- -
-
-
-
Store Transaction Idle Timeout Close:
-
- -
-
-
-
Store Transaction Open Timeout Warn:
-
- -
-
-
-
Store Transaction Open Timeout Close:
-
- -
+
+ +
+
+ Store transaction settings +
+
Idle Timeout Warn:
+
+ +
+
+
+
Idle Timeout Close:
+
+ +
+
+
+
Open Timeout Warn:
+
+ +
+
+
+
Open Timeout Close:
+
+ +
+
+
-
-
House keeping check period (ms):
-
- -
+
+
+ House keeping settings +
+
Check period (ms):
+
+ +
+
+
+
Thread count:
+
+ +
+
+
+
-
House keeping thread count:
+
Dead letter queue enabled:
- + +
-
diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/editVirtualHostNode.html b/qpid/java/broker-plugins/management-http/src/main/java/resources/editVirtualHostNode.html new file mode 100644 index 0000000000..49f069c06d --- /dev/null +++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/editVirtualHostNode.html @@ -0,0 +1,48 @@ + +
+
+ +
NOTE: All changes will only take effect after Virtual Host Node restart.
+
+
Name*:
+
+ +
+
+ +
+ +
+ +
+ + +
+ +
+
diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/common/util.js b/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/common/util.js index 60c05a5df6..5ba7cc7b2c 100644 --- a/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/common/util.js +++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/common/util.js @@ -18,7 +18,6 @@ * under the License. * */ - define(["dojo/_base/xhr", "dojo/_base/event", "dojo/json", @@ -29,6 +28,7 @@ define(["dojo/_base/xhr", "dojo/query", "dojo/parser", "dojox/html/entities", + "dijit/registry", "dijit/TitlePane", "dijit/Dialog", "dijit/form/Form", @@ -41,7 +41,7 @@ define(["dojo/_base/xhr", "dojox/validate/web", "dojo/domReady!" ], - function (xhr, event, json, lang, dom, geometry, win, query, parser, entities) { + function (xhr, event, json, lang, dom, geometry, win, query, parser, entities, registry) { var util = {}; if (Array.isArray) { util.isArray = function (object) { @@ -494,21 +494,42 @@ define(["dojo/_base/xhr", return object1 === object2; } - util.buildUI = function(containerNode, parent, htmlTemplateLocation, fieldNames, obj) + util.parseHtmlIntoDiv = function(containerNode, htmlTemplateLocation) { xhr.get({url: htmlTemplateLocation, - sync: true, - load: function(template) { - containerNode.innerHTML = template; - parser.parse(containerNode); - }}); - for(var i=0; i
-
Store Overfull Limit:
-
bytes
+
Store overfull size:
+
bytes
-
Store Underfull Limit:
-
bytes
+
Store underfull size:
+
bytes
diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhost/sizemonitoring/edit.html b/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhost/sizemonitoring/edit.html new file mode 100644 index 0000000000..088057533b --- /dev/null +++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhost/sizemonitoring/edit.html @@ -0,0 +1,68 @@ + + +
+ +
+
Message store path*:
+
+ +
+
+ +
+
Store overfull size (bytes):
+
+ +
+
+
+
Store underfull size (bytes):
+
+ +
+
+ +
+ +
diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhost/sizemonitoring/show.html b/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhost/sizemonitoring/show.html index 245635b333..350a9777cb 100644 --- a/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhost/sizemonitoring/show.html +++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhost/sizemonitoring/show.html @@ -19,16 +19,16 @@
-
Store Path:
+
Message store path:
-
Store Overfull Limit:
-
bytes
+
Store overfull size:
+
bytes
-
Store Underfull Limit:
-
bytes
+
Store underfull size:
+
bytes
diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhostnode/filebased/edit.html b/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhostnode/filebased/edit.html new file mode 100644 index 0000000000..7c5c07e4a8 --- /dev/null +++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhostnode/filebased/edit.html @@ -0,0 +1,38 @@ + + +
+ +
+
Configuration store path*:
+
+ +
+
+ +
+ +
diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhostnode/json/show.html b/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhostnode/json/show.html index 05a85daf6e..b8c6adeed3 100644 --- a/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhostnode/json/show.html +++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/virtualhostnode/json/show.html @@ -16,6 +16,6 @@ -->
-
Store Path:
+
Configuration store path:
-- cgit v1.2.1