ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sboi...@apache.org
Subject [49/50] [abbrv] incubator-ignite git commit: # sprint-2: Fixed NPE and changes for Visor after SQL rework.
Date Wed, 18 Mar 2015 04:45:42 GMT
# sprint-2: Fixed NPE and changes for Visor after SQL rework.


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

Branch: refs/heads/ignite-496
Commit: 3eca5e705599033d1e395ed0e5f438dfcdcf681a
Parents: 7deceb2
Author: AKuznetsov <akuznetsov@gridgain.com>
Authored: Wed Mar 18 09:44:48 2015 +0700
Committer: AKuznetsov <akuznetsov@gridgain.com>
Committed: Wed Mar 18 09:44:48 2015 +0700

----------------------------------------------------------------------
 .../visor/cache/VisorCacheConfiguration.java    | 21 --------------------
 .../cache/VisorCacheQueryConfiguration.java     |  5 +----
 .../commands/cache/VisorCacheCommand.scala      | 14 +++++++------
 3 files changed, 9 insertions(+), 31 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/3eca5e70/modules/core/src/main/java/org/apache/ignite/internal/visor/cache/VisorCacheConfiguration.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/visor/cache/VisorCacheConfiguration.java
b/modules/core/src/main/java/org/apache/ignite/internal/visor/cache/VisorCacheConfiguration.java
index 30e9f46..7206853 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/visor/cache/VisorCacheConfiguration.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/visor/cache/VisorCacheConfiguration.java
@@ -21,7 +21,6 @@ import org.apache.ignite.*;
 import org.apache.ignite.cache.*;
 import org.apache.ignite.configuration.*;
 import org.apache.ignite.internal.util.typedef.internal.*;
-import org.apache.ignite.internal.visor.node.*;
 import org.jetbrains.annotations.*;
 
 import java.io.*;
@@ -60,9 +59,6 @@ public class VisorCacheConfiguration implements Serializable {
     /** Swap enabled flag. */
     private boolean swapEnabled;
 
-    /** Flag indicating whether Ignite should attempt to index value and/or key instances
stored in cache. */
-    private boolean qryIdxEnabled;
-
     /** Invalidate. */
     private boolean invalidate;
 
@@ -75,9 +71,6 @@ public class VisorCacheConfiguration implements Serializable {
     /** Off-heap max memory. */
     private long offHeapMaxMemory;
 
-    /** Max query iterator count */
-    private int maxQryIterCnt;
-
     /** Max concurrent async operations */
     private int maxConcurrentAsyncOps;
 
@@ -241,13 +234,6 @@ public class VisorCacheConfiguration implements Serializable {
     }
 
     /**
-     * @return Flag indicating whether Ignite should attempt to index value and/or key instances
stored in cache.
-     */
-    public boolean queryIndexEnabled() {
-        return qryIdxEnabled;
-    }
-
-    /**
      * @return Invalidate.
      */
     public boolean invalidate() {
@@ -276,13 +262,6 @@ public class VisorCacheConfiguration implements Serializable {
     }
 
     /**
-     * @return Max query iterator count
-     */
-    public int maxQueryIteratorCount() {
-        return maxQryIterCnt;
-    }
-
-    /**
      * @return Max concurrent async operations
      */
     public int maxConcurrentAsyncOperations() {

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/3eca5e70/modules/core/src/main/java/org/apache/ignite/internal/visor/cache/VisorCacheQueryConfiguration.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/visor/cache/VisorCacheQueryConfiguration.java
b/modules/core/src/main/java/org/apache/ignite/internal/visor/cache/VisorCacheQueryConfiguration.java
index 5b39182..53f0ae5 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/visor/cache/VisorCacheQueryConfiguration.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/visor/cache/VisorCacheQueryConfiguration.java
@@ -39,9 +39,6 @@ public class VisorCacheQueryConfiguration implements Serializable {
     private static final long serialVersionUID = 0L;
 
     /** */
-    private static final String[] EMPTY_STR_ARR = new String[0];
-
-    /** */
     private String[] sqlFuncClss;
 
     /** */
@@ -61,7 +58,7 @@ public class VisorCacheQueryConfiguration implements Serializable {
      */
     private static String[] compactClasses(Class<?>[] clss) {
         if (clss == null)
-            return EMPTY_STR_ARR;
+            return null;
 
         int len = clss.length;
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/3eca5e70/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/cache/VisorCacheCommand.scala
----------------------------------------------------------------------
diff --git a/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/cache/VisorCacheCommand.scala
b/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/cache/VisorCacheCommand.scala
index 8f681b2..37dc479 100644
--- a/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/cache/VisorCacheCommand.scala
+++ b/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/cache/VisorCacheCommand.scala
@@ -809,8 +809,6 @@ object VisorCacheCommand {
 
         cacheT += ("Default Lock Timeout", defaultCfg.txLockTimeout())
         cacheT += ("Default Query Timeout", defaultCfg.queryTimeout())
-        cacheT += ("Query Indexing Enabled", bool2Str(cfg.queryIndexEnabled()))
-        cacheT += ("Query Iterators Number", cfg.maxQueryIteratorCount())
         cacheT += ("Metadata type count", cfg.typeMeta().size())
         cacheT += ("Cache Interceptor", safe(cfg.interceptor()))
 
@@ -844,19 +842,23 @@ object VisorCacheCommand {
 
         val sqlFxs = queryCfg.sqlFunctionClasses()
 
-        if (sqlFxs.isEmpty)
+        val hasSqlFxs = sqlFxs != null && sqlFxs.nonEmpty
+
+        if (!hasSqlFxs)
             cacheT +=("Query SQL functions", NA)
 
         val indexedTypes = queryCfg.indexedTypes()
 
-        if (indexedTypes.isEmpty)
+        val hasIndexedTypes = indexedTypes != null && indexedTypes.nonEmpty
+
+        if (!hasIndexedTypes)
             cacheT +=("Query Indexed Types", NA)
 
         println(title)
 
         cacheT.render()
 
-        if (sqlFxs.nonEmpty) {
+        if (hasSqlFxs) {
             println("\nQuery SQL functions:")
 
             val sqlFxsT = VisorTextTable()
@@ -868,7 +870,7 @@ object VisorCacheCommand {
             sqlFxsT.render()
         }
 
-        if (indexedTypes.nonEmpty) {
+        if (hasIndexedTypes) {
             println("\nQuery Indexed Types:")
 
             val indexedTypesT = VisorTextTable()


Mime
View raw message