ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sboi...@apache.org
Subject [07/50] [abbrv] ignite git commit: IGNITE-4988 Cleanup and refactor VisorXxx tasks and DTO for ignite-2.0
Date Mon, 17 Apr 2017 08:21:29 GMT
http://git-wip-us.apache.org/repos/asf/ignite/blob/12dfe9e8/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 6d49a3b..3fd9555 100755
--- 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
@@ -17,8 +17,7 @@
 
 package org.apache.ignite.visor.commands.cache
 
-import java.lang.{Boolean => JavaBoolean}
-import java.util.{Collection => JavaCollection, Collections, UUID}
+import java.util.{Collection => JavaCollection, List => JavaList, Collections, UUID}
 
 import org.apache.ignite._
 import org.apache.ignite.cluster.ClusterNode
@@ -26,7 +25,6 @@ import org.apache.ignite.internal.util.lang.{GridFunc => F}
 import org.apache.ignite.internal.util.typedef.X
 import org.apache.ignite.internal.visor.cache._
 import org.apache.ignite.internal.visor.util.VisorTaskUtils._
-import org.apache.ignite.lang.IgniteBiTuple
 import org.apache.ignite.visor.VisorTag
 import org.apache.ignite.visor.commands.cache.VisorCacheCommand._
 import org.apache.ignite.visor.commands.common.VisorTextTable
@@ -270,7 +268,7 @@ class VisorCacheCommand {
                     if (hasArgFlag("scan", argLst))
                         VisorCacheScanCommand().scan(argLst, node)
                     else {
-                        if (aggrData.nonEmpty && !aggrData.exists(cache => F.eq(cache.name(), name) && cache.system())) {
+                        if (aggrData.nonEmpty && !aggrData.exists(cache => F.eq(cache.getName, name) && cache.isSystem)) {
                             if (hasArgFlag("clear", argLst))
                                 VisorCacheClearCommand().clear(argLst, node)
                             else if (hasArgFlag("stop", argLst))
@@ -323,39 +321,39 @@ class VisorCacheCommand {
             sortAggregatedData(aggrData, sortType.getOrElse("cn"), reversed).foreach(
                 ad => {
                     // Add cache host as visor variable.
-                    registerCacheName(ad.name())
+                    registerCacheName(ad.getName)
 
                     sumT += (
-                        mkCacheName(ad.name()),
-                        ad.mode(),
-                        ad.nodes.size(),
+                        mkCacheName(ad.getName),
+                        ad.getMode,
+                        ad.getNodes.size(),
                         (
-                            "min: " + (ad.minimumHeapSize() + ad.minimumOffHeapSize()) +
-                                " (" + ad.minimumHeapSize() + " / " + ad.minimumOffHeapSize() + ")",
-                            "avg: " + formatDouble(ad.averageHeapSize() + ad.averageOffHeapSize()) +
-                                " (" + formatDouble(ad.averageHeapSize()) + " / " + formatDouble(ad.averageOffHeapSize()) + ")",
-                            "max: " + (ad.maximumHeapSize() + ad.maximumOffHeapSize()) +
-                                " (" + ad.maximumHeapSize() + " / " + ad.maximumOffHeapSize() + ")"
+                            "min: " + (ad.getMinimumHeapSize + ad.getMinimumOffHeapSize) +
+                                " (" + ad.getMinimumHeapSize + " / " + ad.getMinimumOffHeapSize + ")",
+                            "avg: " + formatDouble(ad.getAverageHeapSize + ad.getAverageOffHeapSize) +
+                                " (" + formatDouble(ad.getAverageHeapSize) + " / " + formatDouble(ad.getAverageOffHeapSize) + ")",
+                            "max: " + (ad.getMaximumHeapSize + ad.getMaximumOffHeapSize) +
+                                " (" + ad.getMaximumHeapSize + " / " + ad.getMaximumOffHeapSize + ")"
                             ),
                         (
-                            "min: " + ad.minimumHits,
-                            "avg: " + formatDouble(ad.averageHits),
-                            "max: " + ad.maximumHits
+                            "min: " + ad.getMinimumHits,
+                            "avg: " + formatDouble(ad.getAverageHits),
+                            "max: " + ad.getMaximumHits
                             ),
                         (
-                            "min: " + ad.minimumMisses,
-                            "avg: " + formatDouble(ad.averageMisses),
-                            "max: " + ad.maximumMisses
+                            "min: " + ad.getMinimumMisses,
+                            "avg: " + formatDouble(ad.getAverageMisses),
+                            "max: " + ad.getMaximumMisses
                             ),
                         (
-                            "min: " + ad.minimumReads,
-                            "avg: " + formatDouble(ad.averageReads),
-                            "max: " + ad.maximumReads
+                            "min: " + ad.getMinimumReads,
+                            "avg: " + formatDouble(ad.getAverageReads),
+                            "max: " + ad.getMaximumReads
                             ),
                         (
-                            "min: " + ad.minimumWrites,
-                            "avg: " + formatDouble(ad.averageWrites),
-                            "max: " + ad.maximumWrites
+                            "min: " + ad.getMinimumWrites,
+                            "avg: " + formatDouble(ad.getAverageWrites),
+                            "max: " + ad.getMaximumWrites
                             )
                         )
                 }
@@ -365,11 +363,11 @@ class VisorCacheCommand {
 
             if (all) {
                 val sorted = aggrData.sortWith((k1, k2) => {
-                    if (k1.name() == null)
+                    if (k1.getName == null)
                         true
-                    else if (k2.name() == null)
+                    else if (k2.getName == null)
                         false
-                    else k1.name().compareTo(k2.name()) < 0
+                    else k1.getName.compareTo(k2.getName) < 0
                 })
 
                 val gCfg = node.map(config).collect {
@@ -377,23 +375,23 @@ class VisorCacheCommand {
                 }
 
                 sorted.foreach(ad => {
-                    val cacheNameVar = mkCacheName(ad.name())
+                    val cacheNameVar = mkCacheName(ad.getName)
 
                     println("\nCache '" + cacheNameVar + "':")
 
-                    val m = ad.metrics()
+                    val m = ad.getMetrics
 
                     val csT = VisorTextTable()
 
                     csT += ("Name(@)", cacheNameVar)
                     csT += ("Nodes", m.size())
-                    csT += ("Total size Min/Avg/Max", (ad.minimumHeapSize() + ad.minimumOffHeapSize()) + " / " +
-                        formatDouble(ad.averageHeapSize() + ad.averageOffHeapSize()) + " / " +
-                        (ad.maximumHeapSize() + ad.maximumOffHeapSize()))
-                    csT += ("  Heap size Min/Avg/Max", ad.minimumHeapSize() + " / " +
-                        formatDouble(ad.averageHeapSize()) + " / " + ad.maximumHeapSize())
-                    csT += ("  Off-heap size Min/Avg/Max", ad.minimumOffHeapSize() + " / " +
-                        formatDouble(ad.averageOffHeapSize()) + " / " + ad.maximumOffHeapSize())
+                    csT += ("Total size Min/Avg/Max", (ad.getMinimumHeapSize + ad.getMinimumOffHeapSize) + " / " +
+                        formatDouble(ad.getAverageHeapSize + ad.getAverageOffHeapSize) + " / " +
+                        (ad.getMaximumHeapSize + ad.getMaximumOffHeapSize))
+                    csT += ("  Heap size Min/Avg/Max", ad.getMinimumHeapSize + " / " +
+                        formatDouble(ad.getAverageHeapSize) + " / " + ad.getMaximumHeapSize)
+                    csT += ("  Off-heap size Min/Avg/Max", ad.getMinimumOffHeapSize + " / " +
+                        formatDouble(ad.getAverageOffHeapSize) + " / " + ad.getMaximumOffHeapSize)
 
                     val ciT = VisorTextTable()
 
@@ -410,16 +408,16 @@ class VisorCacheCommand {
                             formatDouble(nm.getCurrentCpuLoad * 100d) + " %",
                             X.timeSpan2HMSM(nm.getUpTime),
                             (
-                                "Total: " + (cm.keySize() + cm.offHeapEntriesCount()),
-                                "  Heap: " + cm.keySize(),
+                                "Total: " + (cm.getKeySize + cm.offHeapEntriesCount()),
+                                "  Heap: " + cm.getKeySize,
                                 "  Off-Heap: " + cm.offHeapEntriesCount(),
-                                "  Off-Heap Memory: " + formatMemory(cm.offHeapAllocatedSize())
+                                "  Off-Heap Memory: " + formatMemory(cm.getOffHeapAllocatedSize)
                             ),
                             (
-                                "Hi: " + cm.hits(),
-                                "Mi: " + cm.misses(),
-                                "Rd: " + cm.reads(),
-                                "Wr: " + cm.writes()
+                                "Hi: " + cm.getHits,
+                                "Mi: " + cm.getMisses,
+                                "Rd: " + cm.getReads,
+                                "Wr: " + cm.getWrites
                             )
                         )
                     }
@@ -434,19 +432,19 @@ class VisorCacheCommand {
                     // Print footnote.
                     println("'Hi' - Number of cache hits.")
                     println("'Mi' - Number of cache misses.")
-                    println("'Rd' - Number of cache reads.")
+                    println("'Rd' - number of cache reads.")
                     println("'Wr' - Number of cache writes.")
 
                     // Print metrics.
                     nl()
                     println("Aggregated queries metrics:")
-                    println("  Minimum execution time: " + X.timeSpan2HMSM(ad.minimumQueryTime()))
-                    println("  Maximum execution time: " + X.timeSpan2HMSM(ad.maximumQueryTime))
-                    println("  Average execution time: " + X.timeSpan2HMSM(ad.averageQueryTime.toLong))
-                    println("  Total number of executions: " + ad.execsQuery)
-                    println("  Total number of failures:   " + ad.failsQuery)
+                    println("  Minimum execution time: " + X.timeSpan2HMSM(ad.getMinimumQueryTime))
+                    println("  Maximum execution time: " + X.timeSpan2HMSM(ad.getMaximumQueryTime))
+                    println("  Average execution time: " + X.timeSpan2HMSM(ad.getAverageQueryTime.toLong))
+                    println("  Total number of executions: " + ad.getQueryExecutions)
+                    println("  Total number of failures:   " + ad.getQueryFailures)
 
-                    gCfg.foreach(ccfgs => ccfgs.find(ccfg => F.eq(ccfg.name(), ad.name()))
+                    gCfg.foreach(ccfgs => ccfgs.find(ccfg => F.eq(ccfg.getName, ad.getName))
                         .foreach(ccfg => {
                             nl()
 
@@ -509,9 +507,9 @@ class VisorCacheCommand {
         assert(node != null)
 
         try {
-            val caches: JavaCollection[String] = name.fold(Collections.emptyList[String]())(Collections.singletonList)
+            val caches: JavaList[String] = name.fold(Collections.emptyList[String]())(Collections.singletonList)
 
-            val arg = new IgniteBiTuple(JavaBoolean.valueOf(systemCaches), caches)
+            val arg = new VisorCacheMetricsCollectorTaskArg(systemCaches, caches)
 
             node match {
                 case Some(n) => executeOne(n.id(), classOf[VisorCacheMetricsCollectorTask], arg).toList
@@ -565,10 +563,10 @@ class VisorCacheCommand {
         assert(arg != null)
 
         val sorted = arg.trim match {
-            case "hi" => data.toSeq.sortBy(_._2.hits)
-            case "mi" => data.toSeq.sortBy(_._2.misses)
-            case "rd" => data.toSeq.sortBy(_._2.reads)
-            case "wr" => data.toSeq.sortBy(_._2.writes)
+            case "hi" => data.toSeq.sortBy(_._2.getHits)
+            case "mi" => data.toSeq.sortBy(_._2.getMisses)
+            case "rd" => data.toSeq.sortBy(_._2.getReads)
+            case "wr" => data.toSeq.sortBy(_._2.getWrites)
             case "cn" => data.toSeq.sortBy(_._1)
 
             case _ =>
@@ -592,12 +590,12 @@ class VisorCacheCommand {
         List[VisorCacheAggregatedMetrics] = {
 
         val sorted = arg.trim match {
-            case "hi" => data.toList.sortBy(_.averageHits)
-            case "mi" => data.toList.sortBy(_.averageMisses)
-            case "rd" => data.toList.sortBy(_.averageReads)
-            case "wr" => data.toList.sortBy(_.averageWrites)
+            case "hi" => data.toList.sortBy(_.getAverageHits)
+            case "mi" => data.toList.sortBy(_.getAverageMisses)
+            case "rd" => data.toList.sortBy(_.getAverageReads)
+            case "wr" => data.toList.sortBy(_.getAverageWrites)
             case "cn" => data.toList.sortWith((x, y) =>
-                x.name() == null || (y.name() != null && x.name().toLowerCase < y.name().toLowerCase))
+                x.getName == null || (y.getName != null && x.getName.toLowerCase < y.getName.toLowerCase))
 
             case _ =>
                 assert(false, "Unknown sorting type: " + arg)
@@ -639,19 +637,19 @@ class VisorCacheCommand {
             val ad = sortedAggrData(i)
 
             // Add cache host as visor variable.
-            registerCacheName(ad.name())
+            registerCacheName(ad.getName)
 
             sumT += (
                 i,
-                mkCacheName(ad.name()),
-                ad.mode(),
+                mkCacheName(ad.getName),
+                ad.getMode,
                 (
-                    "min: " + (ad.minimumHeapSize() + ad.minimumOffHeapSize()) +
-                        " (" + ad.minimumHeapSize() + " / " + ad.minimumOffHeapSize() + ")",
-                    "avg: " + formatDouble(ad.averageHeapSize() + ad.averageOffHeapSize()) +
-                        " (" + formatDouble(ad.averageHeapSize()) + " / " + formatDouble(ad.averageOffHeapSize()) + ")",
-                    "max: " + (ad.maximumHeapSize() + ad.maximumOffHeapSize()) +
-                        " (" + ad.maximumHeapSize() + " / " + ad.maximumOffHeapSize() + ")"
+                    "min: " + (ad.getMinimumHeapSize + ad.getMinimumOffHeapSize) +
+                        " (" + ad.getMinimumHeapSize + " / " + ad.getMinimumOffHeapSize + ")",
+                    "avg: " + formatDouble(ad.getAverageHeapSize + ad.getAverageOffHeapSize) +
+                        " (" + formatDouble(ad.getAverageHeapSize) + " / " + formatDouble(ad.getAverageOffHeapSize) + ")",
+                    "max: " + (ad.getMaximumHeapSize + ad.getMaximumOffHeapSize) +
+                        " (" + ad.getMaximumHeapSize + " / " + ad.getMaximumOffHeapSize + ")"
                 ))
         })
 
@@ -663,7 +661,7 @@ class VisorCacheCommand {
             None
         else {
             try
-                Some(sortedAggrData(a.toInt).name())
+                Some(sortedAggrData(a.toInt).getName)
             catch {
                 case e: Throwable =>
                     warn("Invalid selection: " + a)
@@ -828,94 +826,87 @@ object VisorCacheCommand {
      * @param cfg Config to show information.
      */
     private[commands] def printCacheConfiguration(title: String, cfg: VisorCacheConfiguration) {
-        val affinityCfg = cfg.affinityConfiguration()
-        val nearCfg = cfg.nearConfiguration()
-        val rebalanceCfg = cfg.rebalanceConfiguration()
-        val evictCfg = cfg.evictConfiguration()
-        val defaultCfg = cfg.defaultConfiguration()
-        val storeCfg = cfg.storeConfiguration()
-        val queryCfg = cfg.queryConfiguration()
+        val affinityCfg = cfg.getAffinityConfiguration
+        val nearCfg = cfg.getNearConfiguration
+        val rebalanceCfg = cfg.getRebalanceConfiguration
+        val evictCfg = cfg.getEvictionConfiguration
+        val storeCfg = cfg.getStoreConfiguration
+        val queryCfg = cfg.getQueryConfiguration
 
         val cacheT = VisorTextTable()
 
         cacheT #= ("Name", "Value")
 
-        cacheT += ("Mode", cfg.mode)
-        cacheT += ("Atomicity Mode", safe(cfg.atomicityMode))
-        cacheT += ("Atomic Write Ordering Mode", safe(cfg.atomicWriteOrderMode))
-        cacheT += ("Statistic Enabled", bool2Str(cfg.statisticsEnabled()))
-        cacheT += ("Management Enabled", bool2Str(cfg.managementEnabled()))
-
-        cacheT += ("Time To Live Eager Flag", cfg.eagerTtl)
-
-        cacheT += ("Write Synchronization Mode", safe(cfg.writeSynchronizationMode))
-        cacheT += ("Invalidate", bool2Str(cfg.invalidate()))
-        cacheT += ("Start Size", cfg.startSize())
-
-        cacheT += ("Affinity Function", safe(affinityCfg.function()))
-        cacheT += ("Affinity Backups", affinityCfg.partitionedBackups())
-        cacheT += ("Affinity Partitions", safe(affinityCfg.partitions()))
-        cacheT += ("Affinity Exclude Neighbors", safe(affinityCfg.excludeNeighbors()))
-        cacheT += ("Affinity Mapper", safe(affinityCfg.mapper()))
-
-        cacheT += ("Rebalance Mode", rebalanceCfg.mode())
-        cacheT += ("Rebalance Batch Size", rebalanceCfg.batchSize())
-        cacheT += ("Rebalance Thread Pool size", rebalanceCfg.threadPoolSize())
-        cacheT += ("Rebalance Timeout", rebalanceCfg.timeout())
-        cacheT += ("Rebalance Delay", rebalanceCfg.partitionedDelay())
-        cacheT += ("Time Between Rebalance Messages", rebalanceCfg.throttle())
-
-        cacheT += ("Eviction Policy Enabled", bool2Str(evictCfg.policy() != null))
-        cacheT += ("Eviction Policy", safe(evictCfg.policy()))
-        cacheT += ("Eviction Policy Max Size", safe(evictCfg.policyMaxSize()))
-        cacheT += ("Eviction Filter", safe(evictCfg.filter()))
-
-        cacheT += ("Near Cache Enabled", bool2Str(nearCfg.nearEnabled()))
-        cacheT += ("Near Start Size", nearCfg.nearStartSize())
-        cacheT += ("Near Eviction Policy", safe(nearCfg.nearEvictPolicy()))
-        cacheT += ("Near Eviction Policy Max Size", safe(nearCfg.nearEvictMaxSize()))
-
-        cacheT += ("Default Lock Timeout", defaultCfg.txLockTimeout())
-        cacheT += ("Metadata type count", cfg.typeMeta().size())
-        cacheT += ("Cache Interceptor", safe(cfg.interceptor()))
-
-        cacheT += ("Store Enabled", bool2Str(storeCfg.enabled()))
-        cacheT += ("Store Class", safe(storeCfg.store()))
-        cacheT += ("Store Factory Class", storeCfg.storeFactory())
-        cacheT += ("Store Keep Binary", storeCfg.storeKeepBinary())
-        cacheT += ("Store Read Through", bool2Str(storeCfg.readThrough()))
-        cacheT += ("Store Write Through", bool2Str(storeCfg.writeThrough()))
-
-        cacheT += ("Write-Behind Enabled", bool2Str(storeCfg.enabled()))
-        cacheT += ("Write-Behind Flush Size", storeCfg.flushSize())
-        cacheT += ("Write-Behind Frequency", storeCfg.flushFrequency())
-        cacheT += ("Write-Behind Flush Threads Count", storeCfg.flushThreadCount())
-        cacheT += ("Write-Behind Batch Size", storeCfg.batchSize())
-
-        cacheT += ("Concurrent Asynchronous Operations Number", cfg.maxConcurrentAsyncOperations())
-        cacheT += ("Off-Heap Size", cfg.offsetHeapMaxMemory() match {
-            case 0 => "UNLIMITED"
-            case size if size < 0 => NA
-            case size => size
-        })
-
-        cacheT += ("Loader Factory Class Name", safe(cfg.loaderFactory()))
-        cacheT += ("Writer Factory Class Name", safe(cfg.writerFactory()))
-        cacheT += ("Expiry Policy Factory Class Name", safe(cfg.expiryPolicyFactory()))
-
-        cacheT +=("Query Execution Time Threshold", queryCfg.longQueryWarningTimeout())
-        cacheT +=("Query Schema Name", queryCfg.sqlSchema())
-        cacheT +=("Query Escaped Names", bool2Str(queryCfg.sqlEscapeAll()))
-        cacheT +=("Query Onheap Cache Size", queryCfg.sqlOnheapRowCacheSize())
-
-        val sqlFxs = queryCfg.sqlFunctionClasses()
+        cacheT += ("Mode", cfg.getMode)
+        cacheT += ("Atomicity Mode", safe(cfg.getAtomicityMode))
+        cacheT += ("Atomic Write Ordering Mode", safe(cfg.getAtomicWriteOrderMode))
+        cacheT += ("Statistic Enabled", bool2Str(cfg.isStatisticsEnabled))
+        cacheT += ("Management Enabled", bool2Str(cfg.isManagementEnabled))
+
+        cacheT += ("Time To Live Eager Flag", cfg.isEagerTtl)
+
+        cacheT += ("Write Synchronization Mode", safe(cfg.getWriteSynchronizationMode))
+        cacheT += ("Invalidate", bool2Str(cfg.isInvalidate))
+        cacheT += ("Start Size", cfg.getStartSize)
+
+        cacheT += ("Affinity Function", safe(affinityCfg.getFunction))
+        cacheT += ("Affinity Backups", affinityCfg.getPartitionedBackups)
+        cacheT += ("Affinity Partitions", safe(affinityCfg.getPartitions))
+        cacheT += ("Affinity Exclude Neighbors", safe(affinityCfg.isExcludeNeighbors))
+        cacheT += ("Affinity Mapper", safe(affinityCfg.getMapper))
+
+        cacheT += ("Rebalance Mode", rebalanceCfg.getMode)
+        cacheT += ("Rebalance Batch Size", rebalanceCfg.getBatchSize)
+        cacheT += ("Rebalance Timeout", rebalanceCfg.getTimeout)
+        cacheT += ("Rebalance Delay", rebalanceCfg.getPartitionedDelay)
+        cacheT += ("Time Between Rebalance Messages", rebalanceCfg.getThrottle)
+
+        cacheT += ("Eviction Policy Enabled", bool2Str(evictCfg.getPolicy != null))
+        cacheT += ("Eviction Policy", safe(evictCfg.getPolicy))
+        cacheT += ("Eviction Policy Max Size", safe(evictCfg.getPolicyMaxSize))
+        cacheT += ("Eviction Filter", safe(evictCfg.getFilter))
+
+        cacheT += ("Near Cache Enabled", bool2Str(nearCfg.isNearEnabled))
+        cacheT += ("Near Start Size", nearCfg.getNearStartSize)
+        cacheT += ("Near Eviction Policy", safe(nearCfg.getNearEvictPolicy))
+        cacheT += ("Near Eviction Policy Max Size", safe(nearCfg.getNearEvictMaxSize))
+
+        cacheT += ("Default Lock Timeout", cfg.getDefaultLockTimeout)
+        cacheT += ("Metadata type count", cfg.getJdbcTypes.size())
+        cacheT += ("Cache Interceptor", safe(cfg.getInterceptor))
+
+        cacheT += ("Store Enabled", bool2Str(storeCfg.isEnabled))
+        cacheT += ("Store Class", safe(storeCfg.getStore))
+        cacheT += ("Store Factory Class", storeCfg.getStoreFactory)
+        cacheT += ("Store Keep Binary", storeCfg.isStoreKeepBinary)
+        cacheT += ("Store Read Through", bool2Str(storeCfg.isReadThrough))
+        cacheT += ("Store Write Through", bool2Str(storeCfg.isWriteThrough))
+
+        cacheT += ("Write-Behind Enabled", bool2Str(storeCfg.isEnabled))
+        cacheT += ("Write-Behind Flush Size", storeCfg.getFlushSize)
+        cacheT += ("Write-Behind Frequency", storeCfg.getFlushFrequency)
+        cacheT += ("Write-Behind Flush Threads Count", storeCfg.getFlushThreadCount)
+        cacheT += ("Write-Behind Batch Size", storeCfg.getBatchSize)
+
+        cacheT += ("Concurrent Asynchronous Operations Number", cfg.getMaxConcurrentAsyncOperations)
+
+        cacheT += ("Loader Factory Class Name", safe(cfg.getLoaderFactory))
+        cacheT += ("Writer Factory Class Name", safe(cfg.getWriterFactory))
+        cacheT += ("Expiry Policy Factory Class Name", safe(cfg.getExpiryPolicyFactory))
+
+        cacheT +=("Query Execution Time Threshold", queryCfg.getLongQueryWarningTimeout)
+        cacheT +=("Query Schema Name", queryCfg.getSqlSchema)
+        cacheT +=("Query Escaped Names", bool2Str(queryCfg.isSqlEscapeAll))
+        cacheT +=("Query Onheap Cache Size", queryCfg.getSqlOnheapRowCacheSize)
+
+        val sqlFxs = queryCfg.getSqlFunctionClasses
 
         val hasSqlFxs = sqlFxs != null && sqlFxs.nonEmpty
 
         if (!hasSqlFxs)
             cacheT +=("Query SQL functions", NA)
 
-        val indexedTypes = queryCfg.indexedTypes()
+        val indexedTypes = queryCfg.getIndexedTypes
 
         val hasIndexedTypes = indexedTypes != null && indexedTypes.nonEmpty
 

http://git-wip-us.apache.org/repos/asf/ignite/blob/12dfe9e8/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/cache/VisorCacheScanCommand.scala
----------------------------------------------------------------------
diff --git a/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/cache/VisorCacheScanCommand.scala b/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/cache/VisorCacheScanCommand.scala
index 9668072..a6bec15 100644
--- a/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/cache/VisorCacheScanCommand.scala
+++ b/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/cache/VisorCacheScanCommand.scala
@@ -140,11 +140,11 @@ class VisorCacheScanCommand {
             try
                 executeRandom(groupForDataNode(node, cacheName),
                     classOf[VisorQueryTask], new VisorQueryArg(cacheName, null, false, false, false, pageSize)) match {
-                    case x if x.get1() != null =>
-                        error(x.get1())
+                    case x if x.getError != null =>
+                        error(x.getError)
 
                         return
-                    case x => x.get2()
+                    case x => x.getResult
                 }
             catch {
                 case e: ClusterGroupEmptyException =>
@@ -157,7 +157,7 @@ class VisorCacheScanCommand {
                     return
             }
 
-        if (firstPage.rows.isEmpty) {
+        if (firstPage.getRows.isEmpty) {
             println(s"Cache: ${escapeName(cacheName)} is empty")
 
             return
@@ -172,19 +172,19 @@ class VisorCacheScanCommand {
 
             t #= ("Key Class", "Key", "Value Class", "Value")
 
-            nextPage.rows.foreach(r => t += (r(0), r(1), r(2), r(3)))
+            nextPage.getRows.foreach(r => t += (r(0), r(1), r(2), r(3)))
 
             t.render()
         }
 
         render()
 
-        while (nextPage.hasMore) {
+        while (nextPage.isHasMore) {
             ask("\nFetch more objects (y/n) [y]:", "y") match {
                 case "y" | "Y" =>
                     try {
-                        nextPage = executeOne(firstPage.responseNodeId(), classOf[VisorQueryNextPageTask],
-                            new IgniteBiTuple[String, Integer](firstPage.queryId(), pageSize))
+                        nextPage = executeOne(firstPage.getResponseNodeId, classOf[VisorQueryNextPageTask],
+                            new VisorQueryNextPageTaskArg(firstPage.getQueryId, pageSize))
 
                         render()
                     }

http://git-wip-us.apache.org/repos/asf/ignite/blob/12dfe9e8/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/config/VisorConfigurationCommand.scala
----------------------------------------------------------------------
diff --git a/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/config/VisorConfigurationCommand.scala b/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/config/VisorConfigurationCommand.scala
index f7d83a3..75c34ab 100644
--- a/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/config/VisorConfigurationCommand.scala
+++ b/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/config/VisorConfigurationCommand.scala
@@ -29,7 +29,7 @@ import org.apache.ignite.visor.visor._
 import java.lang.System._
 import java.util.UUID
 
-import org.apache.ignite.internal.visor.node.{VisorGridConfiguration, VisorNodeConfigurationCollectorTask}
+import org.apache.ignite.internal.visor.node.{VisorSpiDescription, VisorGridConfiguration, VisorNodeConfigurationCollectorTask}
 import org.apache.ignite.internal.visor.util.VisorTaskUtils._
 
 import scala.collection.JavaConversions._
@@ -139,7 +139,7 @@ class VisorConfigurationCommand extends VisorConsoleCommand {
             cacheConfigurations(nid).foreach(ccfg => {
                 println()
 
-                printCacheConfiguration(s"Cache '${escapeName(ccfg.name())}':", ccfg)
+                printCacheConfiguration(s"Cache '${escapeName(ccfg.getName)}':", ccfg)
             })
         }
         catch {
@@ -157,45 +157,46 @@ class VisorConfigurationCommand extends VisorConsoleCommand {
 
         val cmnT = VisorTextTable()
 
-        val basic = cfg.basic()
-
-        cmnT += ("Ignite instance name", escapeName(basic.igniteInstanceName()))
-        cmnT += ("Ignite home", safe(basic.ggHome()))
-        cmnT += ("Localhost", safe(basic.localHost()))
-        cmnT += ("Node ID", safe(basic.nodeId()))
-        cmnT += ("Marshaller", basic.marshaller())
-        cmnT += ("Deployment mode", safe(basic.deploymentMode()))
-        cmnT += ("ClientMode", javaBoolToStr(basic.clientMode()))
-        cmnT += ("Daemon", bool2Str(basic.daemon()))
-        cmnT += ("Remote JMX", bool2Str(basic.jmxRemote()))
-        cmnT += ("Restart", bool2Str(basic.restart()))
-        cmnT += ("Network timeout", basic.networkTimeout() + "ms")
-        cmnT += ("Grid logger", safe(basic.logger()))
-        cmnT += ("Discovery startup delay", basic.discoStartupDelay() + "ms")
-        cmnT += ("MBean server", safe(basic.mBeanServer()))
-        cmnT += ("ASCII logo disabled", bool2Str(basic.noAscii()))
-        cmnT += ("Discovery order not required", bool2Str(basic.noDiscoOrder()))
-        cmnT += ("Shutdown hook disabled", bool2Str(basic.noShutdownHook()))
-        cmnT += ("Program name", safe(basic. programName()))
-        cmnT += ("Quiet mode", bool2Str(basic.quiet()))
-        cmnT += ("Success filename", safe(basic.successFile()))
-        cmnT += ("Update notification", bool2Str(basic.updateNotifier()))
-        cmnT += ("Include properties", safe(cfg.includeProperties()))
-
-        val atomic = cfg.atomic()
-
-        cmnT += ("Atomic Cache Mode", atomic.cacheMode())
-        cmnT += ("Atomic Sequence Reservation Size", atomic.atomicSequenceReserveSize())
-        cmnT += ("Atomic Number Of Backup Nodes", atomic.backups())
-
-        val trn = cfg.transaction()
-
-        cmnT += ("Transaction Concurrency", trn.defaultTxConcurrency())
-        cmnT += ("Transaction Isolation", trn.defaultTxIsolation())
-        cmnT += ("Transaction Timeout", trn.defaultTxTimeout() + "ms")
-        cmnT += ("Transaction Log Cleanup Delay", trn.pessimisticTxLogLinger() + "ms")
+        val basic = cfg.getBasic
+
+        cmnT += ("Grid name", escapeName(basic.getIgniteInstanceName))
+        cmnT += ("Ignite home", safe(basic.getGgHome))
+        cmnT += ("Localhost", safe(basic.getLocalHost))
+        cmnT += ("Node ID", safe(basic.getNodeId))
+        cmnT += ("Marshaller", basic.getMarshaller)
+        cmnT += ("Deployment mode", safe(basic.getDeploymentMode))
+        cmnT += ("ClientMode", javaBoolToStr(basic.isClientMode))
+        cmnT += ("Daemon", bool2Str(basic.isDaemon))
+        cmnT += ("Remote JMX enabled", bool2Str(basic.isJmxRemote))
+        cmnT += ("Node restart enabled", bool2Str(basic.isRestart))
+        cmnT += ("Network timeout", basic.getNetworkTimeout + "ms")
+        cmnT += ("Grid logger", safe(basic.getLogger))
+        cmnT += ("Discovery startup delay", basic.getDiscoStartupDelay + "ms")
+        cmnT += ("MBean server", safe(basic.getMBeanServer))
+        cmnT += ("ASCII logo disabled", bool2Str(basic.isNoAscii))
+        cmnT += ("Discovery order not required", bool2Str(basic.isNoDiscoOrder))
+        cmnT += ("Shutdown hook disabled", bool2Str(basic.isNoShutdownHook))
+        cmnT += ("Program name", safe(basic.getProgramName))
+        cmnT += ("Quiet mode", bool2Str(basic.isQuiet))
+        cmnT += ("Success filename", safe(basic.getSuccessFile))
+        cmnT += ("Update notification enabled", bool2Str(basic.isUpdateNotifier))
+        cmnT += ("Include properties", safe(cfg.getIncludeProperties))
+
+        val atomic = cfg.getAtomic
+
+        cmnT += ("Atomic Cache Mode", atomic.getCacheMode)
+        cmnT += ("Atomic Sequence Reservation Size", atomic.getAtomicSequenceReserveSize)
+        cmnT += ("Atomic Number Of Backup Nodes", atomic.getBackups)
+
+        val trn = cfg.getTransaction
+
+        cmnT += ("Transaction Concurrency", trn.getDefaultTxConcurrency)
+        cmnT += ("Transaction Isolation", trn.getDefaultTxIsolation)
+        cmnT += ("Transaction Timeout", trn.getDefaultTxTimeout + "ms")
+        cmnT += ("Transaction Log Cleanup Delay", trn.getPessimisticTxLogLinger + "ms")
         cmnT += ("Transaction Log Size", trn.getPessimisticTxLogSize)
-        cmnT += ("Transaction Serializable Enabled", bool2Str(trn.txSerializableEnabled()))
+        cmnT += ("Transaction Manager Factory", trn.getTxManagerFactory)
+        cmnT += ("Transaction Use JTA", bool2Str(trn.isUseJtaSync))
 
         cmnT.render()
 
@@ -203,11 +204,13 @@ class VisorConfigurationCommand extends VisorConsoleCommand {
 
         val metricsT = VisorTextTable()
 
-        val expTime = cfg.metrics().expireTime()
+        val metricsCfg = cfg.getMetrics
+
+        val expTime = metricsCfg.getExpireTime
 
         metricsT += ("Metrics expire time", if (expTime != Long.MaxValue) expTime + "ms" else "<never>")
-        metricsT += ("Metrics history size", cfg.metrics().historySize())
-        metricsT += ("Metrics log frequency", cfg.metrics().loggerFrequency())
+        metricsT += ("Metrics history size", metricsCfg.getHistorySize)
+        metricsT += ("Metrics log frequency", metricsCfg.getLoggerFrequency)
 
         metricsT.render()
 
@@ -215,23 +218,25 @@ class VisorConfigurationCommand extends VisorConsoleCommand {
 
         val spisT = VisorTextTable()
 
-        def spiClass(spi: IgniteBiTuple[String, java.util.Map[String, AnyRef]]) = {
-            if (spi != null) spi.get2().getOrElse("Class Name", NA) else NA
+        def spiClass(spi: VisorSpiDescription) = {
+            if (spi != null) spi.getFieldDescriptions.getOrElse("Class Name", NA) else NA
         }
 
-        def spisClass(spis: Array[IgniteBiTuple[String, java.util.Map[String, AnyRef]]]) = {
+        def spisClass(spis: Array[VisorSpiDescription]) = {
             spis.map(spiClass).mkString("[", ", ", "]")
         }
 
-        spisT += ("Discovery", spiClass(cfg.spis().discoverySpi()))
-        spisT += ("Communication", spiClass(cfg.spis().communicationSpi()))
-        spisT += ("Event storage", spiClass(cfg.spis().eventStorageSpi()))
-        spisT += ("Collision", spiClass(cfg.spis().collisionSpi()))
-        spisT += ("Deployment", spiClass(cfg.spis().deploymentSpi()))
-        spisT += ("Checkpoints", spisClass(cfg.spis().checkpointSpis()))
-        spisT += ("Failovers", spisClass(cfg.spis().failoverSpis()))
-        spisT += ("Load balancings", spisClass(cfg.spis().loadBalancingSpis()))
-        spisT += ("Indexing", spisClass(cfg.spis().indexingSpis()))
+        val spisCfg = cfg.getSpis
+
+        spisT += ("Discovery", spiClass(spisCfg.getDiscoverySpi))
+        spisT += ("Communication", spiClass(spisCfg.getCommunicationSpi))
+        spisT += ("Event storage", spiClass(spisCfg.getEventStorageSpi))
+        spisT += ("Collision", spiClass(spisCfg.getCollisionSpi))
+        spisT += ("Deployment", spiClass(spisCfg.getDeploymentSpi))
+        spisT += ("Checkpoints", spisClass(spisCfg.getCheckpointSpis))
+        spisT += ("Failovers", spisClass(spisCfg.getFailoverSpis))
+        spisT += ("Load balancings", spisClass(spisCfg.getLoadBalancingSpis))
+        spisT += ("Indexing", spisClass(spisCfg.getIndexingSpis))
 
         spisT.render()
 
@@ -239,9 +244,11 @@ class VisorConfigurationCommand extends VisorConsoleCommand {
 
         val p2pT = VisorTextTable()
 
-        p2pT += ("Peer class loading enabled", bool2Str(cfg.p2p().p2pEnabled()))
-        p2pT += ("Missed resources cache size", cfg.p2p().p2pMissedResponseCacheSize())
-        p2pT += ("Peer-to-Peer loaded packages", safe(cfg.p2p().p2pLocalClassPathExclude()))
+        val p2pCfg = cfg.getP2p
+
+        p2pT += ("Peer class loading enabled", bool2Str(p2pCfg.isPeerClassLoadingEnabled))
+        p2pT += ("Missed resources cache size", p2pCfg.getPeerClassLoadingMissedResourcesCacheSize)
+        p2pT += ("Peer-to-Peer loaded packages", safe(p2pCfg.getPeerClassLoadingLocalClassPathExclude))
 
         p2pT.render()
 
@@ -249,7 +256,7 @@ class VisorConfigurationCommand extends VisorConsoleCommand {
 
         val lifecycleT = VisorTextTable()
 
-        lifecycleT += ("Beans", safe(cfg.lifecycle().beans()))
+        lifecycleT += ("Beans", safe(cfg.getLifecycle.getBeans))
 
         lifecycleT.render()
 
@@ -257,14 +264,15 @@ class VisorConfigurationCommand extends VisorConsoleCommand {
 
         val execSvcT = VisorTextTable()
 
-        val execCfg = cfg.executeService()
+        val execCfg = cfg.getExecutorService
 
-        execSvcT += ("Public thread pool size", safe(execCfg.publicThreadPoolSize()))
-        execSvcT += ("System thread pool size", safe(execCfg.systemThreadPoolSize()))
-        execSvcT += ("Management thread pool size", safe(execCfg.managementThreadPoolSize()))
-        execSvcT += ("IGFS thread pool size", safe(execCfg.igfsThreadPoolSize()))
-        execSvcT += ("Peer-to-Peer thread pool size", safe(execCfg.peerClassLoadingThreadPoolSize()))
-        execSvcT += ("REST thread pool size", safe(execCfg.restThreadPoolSize()))
+        execSvcT += ("Public thread pool size", safe(execCfg.getPublicThreadPoolSize))
+        execSvcT += ("System thread pool size", safe(execCfg.getSystemThreadPoolSize))
+        execSvcT += ("Management thread pool size", safe(execCfg.getManagementThreadPoolSize))
+        execSvcT += ("IGFS thread pool size", safe(execCfg.getIgfsThreadPoolSize))
+        execSvcT += ("Peer-to-Peer thread pool size", safe(execCfg.getPeerClassLoadingThreadPoolSize))
+        execSvcT += ("Rebalance Thread Pool size", execCfg.getRebalanceThreadPoolSize)
+        execSvcT += ("REST thread pool size", safe(execCfg.getRestThreadPoolSize))
 
         execSvcT.render()
 
@@ -272,11 +280,13 @@ class VisorConfigurationCommand extends VisorConsoleCommand {
 
         val segT = VisorTextTable()
 
-        segT += ("Segmentation policy", safe(cfg.segmentation().policy()))
-        segT += ("Segmentation resolvers", safe(cfg.segmentation().resolvers()))
-        segT += ("Segmentation check frequency", cfg.segmentation().checkFrequency())
-        segT += ("Wait for segmentation on start", bool2Str(cfg.segmentation().waitOnStart()))
-        segT += ("All resolvers pass required", bool2Str(cfg.segmentation().passRequired()))
+        val segmentationCfg = cfg.getSegmentation
+
+        segT += ("Segmentation policy", safe(segmentationCfg.getPolicy))
+        segT += ("Segmentation resolvers", safe(segmentationCfg.getResolvers))
+        segT += ("Segmentation check frequency", segmentationCfg.getCheckFrequency)
+        segT += ("Wait for segmentation on start", bool2Str(segmentationCfg.isWaitOnStart))
+        segT += ("All resolvers pass required", bool2Str(segmentationCfg.isAllSegmentationResolversPassRequired))
 
         segT.render()
 
@@ -284,7 +294,7 @@ class VisorConfigurationCommand extends VisorConsoleCommand {
 
         val evtsT = VisorTextTable()
 
-        val inclEvtTypes = Option(cfg.includeEventTypes()).fold(NA)(et => arr2Str(et.map(U.gridEventName)))
+        val inclEvtTypes = Option(cfg.getIncludeEventTypes).fold(NA)(et => arr2Str(et.map(U.gridEventName)))
 
         evtsT += ("Included event types", inclEvtTypes)
 
@@ -294,32 +304,33 @@ class VisorConfigurationCommand extends VisorConsoleCommand {
 
         val restT = VisorTextTable()
 
-        restT += ("REST enabled", bool2Str(cfg.rest().restEnabled()))
-        restT += ("Rest accessible folders", safe(cfg.rest().accessibleFolders()))
-        restT += ("Jetty path", safe(cfg.rest().jettyPath()))
-        restT += ("Jetty host", safe(cfg.rest().jettyHost()))
-        restT += ("Jetty port", safe(cfg.rest().jettyPort()))
-        restT += ("Tcp ssl enabled", bool2Str(cfg.rest().tcpSslEnabled()))
-        restT += ("Tcp ssl context factory", safe(cfg.rest().tcpSslContextFactory()))
-        restT += ("Tcp host", safe(cfg.rest().tcpHost()))
-        restT += ("Tcp port", safe(cfg.rest().tcpPort()))
+        val restCfg = cfg.getRest
+
+        restT += ("REST enabled", bool2Str(restCfg.isRestEnabled))
+        restT += ("Jetty path", safe(restCfg.getJettyPath))
+        restT += ("Jetty host", safe(restCfg.getJettyHost))
+        restT += ("Jetty port", safe(restCfg.getJettyPort))
+        restT += ("Tcp ssl enabled", bool2Str(restCfg.isTcpSslEnabled))
+        restT += ("Tcp ssl context factory", safe(restCfg.getTcpSslContextFactory))
+        restT += ("Tcp host", safe(restCfg.getTcpHost))
+        restT += ("Tcp port", safe(restCfg.getTcpPort))
 
         restT.render()
 
-        if (cfg.userAttributes().nonEmpty) {
+        if (cfg.getUserAttributes.nonEmpty) {
             println("\nUser attributes:")
 
             val uaT = VisorTextTable()
 
             uaT #= ("Name", "Value")
 
-            cfg.userAttributes().foreach(a => uaT += (a._1, a._2))
+            cfg.getUserAttributes.foreach(a => uaT += (a._1, a._2))
 
             uaT.render()
         } else
             println("\nNo user attributes defined.")
 
-        if (cfg.env().nonEmpty) {
+        if (cfg.getEnv.nonEmpty) {
             println("\nEnvironment variables:")
 
             val envT = VisorTextTable()
@@ -328,13 +339,13 @@ class VisorConfigurationCommand extends VisorConsoleCommand {
 
             envT #= ("Name", "Value")
 
-            cfg.env().foreach(v => envT += (v._1, compactProperty(v._1, v._2)))
+            cfg.getEnv.foreach(v => envT += (v._1, compactProperty(v._1, v._2)))
 
             envT.render()
         } else
             println("\nNo environment variables defined.")
 
-        val sysProps = cfg.systemProperties().toMap
+        val sysProps = cfg.getSystemProperties.toMap
 
         if (sysProps.nonEmpty) {
             println("\nSystem properties:")

http://git-wip-us.apache.org/repos/asf/ignite/blob/12dfe9e8/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/disco/VisorDiscoveryCommand.scala
----------------------------------------------------------------------
diff --git a/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/disco/VisorDiscoveryCommand.scala b/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/disco/VisorDiscoveryCommand.scala
index 0ea88ad..de69cd7 100644
--- a/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/disco/VisorDiscoveryCommand.scala
+++ b/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/disco/VisorDiscoveryCommand.scala
@@ -28,7 +28,7 @@ import org.apache.ignite.visor.visor._
 
 import org.apache.ignite.internal.visor.event.VisorGridDiscoveryEvent
 import org.apache.ignite.internal.visor.node.VisorNodeEventsCollectorTask
-import org.apache.ignite.internal.visor.node.VisorNodeEventsCollectorTask.VisorNodeEventsCollectorTaskArg
+import org.apache.ignite.internal.visor.node.VisorNodeEventsCollectorTaskArg
 
 import scala.collection.JavaConversions._
 import scala.collection.immutable._
@@ -42,7 +42,7 @@ import scala.language.{implicitConversions, reflectiveCalls}
  * {{{
  * +---------------------------------------------------------------------------------------+
  * | disco | Prints topology change log as seen from the oldest node.                      |
- * |       | Timeframe for querying events can be specified in arguments.                  |
+ * |       | Time frame for querying events can be specified in arguments.                 |
  * |       |                                                                               |
  * |       | Note that this command depends on Ignite events.                              |
  * |       |                                                                               |
@@ -66,7 +66,7 @@ import scala.language.{implicitConversions, reflectiveCalls}
  * ====Arguments====
  * {{{
  *     -t=<num>s|m|h|d
- *         Defines timeframe for querying events:
+ *         Defines time frame for querying events:
  *            =<num>s Events fired during last <num> seconds.
  *            =<num>m Events fired during last <num> minutes.
  *            =<num>h Events fired during last <num> hours.
@@ -107,7 +107,7 @@ class VisorDiscoveryCommand extends VisorConsoleCommand {
 
     /**
      * ===Command===
-     * Prints discovery events within specified timeframe.
+     * Prints discovery events within specified time frame.
      *
      * ===Examples===
      * <ex>disco "-r"</ex>
@@ -143,7 +143,7 @@ class VisorDiscoveryCommand extends VisorConsoleCommand {
                     try
                         cntOpt.fold(Int.MaxValue)(_.toInt)
                     catch {
-                        case e: NumberFormatException =>
+                        case _: NumberFormatException =>
                             scold("Invalid count: " + cntOpt.get)
 
                             return
@@ -184,9 +184,9 @@ class VisorDiscoveryCommand extends VisorConsoleCommand {
 
                 evts.take(cnt).foreach {
                     case de: VisorGridDiscoveryEvent =>
-                        t +=(formatDateTime(de.timestamp()), de.name(),
-                            nodeId8(de.evtNodeId()) + (if (de.isDaemon) "(daemon)" else ""),
-                            if (F.isEmpty(de.address())) NA else de.address())
+                        t +=(formatDateTime(de.getTimestamp), de.getName,
+                            nodeId8(de.getEventNodeId) + (if (de.isDaemon) "(daemon)" else ""),
+                            if (F.isEmpty(de.getAddress)) NA else de.getAddress)
                     case _ =>
                 }
 
@@ -221,7 +221,7 @@ class VisorDiscoveryCommand extends VisorConsoleCommand {
             evts = Seq(root) ++ evts
         }
 
-        evts = evts.sortBy(_.timestamp())
+        evts = evts.sortBy(_.getTimestamp)
 
         if (reverse) evts.reverse else evts
     }
@@ -239,7 +239,7 @@ object VisorDiscoveryCommand {
         shortInfo = "Prints topology change log.",
         longInfo = List(
             "Prints topology change log as seen from the oldest node.",
-            "Timeframe for querying events can be specified in arguments.",
+            "Time frame for querying events can be specified in arguments.",
             " ",
             "Note that this command depends on Ignite events.",
             " ",
@@ -257,7 +257,7 @@ object VisorDiscoveryCommand {
         ),
         args = List(
             "-t=<num>s|m|h|d" -> List(
-                "Defines timeframe for quering events:",
+                "Defines time frame for querying events:",
                 "   =<num>s Events fired during last <num> seconds.",
                 "   =<num>m Events fired during last <num> minutes.",
                 "   =<num>h Events fired during last <num> hours.",

http://git-wip-us.apache.org/repos/asf/ignite/blob/12dfe9e8/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/events/VisorEventsCommand.scala
----------------------------------------------------------------------
diff --git a/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/events/VisorEventsCommand.scala b/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/events/VisorEventsCommand.scala
index f56740c..c41eca1 100644
--- a/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/events/VisorEventsCommand.scala
+++ b/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/events/VisorEventsCommand.scala
@@ -28,7 +28,7 @@ import java.util.UUID
 
 import org.apache.ignite.internal.visor.event.VisorGridEvent
 import org.apache.ignite.internal.visor.node.VisorNodeEventsCollectorTask
-import org.apache.ignite.internal.visor.node.VisorNodeEventsCollectorTask.VisorNodeEventsCollectorTaskArg
+import org.apache.ignite.internal.visor.node.VisorNodeEventsCollectorTaskArg
 
 import scala.collection.JavaConversions._
 import scala.collection.immutable._
@@ -182,7 +182,7 @@ class VisorEventsCommand extends VisorConsoleCommand {
     protected def mnemonic(e: VisorGridEvent) = {
         assert(e != null)
 
-        e.typeId() match {
+        e.getTypeId match {
             case t if EVTS_CHECKPOINT.contains(t) => "ch"
             case t if EVTS_DEPLOYMENT.contains(t) => "de"
             case t if EVTS_DISCOVERY_ALL.contains(t) => "di"
@@ -264,8 +264,8 @@ class VisorEventsCommand extends VisorConsoleCommand {
 
                     st += ("Node ID8(@ID)", nodeId8Addr(nid))
                     st += ("Total", sorted.size)
-                    st += ("Earliest timestamp", formatDateTime(evts.maxBy(_.timestamp).timestamp))
-                    st += ("Oldest timestamp", formatDateTime(evts.minBy(_.timestamp).timestamp))
+                    st += ("Earliest timestamp", formatDateTime(evts.maxBy(_.getTimestamp).getTimestamp))
+                    st += ("Oldest timestamp", formatDateTime(evts.minBy(_.getTimestamp).getTimestamp))
 
                     st.render()
 
@@ -276,13 +276,13 @@ class VisorEventsCommand extends VisorConsoleCommand {
                     var sum = Map[Int, (String, Int, Long, Long)]()
 
                     evts.foreach(evt => {
-                        val info = sum.getOrElse(evt.typeId(), (null, 0, Long.MinValue, Long.MaxValue))
+                        val info = sum.getOrElse(evt.getTypeId, (null, 0, Long.MinValue, Long.MaxValue))
 
-                        sum += (evt.typeId -> (
-                            "(" + mnemonic(evt) + ") " + evt.name(),
+                        sum += (evt.getTypeId -> (
+                            "(" + mnemonic(evt) + ") " + evt.getName,
                             info._2 + 1,
-                            if (evt.timestamp() > info._3) evt.timestamp() else info._3,
-                            if (evt.timestamp() < info._4) evt.timestamp() else info._4)
+                            if (evt.getTimestamp > info._3) evt.getTimestamp else info._3,
+                            if (evt.getTimestamp < info._4) evt.getTimestamp else info._4)
                             )
                     })
 
@@ -322,7 +322,7 @@ class VisorEventsCommand extends VisorConsoleCommand {
                     all #= ("Timestamp", "Description")
 
                     sorted.take(cnt).foreach(evt =>
-                        all += (formatDateTime(evt.timestamp()), U.compact(evt.shortDisplay))
+                        all += (formatDateTime(evt.getTimestamp), U.compact(evt.getShortDisplay))
                     )
 
                     all.render()
@@ -365,8 +365,8 @@ class VisorEventsCommand extends VisorConsoleCommand {
             Some(evts)
         else
             arg.get.trim match {
-                case "e" => Some(if (reverse) evts.sortBy(_.name).reverse else evts.sortBy(_.name))
-                case "t" => Some(if (reverse) evts.sortBy(_.timestamp).reverse else evts.sortBy(_.timestamp))
+                case "e" => Some(if (reverse) evts.sortBy(_.getName).reverse else evts.sortBy(_.getName))
+                case "t" => Some(if (reverse) evts.sortBy(_.getTimestamp).reverse else evts.sortBy(_.getTimestamp))
                 case a: String =>
                     scold("Invalid sorting argument: " + a)
 
@@ -400,7 +400,7 @@ object VisorEventsCommand {
         ),
         spec = List(
             "events",
-            "events {-id=<node-id>|-id8=<node-id8>} {-e=<ch,de,di,jo,ta,ca,cr,sw>}",
+            "events {-id=<node-id>|-id8=<node-id8>} {-e=<ch,de,di,jo,ta,ca,cr>}",
             "    {-t=<num>s|m|h|d} {-s=e|t} {-r} {-c=<n>}"
         ),
         args = List(
@@ -417,7 +417,7 @@ object VisorEventsCommand {
                 "Either '-id' or '-id8' can be specified.",
                 "If called without the arguments - starts in interactive mode."
             ),
-            "-e=<ch,de,di,jo,ta,ca,cr,sw>" -> List(
+            "-e=<ch,de,di,jo,ta,ca,cr>" -> List(
                 "Comma separated list of event types that should be queried:",
                 "   ch Checkpoint events.",
                 "   de Deployment events.",
@@ -428,7 +428,7 @@ object VisorEventsCommand {
                 "   cr Cache rebalance events."
             ),
             "-t=<num>s|m|h|d" -> List(
-                "Defines time frame for quering events:",
+                "Defines time frame for querying events:",
                 "   =<num>s Queries events fired during last <num> seconds.",
                 "   =<num>m Queries events fired during last <num> minutes.",
                 "   =<num>h Queries events fired during last <num> hours.",

http://git-wip-us.apache.org/repos/asf/ignite/blob/12dfe9e8/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/gc/VisorGcCommand.scala
----------------------------------------------------------------------
diff --git a/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/gc/VisorGcCommand.scala b/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/gc/VisorGcCommand.scala
index 990fd00..5f642d7 100644
--- a/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/gc/VisorGcCommand.scala
+++ b/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/gc/VisorGcCommand.scala
@@ -104,8 +104,8 @@ class VisorGcCommand extends VisorConsoleCommand {
 
                 res.foreach {
                     case (nid, stat) =>
-                        val roundHb = stat.get1() / (1024L * 1024L)
-                        val roundHa = stat.get2() / (1024L * 1024L)
+                        val roundHb = stat.getSizeBefore / (1024L * 1024L)
+                        val roundHa = stat.getSizeAfter / (1024L * 1024L)
 
                         val sign = if (roundHa > roundHb) "+" else ""
 

http://git-wip-us.apache.org/repos/asf/ignite/blob/12dfe9e8/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/tasks/VisorTasksCommand.scala
----------------------------------------------------------------------
diff --git a/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/tasks/VisorTasksCommand.scala b/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/tasks/VisorTasksCommand.scala
index 0468e80..4d9b795 100644
--- a/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/tasks/VisorTasksCommand.scala
+++ b/modules/visor-console/src/main/scala/org/apache/ignite/visor/commands/tasks/VisorTasksCommand.scala
@@ -31,7 +31,7 @@ import java.util.UUID
 
 import org.apache.ignite.internal.visor.event.{VisorGridEvent, VisorGridJobEvent, VisorGridTaskEvent}
 import org.apache.ignite.internal.visor.node.VisorNodeEventsCollectorTask
-import org.apache.ignite.internal.visor.node.VisorNodeEventsCollectorTask.VisorNodeEventsCollectorTaskArg
+import org.apache.ignite.internal.visor.node.VisorNodeEventsCollectorTaskArg
 
 import scala.collection.JavaConversions._
 import scala.language.implicitConversions
@@ -91,37 +91,37 @@ private case class VisorExecution(
      * Gets number of job rejections in this session.
      */
     lazy val rejections: Int =
-        evts.count(_.typeId() == EVT_JOB_REJECTED)
+        evts.count(_.getTypeId == EVT_JOB_REJECTED)
 
     /**
      * Gets number of job cancellations in this session.
      */
     lazy val cancels: Int =
-        evts.count(_.typeId() == EVT_JOB_CANCELLED)
+        evts.count(_.getTypeId == EVT_JOB_CANCELLED)
 
     /**
      * Gets number of job finished in this session.
      */
     lazy val finished: Int =
-        evts.count(_.typeId() == EVT_JOB_FINISHED)
+        evts.count(_.getTypeId == EVT_JOB_FINISHED)
 
     /**
      * Gets number of job started in this session.
      */
     lazy val started: Int =
-        evts.count(_.typeId() == EVT_JOB_STARTED)
+        evts.count(_.getTypeId == EVT_JOB_STARTED)
 
     /**
      * Gets number of job failures in this session.
      */
     lazy val failures: Int =
-        evts.count(_.typeId() == EVT_JOB_FAILED)
+        evts.count(_.getTypeId == EVT_JOB_FAILED)
 
     /**
      * Gets number of job failovers in this session.
      */
     lazy val failovers: Int =
-        evts.count(_.typeId() == EVT_JOB_FAILED_OVER)
+        evts.count(_.getTypeId == EVT_JOB_FAILED_OVER)
 
     /**
      * Gets duration of the session.
@@ -420,7 +420,7 @@ class VisorTasksCommand extends VisorConsoleCommand {
             else if (hasArgName("n", argLst)) {
                 val n = argValue("n", argLst)
 
-                if (!n.isDefined)
+                if (n.isEmpty)
                     scold("Invalid arguments: " + args)
                 else
                     task(n.get, hasArgFlag("r", argLst), hasArgFlag("a", argLst))
@@ -428,7 +428,7 @@ class VisorTasksCommand extends VisorConsoleCommand {
             else if (hasArgName("e", argLst)) {
                 val s = argValue("e", argLst)
 
-                if (!s.isDefined)
+                if (s.isEmpty)
                     scold("Invalid arguments: " + args)
                 else
                     exec(s.get, hasArgFlag("r", argLst))
@@ -541,28 +541,28 @@ class VisorTasksCommand extends VisorConsoleCommand {
 
         evts.foreach {
             case te: VisorGridTaskEvent =>
-                val displayedTaskName = taskSimpleName(te.taskName(), te.taskClassName())
+                val displayedTaskName = taskSimpleName(te.getTaskName(), te.getTaskClassName())
 
-                val s = getSession(te.taskSessionId(), displayedTaskName)
+                val s = getSession(te.getTaskSessionId(), displayedTaskName)
                 val t = getTask(displayedTaskName)
 
                 t.execs = t.execs + s
 
                 s.evts = s.evts :+ te
-                s.nodeIds = s.nodeIds + te.nid()
-                s.startTs = math.min(s.startTs, te.timestamp())
-                s.endTs = math.max(s.endTs, te.timestamp())
+                s.nodeIds = s.nodeIds + te.getNid
+                s.startTs = math.min(s.startTs, te.getTimestamp)
+                s.endTs = math.max(s.endTs, te.getTimestamp)
 
-                te.typeId() match {
+                te.getTypeId match {
                     case EVT_TASK_STARTED =>
                         if (s.state == UNDEFINED) s.state = STARTED
 
-                        s.origNodeId = te.nid()
+                        s.origNodeId = te.getNid
 
                     case EVT_TASK_FINISHED =>
                         if (s.state == UNDEFINED || s.state == STARTED) s.state = FINISHED
 
-                        s.origNodeId = te.nid()
+                        s.origNodeId = te.getNid
 
                     case EVT_TASK_FAILED => if (s.state == UNDEFINED || s.state == STARTED) s.state = FAILED
                     case EVT_TASK_TIMEDOUT => if (s.state == UNDEFINED || s.state == STARTED) s.state = TIMEDOUT
@@ -570,23 +570,23 @@ class VisorTasksCommand extends VisorConsoleCommand {
                 }
 
             case je: VisorGridJobEvent =>
-                val displayedTaskName = taskSimpleName(je.taskName(), je.taskClassName())
-                val s = getSession(je.taskSessionId(), displayedTaskName)
+                val displayedTaskName = taskSimpleName(je.getTaskName(), je.getTaskClassName())
+                val s = getSession(je.getTaskSessionId(), displayedTaskName)
                 val t = getTask(displayedTaskName)
 
                 t.execs = t.execs + s
 
                 // Collect node IDs where jobs didn't finish ok.
-                je.typeId() match {
+                je.getTypeId match {
                     case EVT_JOB_CANCELLED | EVT_JOB_FAILED | EVT_JOB_REJECTED | EVT_JOB_TIMEDOUT =>
-                        s.failedNodeIds = s.failedNodeIds + je.nid()
+                        s.failedNodeIds = s.failedNodeIds + je.getNid
                     case _ =>
                 }
 
                 s.evts = s.evts :+ je
-                s.nodeIds = s.nodeIds + je.nid()
-                s.startTs = math.min(s.startTs, je.timestamp())
-                s.endTs = math.max(s.endTs, je.timestamp())
+                s.nodeIds = s.nodeIds + je.getNid
+                s.startTs = math.min(s.startTs, je.getTimestamp)
+                s.endTs = math.max(s.endTs, je.getTimestamp)
 
             case _ =>
         }
@@ -1063,13 +1063,12 @@ class VisorTasksCommand extends VisorConsoleCommand {
 
                 evtsT #= ("Timestamp", "Node ID8(@)", "Event")
 
-                val se = if (!reverse) e.evts.sortBy(_.timestamp()) else e.evts.sortBy(_.timestamp()).reverse
+                val se = if (!reverse) e.evts.sortBy(_.getTimestamp) else e.evts.sortBy(_.getTimestamp).reverse
 
                 se.foreach(e => evtsT += (
-                    formatDateTime(e.timestamp()),
-                    nodeId8Addr(e.nid()),
-                    e.name()
-                    ))
+                    formatDateTime(e.getTimestamp),
+                    nodeId8Addr(e.getNid),
+                    e.getName))
 
                 println("\nTrace:")
 
@@ -1142,7 +1141,7 @@ class VisorTasksCommand extends VisorConsoleCommand {
                     }
 
                     sortedNames.foreach(taskName => {
-                        val t = VisorTask(taskName, execsMap.get(taskName).get)
+                        val t = VisorTask(taskName, execsMap(taskName))
 
                         val sE = t.execsFor(STARTED)
                         val fE = t.execsFor(FINISHED)
@@ -1256,7 +1255,7 @@ class VisorTasksCommand extends VisorConsoleCommand {
                     }
 
                     sortedNames.foreach(taskName => {
-                        val t = VisorTask(taskName, execsMap.get(taskName).get)
+                        val t = VisorTask(taskName, execsMap(taskName))
 
                         val sE = t.execsFor(STARTED)
                         val fE = t.execsFor(FINISHED)

http://git-wip-us.apache.org/repos/asf/ignite/blob/12dfe9e8/modules/visor-console/src/main/scala/org/apache/ignite/visor/visor.scala
----------------------------------------------------------------------
diff --git a/modules/visor-console/src/main/scala/org/apache/ignite/visor/visor.scala b/modules/visor-console/src/main/scala/org/apache/ignite/visor/visor.scala
index ea60c87..e1dd14e 100644
--- a/modules/visor-console/src/main/scala/org/apache/ignite/visor/visor.scala
+++ b/modules/visor-console/src/main/scala/org/apache/ignite/visor/visor.scala
@@ -43,7 +43,7 @@ import java.util.concurrent._
 import java.util.{Collection => JavaCollection, HashSet => JavaHashSet, _}
 
 import org.apache.ignite.internal.visor.cache._
-import org.apache.ignite.internal.visor.node.VisorNodeEventsCollectorTask.VisorNodeEventsCollectorTaskArg
+import org.apache.ignite.internal.visor.node.VisorNodeEventsCollectorTaskArg
 import org.apache.ignite.internal.visor.node._
 import org.apache.ignite.internal.visor.util.VisorEventMapper
 import org.apache.ignite.internal.visor.util.VisorTaskUtils._
@@ -152,16 +152,16 @@ object visor extends VisorTag {
     private var cmdLst: Seq[VisorCommandHolder] = Nil
 
     /** Node left listener. */
-    private var nodeLeftLsnr: IgnitePredicate[Event] = null
+    private var nodeLeftLsnr: IgnitePredicate[Event] = _
 
     /** Node join listener. */
-    private var nodeJoinLsnr: IgnitePredicate[Event] = null
+    private var nodeJoinLsnr: IgnitePredicate[Event] = _
 
     /** Node segmentation listener. */
-    private var nodeSegLsnr: IgnitePredicate[Event] = null
+    private var nodeSegLsnr: IgnitePredicate[Event] = _
 
     /** Node stop listener. */
-    private var nodeStopLsnr: IgnitionListener = null
+    private var nodeStopLsnr: IgnitionListener = _
 
     /** */
     @volatile private var isCon: Boolean = false
@@ -209,13 +209,13 @@ object visor extends VisorTag {
     private final val DFLT_LOG_PATH = "visor/visor-log"
 
     /** Log file. */
-    private var logFile: File = null
+    private var logFile: File = _
 
     /** Log timer. */
-    private var logTimer: Timer = null
+    private var logTimer: Timer = _
 
     /** Topology log timer. */
-    private var topTimer: Timer = null
+    private var topTimer: Timer = _
 
     /** Log started flag. */
     @volatile private var logStarted = false
@@ -224,15 +224,15 @@ object visor extends VisorTag {
     @volatile var pool: ExecutorService = new IgniteThreadPoolExecutor()
 
     /** Configuration file path, if any. */
-    @volatile var cfgPath: String = null
+    @volatile var cfgPath: String = _
 
     /** */
-    @volatile var ignite: IgniteEx = null
+    @volatile var ignite: IgniteEx = _
 
     /** */
     @volatile var prevIgnite: Option[IgniteEx] = None
 
-    private var reader: ConsoleReader = null
+    private var reader: ConsoleReader = _
 
     var batchMode: Boolean = false
 
@@ -1674,7 +1674,7 @@ object visor extends VisorTag {
             val id8 = nid8(id)
             var v = mfindHead(id8)
 
-            if(!v.isDefined){
+            if(v.isEmpty){
                v = assignNodeValue(n)
             }
 
@@ -2454,15 +2454,15 @@ object visor extends VisorTag {
                             try {
                                 out = new FileWriter(logFile, true)
 
-                                evts.toList.sortBy(_.timestamp).foreach(e => {
+                                evts.toList.sortBy(_.getTimestamp).foreach(e => {
                                     logImpl(
                                         out,
-                                        formatDateTime(e.timestamp),
-                                        nodeId8Addr(e.nid()),
-                                        U.compact(e.shortDisplay())
+                                        formatDateTime(e.getTimestamp),
+                                        nodeId8Addr(e.getNid),
+                                        U.compact(e.getShortDisplay)
                                     )
 
-                                    if (EVTS_DISCOVERY.contains(e.typeId()))
+                                    if (EVTS_DISCOVERY.contains(e.getTypeId))
                                         snapshot()
                                 })
                             }

http://git-wip-us.apache.org/repos/asf/ignite/blob/12dfe9e8/modules/web-console/backend/app/agent.js
----------------------------------------------------------------------
diff --git a/modules/web-console/backend/app/agent.js b/modules/web-console/backend/app/agent.js
index f65eabb..758d31b 100644
--- a/modules/web-console/backend/app/agent.js
+++ b/modules/web-console/backend/app/agent.js
@@ -236,32 +236,43 @@ module.exports.factory = function(_, fs, path, JSZip, socketio, settings, mongo,
             const cmd = new Command(demo, 'exe')
                 .addParam('name', 'org.apache.ignite.internal.visor.compute.VisorGatewayTask')
                 .addParam('p1', nid)
-                .addParam('p2', 'org.apache.ignite.internal.visor.query.VisorQueryTask');
-
-            if (enforceJoinOrder) {
-                cmd.addParam('p3', 'org.apache.ignite.internal.visor.query.VisorQueryArgV3')
-                    .addParam('p4', cacheName)
-                    .addParam('p5', query)
-                    .addParam('p6', nonCollocatedJoins)
-                    .addParam('p7', enforceJoinOrder)
-                    .addParam('p8', local)
-                    .addParam('p9', pageSize);
-            }
-            else if (nonCollocatedJoins) {
-                cmd.addParam('p3', 'org.apache.ignite.internal.visor.query.VisorQueryArgV2')
-                    .addParam('p4', cacheName)
-                    .addParam('p5', query)
-                    .addParam('p6', true)
-                    .addParam('p7', local)
-                    .addParam('p8', pageSize);
-            }
-            else {
-                cmd.addParam('p3', 'org.apache.ignite.internal.visor.query.VisorQueryArg')
-                    .addParam('p4', cacheName)
-                    .addParam('p5', query)
-                    .addParam('p6', local)
-                    .addParam('p7', pageSize);
-            }
+                .addParam('p2', 'org.apache.ignite.internal.visor.query.VisorQueryTask')
+                .addParam('p3', 'org.apache.ignite.internal.visor.query.VisorQueryArg')
+                .addParam('p4', cacheName)
+                .addParam('p5', query)
+                .addParam('p6', nonCollocatedJoins)
+                .addParam('p7', enforceJoinOrder)
+                .addParam('p8', local)
+                .addParam('p9', pageSize);
+
+            return this.executeRest(cmd);
+        }
+
+        /**
+         * @param {Boolean} demo Is need run command on demo node.
+         * @param {String} nid Node id.
+         * @param {String} cacheName Cache name.
+         * @param {String} filter Filter text.
+         * @param {Boolean} regEx Flag whether filter by regexp.
+         * @param {Boolean} caseSensitive Case sensitive filtration.
+         * @param {Boolean} near Scan near cache.
+         * @param {Boolean} local Flag whether to execute query locally.
+         * @param {int} pageSize Page size.
+         * @returns {Promise}
+         */
+        queryScan(demo, nid, cacheName, filter, regEx, caseSensitive, near, local, pageSize) {
+            const cmd = new Command(demo, 'exe')
+                .addParam('name', 'org.apache.ignite.internal.visor.compute.VisorGatewayTask')
+                .addParam('p1', nid)
+                .addParam('p2', 'org.apache.ignite.internal.visor.query.VisorScanQueryTask')
+                .addParam('p3', 'org.apache.ignite.internal.visor.query.VisorScanQueryArg')
+                .addParam('p4', cacheName)
+                .addParam('p5', filter)
+                .addParam('p6', regEx)
+                .addParam('p7', caseSensitive)
+                .addParam('p8', near)
+                .addParam('p9', local)
+                .addParam('p10', pageSize);
 
             return this.executeRest(cmd);
         }
@@ -278,7 +289,7 @@ module.exports.factory = function(_, fs, path, JSZip, socketio, settings, mongo,
                 .addParam('name', 'org.apache.ignite.internal.visor.compute.VisorGatewayTask')
                 .addParam('p1', nid)
                 .addParam('p2', 'org.apache.ignite.internal.visor.query.VisorQueryNextPageTask')
-                .addParam('p3', 'org.apache.ignite.lang.IgniteBiTuple')
+                .addParam('p3', 'org.apache.ignite.lang.VisorQueryNextPageTaskArg')
                 .addParam('p4', 'java.lang.String')
                 .addParam('p5', 'java.lang.Integer')
                 .addParam('p6', queryId)
@@ -316,7 +327,7 @@ module.exports.factory = function(_, fs, path, JSZip, socketio, settings, mongo,
             const cmd = new Command(demo, 'exe')
                 .addParam('name', 'org.apache.ignite.internal.visor.compute.VisorGatewayTask')
                 .addParam('p1', nids)
-                .addParam('p2', 'org.apache.ignite.internal.visor.cache.VisorCacheQueryDetailMetricsCollectorTask')
+                .addParam('p2', 'org.apache.ignite.internal.visor.query.VisorQueryDetailMetricsCollectorTask')
                 .addParam('p3', 'java.lang.Long')
                 .addParam('p4', since);
 
@@ -332,7 +343,7 @@ module.exports.factory = function(_, fs, path, JSZip, socketio, settings, mongo,
             const cmd = new Command(demo, 'exe')
                 .addParam('name', 'org.apache.ignite.internal.visor.compute.VisorGatewayTask')
                 .addParam('p1', nids)
-                .addParam('p2', 'org.apache.ignite.internal.visor.cache.VisorCacheResetQueryDetailMetricsTask')
+                .addParam('p2', 'org.apache.ignite.internal.visor.query.VisorQueryResetDetailMetricsTask')
                 .addParam('p3', 'java.lang.Void');
 
             return this.executeRest(cmd);
@@ -348,7 +359,7 @@ module.exports.factory = function(_, fs, path, JSZip, socketio, settings, mongo,
             const cmd = new Command(demo, 'exe')
                 .addParam('name', 'org.apache.ignite.internal.visor.compute.VisorGatewayTask')
                 .addParam('p1', '')
-                .addParam('p2', 'org.apache.ignite.internal.visor.query.VisorCollectRunningQueriesTask')
+                .addParam('p2', 'org.apache.ignite.internal.visor.query.VisorRunningQueriesCollectorTask')
                 .addParam('p3', 'java.lang.Long')
                 .addParam('p4', duration);
 
@@ -366,10 +377,9 @@ module.exports.factory = function(_, fs, path, JSZip, socketio, settings, mongo,
             const cmd = new Command(demo, 'exe')
                 .addParam('name', 'org.apache.ignite.internal.visor.compute.VisorGatewayTask')
                 .addParam('p1', nid)
-                .addParam('p2', 'org.apache.ignite.internal.visor.query.VisorCancelQueriesTask')
-                .addParam('p3', 'java.util.Collection')
-                .addParam('p4', 'java.lang.Long')
-                .addParam('p5', queryId);
+                .addParam('p2', 'org.apache.ignite.internal.visor.query.VisorQueryCancelTask')
+                .addParam('p3', 'java.lang.Long')
+                .addParam('p4', queryId);
 
             return this.executeRest(cmd);
         }
@@ -471,7 +481,7 @@ module.exports.factory = function(_, fs, path, JSZip, socketio, settings, mongo,
                 .addParam('name', 'org.apache.ignite.internal.visor.compute.VisorGatewayTask')
                 .addParam('p1', nids)
                 .addParam('p2', 'org.apache.ignite.internal.visor.cache.VisorCacheStartTask')
-                .addParam('p3', 'org.apache.ignite.internal.visor.cache.VisorCacheStartTask$VisorCacheStartArg')
+                .addParam('p3', 'org.apache.ignite.internal.visor.cache.VisorCacheStartArg')
                 .addParam('p4', near)
                 .addParam('p5', cacheName)
                 .addParam('p6', cfg);
@@ -515,24 +525,6 @@ module.exports.factory = function(_, fs, path, JSZip, socketio, settings, mongo,
 
         /**
          * @param {Boolean} demo Is need run command on demo node.
-         * @param {String} nid Node id.
-         * @param {String} cacheNames Cache names separated by comma.
-         * @returns {Promise}
-         */
-        cacheSwapBackups(demo, nid, cacheNames) {
-            const cmd = new Command(demo, 'exe')
-                .addParam('name', 'org.apache.ignite.internal.visor.compute.VisorGatewayTask')
-                .addParam('p1', nid)
-                .addParam('p2', 'org.apache.ignite.internal.visor.cache.VisorCacheSwapBackupsTask')
-                .addParam('p3', 'java.util.Set')
-                .addParam('p4', 'java.lang.String')
-                .addParam('p5', cacheNames);
-
-            return this.executeRest(cmd);
-        }
-
-        /**
-         * @param {Boolean} demo Is need run command on demo node.
          * @param {String} nids Node ids.
          * @returns {Promise}
          */

http://git-wip-us.apache.org/repos/asf/ignite/blob/12dfe9e8/modules/web-console/backend/app/browser.js
----------------------------------------------------------------------
diff --git a/modules/web-console/backend/app/browser.js b/modules/web-console/backend/app/browser.js
index 00ae751..e9266a8 100644
--- a/modules/web-console/backend/app/browser.js
+++ b/modules/web-console/backend/app/browser.js
@@ -113,6 +113,19 @@ module.exports.factory = (_, socketio, agentMgr, configure) => {
                         .catch((err) => cb(_errorToJson(err)));
                 });
 
+                const fetchResult = (acc) => {
+                    if (!acc.hasMore)
+                        return acc;
+
+                    return agent.queryFetch(demo, acc.responseNodeId, acc.queryId, pageSize)
+                        .then(({result}) => {
+                            acc.rows = acc.rows.concat(result.rows);
+                            acc.hasMore = result.hasMore;
+
+                            return fetchResult(acc);
+                        });
+                };
+
                 // Execute query on node and return full result to browser.
                 socket.on('node:query:getAll', (nid, cacheName, query, distributedJoins, enforceJoinOrder, local, cb) => {
                     // Set page size for query.
@@ -122,26 +135,12 @@ module.exports.factory = (_, socketio, agentMgr, configure) => {
                         .then((agent) => {
                             const firstPage = agent.fieldsQuery(demo, nid, cacheName, query, distributedJoins, enforceJoinOrder, local, pageSize)
                                 .then(({result}) => {
-                                    if (result.key)
-                                        return Promise.reject(result.key);
+                                    if (result.error)
+                                        return Promise.reject(result.error);
 
-                                    return result.value;
+                                    return result.result;
                                 });
 
-                            const fetchResult = (acc) => {
-                                if (!acc.hasMore)
-                                    return acc;
-
-                                return agent.queryFetch(demo, acc.responseNodeId, acc.queryId, pageSize)
-                                    .then(({result}) => {
-                                        acc.rows = acc.rows.concat(result.rows);
-
-                                        acc.hasMore = result.hasMore;
-
-                                        return fetchResult(acc);
-                                    });
-                            };
-
                             return firstPage
                                 .then(fetchResult);
                         })
@@ -203,6 +202,36 @@ module.exports.factory = (_, socketio, agentMgr, configure) => {
                         .catch((err) => cb(_errorToJson(err)));
                 });
 
+                // Execute scan query on node and return first page to browser.
+                socket.on('node:scan', (nid, cacheName, filter, regEx, caseSensitive, near, local, pageSize, cb) => {
+                    agentMgr.findAgent(accountId())
+                        .then((agent) => agent.queryScan(demo, nid, cacheName, filter, regEx, caseSensitive, near, local, pageSize))
+                        .then((res) => cb(null, res))
+                        .catch((err) => cb(_errorToJson(err)));
+                });
+
+                // Execute scan on node and return full result to browser.
+                socket.on('node:scan:getAll', (nid, cacheName, filter, regEx, caseSensitive, near, local, cb) => {
+                    // Set page size for query.
+                    const pageSize = 1024;
+
+                    agentMgr.findAgent(accountId())
+                        .then((agent) => {
+                            const firstPage = agent.queryScan(demo, nid, cacheName, filter, regEx, caseSensitive, near, local, pageSize)
+                                .then(({result}) => {
+                                    if (result.error)
+                                        return Promise.reject(result.error);
+
+                                    return result.result;
+                                });
+
+                            return firstPage
+                                .then(fetchResult);
+                        })
+                        .then((res) => cb(null, res))
+                        .catch((err) => cb(_errorToJson(err)));
+                });
+
                 // Return cache metadata from all nodes in grid.
                 socket.on('node:cache:metadata', (cacheName, cb) => {
                     agentMgr.findAgent(accountId())
@@ -339,19 +368,6 @@ module.exports.factory = (_, socketio, agentMgr, configure) => {
                         .catch((err) => cb(_errorToJson(err)));
                 });
 
-                // Swap backups specified caches on specified node and return result to browser.
-                socket.on('node:cache:swap:backups', (nid, cacheNames, cb) => {
-                    agentMgr.findAgent(accountId())
-                        .then((agent) => agent.cacheSwapBackups(demo, nid, cacheNames))
-                        .then((data) => {
-                            if (data.finished)
-                                return cb(null, data.result);
-
-                            cb(_errorToJson(data.error));
-                        })
-                        .catch((err) => cb(_errorToJson(err)));
-                });
-
                 // Reset metrics specified cache on specified node and return result to browser.
                 socket.on('node:cache:reset:metrics', (nid, cacheName, cb) => {
                     agentMgr.findAgent(accountId())

http://git-wip-us.apache.org/repos/asf/ignite/blob/12dfe9e8/modules/web-console/backend/app/mongo.js
----------------------------------------------------------------------
diff --git a/modules/web-console/backend/app/mongo.js b/modules/web-console/backend/app/mongo.js
index f4a62b1..0da9aa9 100644
--- a/modules/web-console/backend/app/mongo.js
+++ b/modules/web-console/backend/app/mongo.js
@@ -144,6 +144,7 @@ module.exports.factory = function(passportMongo, settings, pluginMongo, mongoose
         domains: [{type: ObjectId, ref: 'DomainModel'}],
         cacheMode: {type: String, enum: ['PARTITIONED', 'REPLICATED', 'LOCAL']},
         atomicityMode: {type: String, enum: ['ATOMIC', 'TRANSACTIONAL']},
+        partitionLossPolicy: {type: String, enum: ['READ_ONLY_SAFE', 'READ_ONLY_ALL', 'READ_WRITE_SAFE', 'READ_WRITE_ALL', 'IGNORE']},
 
         affinity: {
             kind: {type: String, enum: ['Default', 'Rendezvous', 'Fair', 'Custom']},
@@ -178,10 +179,9 @@ module.exports.factory = function(passportMongo, settings, pluginMongo, mongoose
         },
 
         backups: Number,
-        memoryMode: {type: String, enum: ['ONHEAP_TIERED', 'OFFHEAP_TIERED', 'OFFHEAP_VALUES']},
-        offHeapMaxMemory: Number,
         startSize: Number,
-        swapEnabled: Boolean,
+
+        onheapCacheEnabled: Boolean,
 
         evictionPolicy: {
             kind: {type: String, enum: ['LRU', 'FIFO', 'SORTED']},
@@ -272,6 +272,7 @@ module.exports.factory = function(passportMongo, settings, pluginMongo, mongoose
         sqlFunctionClasses: [String],
         snapshotableIndex: Boolean,
         queryDetailMetricsSize: Number,
+        queryParallelism: Number,
         statisticsEnabled: Boolean,
         managementEnabled: Boolean,
         readFromBackup: Boolean,
@@ -334,7 +335,7 @@ module.exports.factory = function(passportMongo, settings, pluginMongo, mongoose
         clusters: [{type: ObjectId, ref: 'Cluster'}],
         affinnityGroupSize: Number,
         blockSize: Number,
-        streamBufferSize: Number,
+        bufferSize: Number,
         dataCacheName: String,
         metaCacheName: String,
         defaultMode: {type: String, enum: ['PRIMARY', 'PROXY', 'DUAL_SYNC', 'DUAL_ASYNC']},
@@ -582,8 +583,6 @@ module.exports.factory = function(passportMongo, settings, pluginMongo, mongoose
             }
         },
         marshalLocalJobs: Boolean,
-        marshallerCacheKeepAliveTime: Number,
-        marshallerCacheThreadPoolSize: Number,
         metricsExpireTime: Number,
         metricsHistorySize: Number,
         metricsLogFrequency: Number,
@@ -641,16 +640,6 @@ module.exports.factory = function(passportMongo, settings, pluginMongo, mongoose
         peerClassLoadingMissedResourcesCacheSize: Number,
         peerClassLoadingThreadPoolSize: Number,
         publicThreadPoolSize: Number,
-        swapSpaceSpi: {
-            kind: {type: String, enum: ['FileSwapSpaceSpi']},
-            FileSwapSpaceSpi: {
-                baseDirectory: String,
-                readStripesNumber: Number,
-                maximumSparsity: Number,
-                maxWriteQueueSize: Number,
-                writeBufferSize: Number
-            }
-        },
         systemThreadPoolSize: Number,
         timeServerPortBase: Number,
         timeServerPortRange: Number,

http://git-wip-us.apache.org/repos/asf/ignite/blob/12dfe9e8/modules/web-console/frontend/app/modules/agent/agent.module.js
----------------------------------------------------------------------
diff --git a/modules/web-console/frontend/app/modules/agent/agent.module.js b/modules/web-console/frontend/app/modules/agent/agent.module.js
index 724fc6c..b20a5bc 100644
--- a/modules/web-console/frontend/app/modules/agent/agent.module.js
+++ b/modules/web-console/frontend/app/modules/agent/agent.module.js
@@ -273,10 +273,10 @@ class IgniteAgentMonitor {
     query(nid, cacheName, query, nonCollocatedJoins, enforceJoinOrder, local, pageSize) {
         return this._rest('node:query', nid, maskNull(cacheName), maskNull(query), nonCollocatedJoins, enforceJoinOrder, local, pageSize)
             .then(({result}) => {
-                if (_.isEmpty(result.key))
-                    return result.value;
+                if (_.isEmpty(result.error))
+                    return result.result;
 
-                return Promise.reject(result.key);
+                return Promise.reject(result.error);
             });
     }
 
@@ -295,6 +295,41 @@ class IgniteAgentMonitor {
 
     /**
      * @param {String} nid Node id.
+     * @param {String} cacheName Cache name.
+     * @param {String} filter Optional filter for scan query.
+     * @param {Boolean} regEx Flag whether filter by regexp.
+     * @param {Boolean} caseSensitive Case sensitive filtration.
+     * @param {Boolean} near Scan near cache.
+     * @param {Boolean} local Flag whether to execute query locally.
+     * @param {int} pageSize
+     * @returns {Promise}
+     */
+    scan(nid, cacheName, filter, regEx, caseSensitive, near, local, pageSize) {
+        return this._rest('node:scan', nid, maskNull(cacheName), maskNull(filter), regEx, caseSensitive, near, local, pageSize)
+            .then(({result}) => {
+                if (_.isEmpty(result.error))
+                    return result.result;
+
+                return Promise.reject(result.error);
+            });
+    }
+
+    /**
+     * @param {String} nid Node id.
+     * @param {String} cacheName Cache name.
+     * @param {String} filter Optional filter for scan query.
+     * @param {Boolean} regEx Flag whether filter by regexp.
+     * @param {Boolean} caseSensitive Case sensitive filtration.
+     * @param {Boolean} near Scan near cache.
+     * @param {Boolean} local Flag whether to execute query locally.
+     * @returns {Promise}
+     */
+    scanGetAll(nid, cacheName, filter, regEx, caseSensitive, near, local) {
+        return this._rest('node:scan:getAll', nid, maskNull(cacheName), maskNull(filter), regEx, caseSensitive, near, local);
+    }
+
+    /**
+     * @param {String} nid Node id.
      * @param {int} queryId
      * @param {int} pageSize
      * @returns {Promise}

http://git-wip-us.apache.org/repos/asf/ignite/blob/12dfe9e8/modules/web-console/frontend/app/modules/configuration/generator/AbstractTransformer.js
----------------------------------------------------------------------
diff --git a/modules/web-console/frontend/app/modules/configuration/generator/AbstractTransformer.js b/modules/web-console/frontend/app/modules/configuration/generator/AbstractTransformer.js
index 40d937e..40641d9 100644
--- a/modules/web-console/frontend/app/modules/configuration/generator/AbstractTransformer.js
+++ b/modules/web-console/frontend/app/modules/configuration/generator/AbstractTransformer.js
@@ -150,11 +150,6 @@ export default class AbstractTransformer {
         return this.toSection(this.generator.clusterSsl(cluster));
     }
 
-    // Generate swap group.
-    static clusterSwap(cluster) {
-        return this.toSection(this.generator.clusterSwap(cluster));
-    }
-
     // Generate time group.
     static clusterTime(cluster) {
         return this.toSection(this.generator.clusterTime(cluster));


Mime
View raw message