[pve-devel] [PATCH manager] do not hide ceph on dashboard if the api call fails

Dominik Csapak d.csapak at proxmox.com
Wed Dec 21 11:48:46 CET 2016


with this patch, we do not hide the ceph status anymore if the api call
fails (too slow, e.g.) as long as we showed it at least one time

also, we only stop the updates if we never successfully got the status

Signed-off-by: Dominik Csapak <d.csapak at proxmox.com>
---
 www/manager6/dc/Health.js | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/www/manager6/dc/Health.js b/www/manager6/dc/Health.js
index fbb74a6..78d8922 100644
--- a/www/manager6/dc/Health.js
+++ b/www/manager6/dc/Health.js
@@ -67,8 +67,13 @@ Ext.define('PVE.dc.Health', {
 	var me = this;
 	var cephstatus = me.getComponent('ceph');
 	if (!success || records.length < 1) {
+
+	    // if ceph status is already visible
+	    // dont stop to update
+	    if (cephstatus.isVisible()) {
+		return;
+	    }
 	    me.cepherrors++;
-	    cephstatus.setVisible(false);
 
 	    // after 3 unsuccessful tries of
 	    // /nodes/localhost/ceph/status
-- 
2.1.4





More information about the pve-devel mailing list