You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@brooklyn.apache.org by he...@apache.org on 2015/09/15 18:53:27 UTC
[08/15] incubator-brooklyn git commit: jsgui - tidy catalog error
messages and check server status more often
jsgui - tidy catalog error messages and check server status more often
(latter one allows it to switch back from "server not responsive" faster)
Project: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/commit/40959c6c
Tree: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/tree/40959c6c
Diff: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/diff/40959c6c
Branch: refs/heads/master
Commit: 40959c6c7721cb577afc84d4ae8ad6d0044af424
Parents: b961165
Author: Alex Heneveld <al...@cloudsoftcorp.com>
Authored: Fri Sep 11 10:11:53 2015 +0100
Committer: Alex Heneveld <al...@cloudsoftcorp.com>
Committed: Fri Sep 11 10:54:39 2015 +0100
----------------------------------------------------------------------
usage/jsgui/src/main/webapp/assets/css/base.css | 3 +++
.../src/main/webapp/assets/js/model/server-extended-status.js | 2 +-
usage/jsgui/src/main/webapp/assets/js/view/catalog.js | 2 +-
usage/jsgui/src/main/webapp/assets/tpl/catalog/add-location.html | 3 +--
usage/jsgui/src/main/webapp/assets/tpl/catalog/add-yaml.html | 3 +--
5 files changed, 7 insertions(+), 6 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/40959c6c/usage/jsgui/src/main/webapp/assets/css/base.css
----------------------------------------------------------------------
diff --git a/usage/jsgui/src/main/webapp/assets/css/base.css b/usage/jsgui/src/main/webapp/assets/css/base.css
index 745540c..04a488d 100644
--- a/usage/jsgui/src/main/webapp/assets/css/base.css
+++ b/usage/jsgui/src/main/webapp/assets/css/base.css
@@ -1165,6 +1165,9 @@ tr.app-add-wizard-config-entry {
padding: 7px;
border-radius: 3px;
}
+.catalog-error-message {
+ white-space: pre-wrap;
+}
.float-right {
float: right;
http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/40959c6c/usage/jsgui/src/main/webapp/assets/js/model/server-extended-status.js
----------------------------------------------------------------------
diff --git a/usage/jsgui/src/main/webapp/assets/js/model/server-extended-status.js b/usage/jsgui/src/main/webapp/assets/js/model/server-extended-status.js
index e774294..aa9e5fa 100644
--- a/usage/jsgui/src/main/webapp/assets/js/model/server-extended-status.js
+++ b/usage/jsgui/src/main/webapp/assets/js/model/server-extended-status.js
@@ -58,7 +58,7 @@ define(["backbone", "brooklyn", "view/viewutils"], function (Backbone, Brooklyn,
var that = this;
// to debug:
// serverExtendedStatus.onLoad(function() { log("loaded server status:"); log(that.attributes); })
- ViewUtils.fetchModelRepeatedlyWithDelay(this, { doitnow: true });
+ ViewUtils.fetchModelRepeatedlyWithDelay(this, { doitnow: true, backoffMaxPeriod: 3000 });
},
isUp: function() { return this.get("up") },
http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/40959c6c/usage/jsgui/src/main/webapp/assets/js/view/catalog.js
----------------------------------------------------------------------
diff --git a/usage/jsgui/src/main/webapp/assets/js/view/catalog.js b/usage/jsgui/src/main/webapp/assets/js/view/catalog.js
index 51d8a0a..7d4ab2a 100644
--- a/usage/jsgui/src/main/webapp/assets/js/view/catalog.js
+++ b/usage/jsgui/src/main/webapp/assets/js/view/catalog.js
@@ -210,7 +210,7 @@ define([
self.$(".catalog-save-error")
.removeClass("hide")
.find(".catalog-error-message")
- .html(Brooklyn.util.extractError(xhr, "Error adding catalog item: " + error));
+ .html(_.escape(Brooklyn.util.extractError(xhr, "Could not add catalog item:\n'n" + error)));
});
}
});
http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/40959c6c/usage/jsgui/src/main/webapp/assets/tpl/catalog/add-location.html
----------------------------------------------------------------------
diff --git a/usage/jsgui/src/main/webapp/assets/tpl/catalog/add-location.html b/usage/jsgui/src/main/webapp/assets/tpl/catalog/add-location.html
index e57b83a..4748617 100644
--- a/usage/jsgui/src/main/webapp/assets/tpl/catalog/add-location.html
+++ b/usage/jsgui/src/main/webapp/assets/tpl/catalog/add-location.html
@@ -30,8 +30,7 @@ under the License.
<p class="catalog-save-error hide">
<span class="alert-error">
- <strong>Error:</strong><br/>
- <span class="catalog-error-message"></span>
+ <span class="catalog-error-message"><strong>Error</strong></span>
</span>
</p>
</form>
http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/40959c6c/usage/jsgui/src/main/webapp/assets/tpl/catalog/add-yaml.html
----------------------------------------------------------------------
diff --git a/usage/jsgui/src/main/webapp/assets/tpl/catalog/add-yaml.html b/usage/jsgui/src/main/webapp/assets/tpl/catalog/add-yaml.html
index 9c64e90..bcd2d17 100644
--- a/usage/jsgui/src/main/webapp/assets/tpl/catalog/add-yaml.html
+++ b/usage/jsgui/src/main/webapp/assets/tpl/catalog/add-yaml.html
@@ -23,8 +23,7 @@ under the License.
<button class='catalog-submit-button btn' data-loading-text='Saving...'>Submit</button>
<p class="catalog-save-error hide">
<span class="alert-error">
- <strong>Error:</strong><br/>
- <span class="catalog-error-message"></span>
+ <span class="catalog-error-message"><strong>Error</strong></span>
</span>
</p>
</form>