ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akuznet...@apache.org
Subject ignite git commit: IGNITE-843 Do not generate IGFS for client XML.
Date Thu, 17 Dec 2015 08:43:57 GMT
Repository: ignite
Updated Branches:
  refs/heads/ignite-843-rc2 1fa0f7c60 -> debb326d3


IGNITE-843 Do not generate IGFS for client XML.


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

Branch: refs/heads/ignite-843-rc2
Commit: debb326d369514bc7587b7741fedbe789e9e6a40
Parents: 1fa0f7c
Author: Alexey Kuznetsov <akuznetsov@apache.org>
Authored: Thu Dec 17 15:44:49 2015 +0700
Committer: Alexey Kuznetsov <akuznetsov@apache.org>
Committed: Thu Dec 17 15:44:49 2015 +0700

----------------------------------------------------------------------
 .../main/js/helpers/generator/generator-xml.js  | 35 +++++++++++---------
 1 file changed, 19 insertions(+), 16 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/debb326d/modules/control-center-web/src/main/js/helpers/generator/generator-xml.js
----------------------------------------------------------------------
diff --git a/modules/control-center-web/src/main/js/helpers/generator/generator-xml.js b/modules/control-center-web/src/main/js/helpers/generator/generator-xml.js
index c1fccd3..6f3d7a5 100644
--- a/modules/control-center-web/src/main/js/helpers/generator/generator-xml.js
+++ b/modules/control-center-web/src/main/js/helpers/generator/generator-xml.js
@@ -20,7 +20,7 @@ $generatorXml = {};
 
 // Do XML escape.
 $generatorXml.escape = function (s) {
-    if (typeof(s) != 'string')
+    if (typeof(s) !== 'string')
         return s;
 
     return s.replace(/&/g, '&amp;').replace(/</g, '&lt;').replace(/>/g,
'&gt;').replace(/"/g, '&quot;');
@@ -51,7 +51,7 @@ $generatorXml.property = function (res, obj, propName, setterName, dflt)
{
             var hasDflt = $commonUtils.isDefined(dflt);
 
             // Add to result if no default provided or value not equals to default.
-            if (!hasDflt || (hasDflt && val != dflt)) {
+            if (!hasDflt || (hasDflt && val !== dflt)) {
                 $generatorXml.element(res, 'property', 'name', setterName ? setterName :
propName, 'value', $generatorXml.escape(val));
 
                 return true;
@@ -82,7 +82,7 @@ $generatorXml.listProperty = function (res, obj, propName, listType, rowFactory)
 
         if (!rowFactory)
             rowFactory = function (val) {
-                return '<value>' + $generatorXml.escape(val) + '</value>'
+                return '<value>' + $generatorXml.escape(val) + '</value>';
             };
 
         res.startBlock('<property name="' + propName + '">');
@@ -115,7 +115,7 @@ $generatorXml.arrayProperty = function (res, obj, propName, descr, rowFactory)
{
         res.startBlock('<list>');
 
         _.forEach(val, function (v) {
-            res.append(rowFactory(v))
+            res.append(rowFactory(v));
         });
 
         res.endBlock('</list>');
@@ -358,13 +358,13 @@ $generatorXml.clusterAtomics = function (cluster, res) {
 
         var cacheMode = atomics.cacheMode ? atomics.cacheMode : 'PARTITIONED';
 
-        var hasData = cacheMode != 'PARTITIONED';
+        var hasData = cacheMode !== 'PARTITIONED';
 
         $generatorXml.property(res, atomics, 'cacheMode');
 
         hasData = $generatorXml.property(res, atomics, 'atomicSequenceReserveSize') || hasData;
 
-        if (cacheMode == 'PARTITIONED')
+        if (cacheMode === 'PARTITIONED')
             hasData = $generatorXml.property(res, atomics, 'backups') || hasData;
 
         res.endBlock('</bean>');
@@ -499,7 +499,7 @@ $generatorXml.clusterEvents = function (cluster, res) {
 
         res.startBlock('<property name="includeEventTypes">');
 
-        if (cluster.includeEventTypes.length == 1)
+        if (cluster.includeEventTypes.length === 1)
             res.line('<util:constant static-field="org.apache.ignite.events.EventType.'
+ cluster.includeEventTypes[0] + '"/>');
         else {
             res.startBlock('<list>');
@@ -513,7 +513,7 @@ $generatorXml.clusterEvents = function (cluster, res) {
                 var eventList = $dataStructures.EVENT_GROUPS[eventGroup];
 
                 _.forEach(eventList, function(event) {
-                    res.line('<util:constant static-field="org.apache.ignite.events.EventType.'
+ event + '"/>')
+                    res.line('<util:constant static-field="org.apache.ignite.events.EventType.'
+ event + '"/>');
                 });
             });
 
@@ -570,7 +570,7 @@ $generatorXml.clusterSwap = function (cluster, res) {
     if (!res)
         res = $generatorCommon.builder();
 
-    if (cluster.swapSpaceSpi && cluster.swapSpaceSpi.kind == 'FileSwapSpaceSpi')
{
+    if (cluster.swapSpaceSpi && cluster.swapSpaceSpi.kind === 'FileSwapSpaceSpi')
{
         $generatorXml.beanProperty(res, cluster.swapSpaceSpi.FileSwapSpaceSpi, 'swapSpaceSpi',
             $generatorCommon.SWAP_SPACE_SPI, true);
 
@@ -663,7 +663,7 @@ $generatorXml.cacheGeneral = function(cache, res) {
     $generatorXml.property(res, cache, 'cacheMode');
     $generatorXml.property(res, cache, 'atomicityMode');
 
-    if (cache.cacheMode == 'PARTITIONED')
+    if (cache.cacheMode === 'PARTITIONED')
         $generatorXml.property(res, cache, 'backups');
 
     $generatorXml.property(res, cache, 'readFromBackup');
@@ -740,7 +740,7 @@ $generatorXml.cacheStore = function(cache, metadatas, res) {
         var storeFactory = cache.cacheStoreFactory[factoryKind];
 
         if (storeFactory) {
-            if (factoryKind == 'CacheJdbcPojoStoreFactory') {
+            if (factoryKind === 'CacheJdbcPojoStoreFactory') {
                 res.startBlock('<property name="cacheStoreFactory">');
                 res.startBlock('<bean class="org.apache.ignite.cache.store.jdbc.CacheJdbcPojoStoreFactory">');
 
@@ -772,14 +772,14 @@ $generatorXml.cacheStore = function(cache, metadatas, res) {
                 }
 
                 res.endBlock('</bean>');
-                res.endBlock("</property>")
+                res.endBlock("</property>");
             }
             else
                 $generatorXml.beanProperty(res, storeFactory, 'cacheStoreFactory', $generatorCommon.STORE_FACTORIES[factoryKind],
true);
 
             if (storeFactory.dialect && storeFactory.dataSourceBean) {
                 if (_.findIndex(res.datasources, function (ds) {
-                        return ds.dataSourceBean == storeFactory.dataSourceBean;
+                        return ds.dataSourceBean === storeFactory.dataSourceBean;
                     }) < 0) {
                     res.datasources.push({
                         dataSourceBean: storeFactory.dataSourceBean,
@@ -831,7 +831,7 @@ $generatorXml.cacheRebalance = function(cache, res) {
     if (!res)
         res = $generatorCommon.builder();
 
-    if (cache.cacheMode != 'LOCAL') {
+    if (cache.cacheMode !== 'LOCAL') {
         $generatorXml.property(res, cache, 'rebalanceMode');
         $generatorXml.property(res, cache, 'rebalanceThreadPoolSize');
         $generatorXml.property(res, cache, 'rebalanceBatchSize');
@@ -859,7 +859,7 @@ $generatorXml.cacheServerNearCache = function(cache, res) {
     if (!res)
         res = $generatorCommon.builder();
 
-    if (cache.cacheMode == 'PARTITIONED' && cache.nearCacheEnabled) {
+    if (cache.cacheMode === 'PARTITIONED' && cache.nearCacheEnabled) {
         res.emptyLineIfNeeded();
 
         res.startBlock('<property name="nearConfiguration">');
@@ -1452,7 +1452,10 @@ $generatorXml.clusterConfiguration = function (cluster, clientNearCfg,
res) {
 
     $generatorXml.clusterSsl(cluster, res);
 
-    return $generatorXml.igfss(cluster.igfss, res);
+    if (isSrvCfg)
+        $generatorXml.igfss(cluster.igfss, res);
+
+    return res;
 };
 
 $generatorXml.cluster = function (cluster, clientNearCfg) {


Mime
View raw message