Repository: stratos
Updated Branches:
  refs/heads/stratos-4.1.x 28f3d4508 -> 63ea5e373


checking all the das nodes for stats publisher enabled check


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

Branch: refs/heads/stratos-4.1.x
Commit: 63ea5e373a072f8022b27ac85268e2f81f9a05a3
Parents: 5f07b2a
Author: Thanuja <[email protected]>
Authored: Wed Oct 14 01:08:48 2015 +0530
Committer: gayangunarathne <[email protected]>
Committed: Wed Oct 14 14:24:33 2015 +0530

----------------------------------------------------------------------
 .../console/controllers/login/login.jag                      | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/63ea5e37/components/org.apache.stratos.manager.console/console/controllers/login/login.jag
----------------------------------------------------------------------
diff --git 
a/components/org.apache.stratos.manager.console/console/controllers/login/login.jag
 
b/components/org.apache.stratos.manager.console/console/controllers/login/login.jag
index 6f707c9..ef495f9 100644
--- 
a/components/org.apache.stratos.manager.console/console/controllers/login/login.jag
+++ 
b/components/org.apache.stratos.manager.console/console/controllers/login/login.jag
@@ -28,8 +28,14 @@ var log = new Log("controller.login"),
         hostName = conf. *::['HostName'].text().toString(),
         conf = carbon.server.loadConfig('thrift-client-config.xml'),
         dasConfig = conf. *::['config']. *::['das'],
-        dasStatsPublisherEnabled = 
dasConfig.node[0].statsPublisherEnabled.text();
+        dasStatsPublisherEnabled = false;
 
+for (var i = 0; i < dasConfig.node.length(); i++) {
+    dasStatsPublisherEnabled = dasConfig.node[i].statsPublisherEnabled.text();
+    if (dasStatsPublisherEnabled == true) {
+        break;
+    }
+}
 
 if (hostName === null || hostName === '') {
     hostName = 'localhost';

Reply via email to