ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From voze...@apache.org
Subject ignite git commit: IGNITE-6850: SQL: Added INLINE_SIZE option support to CREATE INDEX statement. This closes #3013.
Date Fri, 17 Nov 2017 13:17:36 GMT
Repository: ignite
Updated Branches:
  refs/heads/master 19bddc693 -> 8ee6cb5cf


IGNITE-6850: SQL: Added INLINE_SIZE option support to CREATE INDEX statement. This closes
#3013.


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

Branch: refs/heads/master
Commit: 8ee6cb5cf6832f53dcfb7e0f1ca915d39a532017
Parents: 19bddc6
Author: gg-shq <kshirokov@gmail.com>
Authored: Fri Nov 17 16:17:28 2017 +0300
Committer: devozerov <vozerov@gridgain.com>
Committed: Fri Nov 17 16:17:28 2017 +0300

----------------------------------------------------------------------
 .../apache/ignite/IgniteSystemProperties.java   |   3 +
 .../apache/ignite/internal/sql/SqlKeyword.java  |   3 +
 .../ignite/internal/sql/SqlParserUtils.java     |  25 +++-
 .../sql/command/SqlCreateIndexCommand.java      |  41 +++++-
 .../sql/SqlParserCreateIndexSelfTest.java       |  23 +++
 .../processors/query/h2/IgniteH2Indexing.java   |  12 +-
 .../query/h2/ddl/DdlStatementsProcessor.java    |   1 +
 .../cache/index/AbstractSchemaSelfTest.java     |  22 ++-
 .../DynamicIndexAbstractBasicSelfTest.java      | 147 ++++++++++++++++++-
 .../DynamicIndexAbstractConcurrentSelfTest.java |  29 ++--
 .../cache/index/SchemaExchangeSelfTest.java     |   2 +-
 .../query/h2/sql/GridQueryParsingTest.java      |  21 ++-
 12 files changed, 283 insertions(+), 46 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/8ee6cb5c/modules/core/src/main/java/org/apache/ignite/IgniteSystemProperties.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/IgniteSystemProperties.java b/modules/core/src/main/java/org/apache/ignite/IgniteSystemProperties.java
index 4294c71..e0ace11 100644
--- a/modules/core/src/main/java/org/apache/ignite/IgniteSystemProperties.java
+++ b/modules/core/src/main/java/org/apache/ignite/IgniteSystemProperties.java
@@ -452,6 +452,9 @@ public final class IgniteSystemProperties {
      */
     public static final String IGNITE_SQL_MERGE_TABLE_PREFETCH_SIZE = "IGNITE_SQL_MERGE_TABLE_PREFETCH_SIZE";
 
+    /** Disable fallback to H2 SQL parser if the internal SQL parser fails to parse the statement.
*/
+    public static final String IGNITE_SQL_PARSER_DISABLE_H2_FALLBACK = "IGNITE_SQL_PARSER_DISABLE_H2_FALLBACK";
+
     /** Maximum size for affinity assignment history. */
     public static final String IGNITE_AFFINITY_HISTORY_SIZE = "IGNITE_AFFINITY_HISTORY_SIZE";
 

http://git-wip-us.apache.org/repos/asf/ignite/blob/8ee6cb5c/modules/core/src/main/java/org/apache/ignite/internal/sql/SqlKeyword.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/sql/SqlKeyword.java b/modules/core/src/main/java/org/apache/ignite/internal/sql/SqlKeyword.java
index ac826cc..08fa94b 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/sql/SqlKeyword.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/sql/SqlKeyword.java
@@ -99,6 +99,9 @@ public class SqlKeyword {
     /** Keyword: INDEX. */
     public static final String INDEX = "INDEX";
 
+    /** Keyword: INLINE_SIZE. */
+    public static final String INLINE_SIZE = "INLINE_SIZE";
+
     /** Keyword: INT. */
     public static final String INT = "INT";
 

http://git-wip-us.apache.org/repos/asf/ignite/blob/8ee6cb5c/modules/core/src/main/java/org/apache/ignite/internal/sql/SqlParserUtils.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/sql/SqlParserUtils.java
b/modules/core/src/main/java/org/apache/ignite/internal/sql/SqlParserUtils.java
index 2f3b3da..d812b3d 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/sql/SqlParserUtils.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/sql/SqlParserUtils.java
@@ -91,22 +91,35 @@ public class SqlParserUtils {
     }
 
     /**
-     * Parse integer value.
+     * Parse integer value (positive or negative).
      *
      * @param lex Lexer.
      * @return Integer value.
      */
     public static int parseInt(SqlLexer lex) {
+        int sign = 1;
+
+        if (lex.lookAhead().tokenType() == SqlLexerTokenType.MINUS) {
+            sign = -1;
+
+            lex.shift();
+        }
+
         if (lex.shift() && lex.tokenType() == SqlLexerTokenType.DEFAULT) {
             try {
-                return Integer.parseInt(lex.token());
+                long val = sign * Long.parseLong(lex.token());
+
+                if (val >= Integer.MIN_VALUE && val <= Integer.MAX_VALUE)
+                    return (int)val;
+
+                // Fall through.
             }
             catch (NumberFormatException e) {
-                // No-op.
+                // Fall through.
             }
         }
 
-        throw errorUnexpectedToken(lex, "[number]");
+        throw errorUnexpectedToken(lex, "[integer]");
     }
 
     /**
@@ -136,9 +149,9 @@ public class SqlParserUtils {
 
             String first = lex.token();
 
-            SqlLexerToken nextToken = lex.lookAhead();
+            SqlLexerToken nextTok = lex.lookAhead();
 
-            if (nextToken.tokenType() == SqlLexerTokenType.DOT) {
+            if (nextTok.tokenType() == SqlLexerTokenType.DOT) {
                 lex.shift();
 
                 String second = parseIdentifier(lex);

http://git-wip-us.apache.org/repos/asf/ignite/blob/8ee6cb5c/modules/core/src/main/java/org/apache/ignite/internal/sql/command/SqlCreateIndexCommand.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/sql/command/SqlCreateIndexCommand.java
b/modules/core/src/main/java/org/apache/ignite/internal/sql/command/SqlCreateIndexCommand.java
index ef89a5a..05eeb44 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/sql/command/SqlCreateIndexCommand.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/sql/command/SqlCreateIndexCommand.java
@@ -17,9 +17,11 @@
 
 package org.apache.ignite.internal.sql.command;
 
+import org.apache.ignite.cache.QueryIndex;
 import org.apache.ignite.internal.sql.SqlLexer;
 import org.apache.ignite.internal.sql.SqlLexerTokenType;
 import org.apache.ignite.internal.sql.SqlLexerToken;
+import org.apache.ignite.internal.sql.SqlParserUtils;
 import org.apache.ignite.internal.util.tostring.GridToStringExclude;
 import org.apache.ignite.internal.util.tostring.GridToStringInclude;
 import org.apache.ignite.internal.util.typedef.internal.S;
@@ -34,6 +36,7 @@ import java.util.Set;
 import static org.apache.ignite.internal.sql.SqlKeyword.ASC;
 import static org.apache.ignite.internal.sql.SqlKeyword.DESC;
 import static org.apache.ignite.internal.sql.SqlKeyword.IF;
+import static org.apache.ignite.internal.sql.SqlKeyword.INLINE_SIZE;
 import static org.apache.ignite.internal.sql.SqlKeyword.ON;
 import static org.apache.ignite.internal.sql.SqlParserUtils.error;
 import static org.apache.ignite.internal.sql.SqlParserUtils.errorUnexpectedToken;
@@ -71,6 +74,9 @@ public class SqlCreateIndexCommand implements SqlCommand {
     @GridToStringExclude
     private Set<String> colNames;
 
+    /** Inline size. Zero effectively disables inlining. */
+    private int inlineSize = QueryIndex.DFLT_INLINE_SIZE;
+
     /** {@inheritDoc} */
     @Override public String schemaName() {
         return schemaName;
@@ -110,6 +116,13 @@ public class SqlCreateIndexCommand implements SqlCommand {
     }
 
     /**
+     * @return Inline size.
+     */
+    public int inlineSize() {
+        return inlineSize;
+    }
+
+    /**
      * @param spatial Spatial index flag.
      * @return This instance.
      */
@@ -141,6 +154,8 @@ public class SqlCreateIndexCommand implements SqlCommand {
 
         parseColumnList(lex);
 
+        parseInlineSize(lex);
+
         return this;
     }
 
@@ -157,7 +172,27 @@ public class SqlCreateIndexCommand implements SqlCommand {
         return parseIdentifier(lex, IF);
     }
 
-    /*
+    /**
+     * Parses inline size option if exists.
+     *
+     * @param lex Lexer.
+     */
+    private void parseInlineSize(SqlLexer lex) {
+        SqlLexerToken nextTok = lex.lookAhead();
+
+        if (matchesKeyword(nextTok, INLINE_SIZE)) {
+            lex.shift();
+
+            int stmtInlineSize = SqlParserUtils.parseInt(lex);
+
+            if (stmtInlineSize < 0)
+                throw error(lex, "Inline size should be positive: " + stmtInlineSize);
+
+            inlineSize = stmtInlineSize;
+        }
+    }
+
+    /**
      * @param lex Lexer.
      */
     private void parseColumnList(SqlLexer lex) {
@@ -165,7 +200,7 @@ public class SqlCreateIndexCommand implements SqlCommand {
             throw errorUnexpectedToken(lex, "(");
 
         while (true) {
-            perseIndexColumn(lex);
+            parseIndexColumn(lex);
 
             if (skipCommaOrRightParenthesis(lex))
                 break;
@@ -175,7 +210,7 @@ public class SqlCreateIndexCommand implements SqlCommand {
     /**
      * @param lex Lexer.
      */
-    private void perseIndexColumn(SqlLexer lex) {
+    private void parseIndexColumn(SqlLexer lex) {
         String name = parseIdentifier(lex);
         boolean desc = false;
 

http://git-wip-us.apache.org/repos/asf/ignite/blob/8ee6cb5c/modules/core/src/test/java/org/apache/ignite/internal/sql/SqlParserCreateIndexSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/sql/SqlParserCreateIndexSelfTest.java
b/modules/core/src/test/java/org/apache/ignite/internal/sql/SqlParserCreateIndexSelfTest.java
index e7bc3e9..8cfeb2c 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/sql/SqlParserCreateIndexSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/sql/SqlParserCreateIndexSelfTest.java
@@ -123,6 +123,29 @@ public class SqlParserCreateIndexSelfTest extends SqlParserAbstractSelfTest
{
 
         // PRIMARY KEY
         assertParseError(null, "CREATE PRIMARY KEY INDEX idx ON tbl(a)", "Unsupported keyword:
\"PRIMARY\"");
+
+        // INLINE_SIZE option
+        assertParseError(null, "CREATE INDEX ON tbl(a) INLINE_SIZE",
+            "Unexpected end of command (expected: \"[integer]\")");
+
+        assertParseError(null, "CREATE INDEX ON tbl(a) INLINE_SIZE HASH",
+            "Unexpected token: \"HASH\" (expected: \"[integer]\")");
+
+        assertParseError(null, "CREATE INDEX ON tbl(a) INLINE_SIZE elegua",
+            "Unexpected token: \"ELEGUA\" (expected: \"[integer]\")");
+
+        assertParseError(null, "CREATE INDEX ON tbl(a) INLINE_SIZE -9223372036854775808",
+            "Unexpected token: \"9223372036854775808\" (expected: \"[integer]\")");
+
+        assertParseError(null, "CREATE INDEX ON tbl(a) INLINE_SIZE " + Integer.MIN_VALUE,
+            "Inline size should be positive: " + Integer.MIN_VALUE);
+
+        assertParseError(null, "CREATE INDEX ON tbl(a) INLINE_SIZE -1", "Inline size should
be positive: -1");
+
+        parseValidate(null, "CREATE INDEX idx ON schema.tbl(a) INLINE_SIZE 0", "SCHEMA",
"TBL", "IDX", "A", false);
+        parseValidate(null, "CREATE INDEX idx ON schema.tbl(a) INLINE_SIZE 1", "SCHEMA",
"TBL", "IDX", "A", false);
+        parseValidate(null, "CREATE INDEX idx ON schema.tbl(a) INLINE_SIZE " + Integer.MAX_VALUE,
+            "SCHEMA", "TBL", "IDX", "A", false);
     }
 
     /**

http://git-wip-us.apache.org/repos/asf/ignite/blob/8ee6cb5c/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java
----------------------------------------------------------------------
diff --git a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java
b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java
index 333a958..c37e5f0 100644
--- a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java
+++ b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java
@@ -49,6 +49,7 @@ import org.apache.ignite.IgniteCheckedException;
 import org.apache.ignite.IgniteDataStreamer;
 import org.apache.ignite.IgniteException;
 import org.apache.ignite.IgniteLogger;
+import org.apache.ignite.IgniteSystemProperties;
 import org.apache.ignite.cache.query.FieldsQueryCursor;
 import org.apache.ignite.cache.query.QueryCancelledException;
 import org.apache.ignite.cache.query.QueryCursor;
@@ -116,6 +117,7 @@ import org.apache.ignite.internal.processors.query.h2.twostep.MapQueryLazyWorker
 import org.apache.ignite.internal.processors.query.schema.SchemaIndexCacheVisitor;
 import org.apache.ignite.internal.processors.query.schema.SchemaIndexCacheVisitorClosure;
 import org.apache.ignite.internal.processors.timeout.GridTimeoutProcessor;
+import org.apache.ignite.internal.sql.SqlParseException;
 import org.apache.ignite.internal.sql.SqlParser;
 import org.apache.ignite.internal.sql.command.SqlCommand;
 import org.apache.ignite.internal.sql.command.SqlCreateIndexCommand;
@@ -1359,7 +1361,15 @@ public class IgniteH2Indexing implements GridQueryIndexing {
             if (log.isDebugEnabled())
                 log.debug("Failed to parse SQL with native parser [qry=" + qry.getSql() +
", err=" + e + ']');
 
-            return null;
+            if (!IgniteSystemProperties.getBoolean(IgniteSystemProperties.IGNITE_SQL_PARSER_DISABLE_H2_FALLBACK))
+                return null;
+
+            int code = IgniteQueryErrorCode.PARSING;
+
+            if (e instanceof SqlParseException)
+                code = ((SqlParseException)e).code();
+
+            throw new IgniteSQLException("Failed to parse DDL statement: " + qry.getSql(),
code, e);
         }
 
         // Execute.

http://git-wip-us.apache.org/repos/asf/ignite/blob/8ee6cb5c/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/ddl/DdlStatementsProcessor.java
----------------------------------------------------------------------
diff --git a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/ddl/DdlStatementsProcessor.java
b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/ddl/DdlStatementsProcessor.java
index 3c8d9fe..ea721f7 100644
--- a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/ddl/DdlStatementsProcessor.java
+++ b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/ddl/DdlStatementsProcessor.java
@@ -135,6 +135,7 @@ public class DdlStatementsProcessor {
                 }
 
                 newIdx.setFields(flds);
+                newIdx.setInlineSize(cmd0.inlineSize());
 
                 fut = ctx.query().dynamicIndexCreate(tbl.cacheName(), cmd0.schemaName(),
typeDesc.tableName(),
                     newIdx, cmd0.ifNotExists());

http://git-wip-us.apache.org/repos/asf/ignite/blob/8ee6cb5c/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/AbstractSchemaSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/AbstractSchemaSelfTest.java
b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/AbstractSchemaSelfTest.java
index eb3b8e1..0074020 100644
--- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/AbstractSchemaSelfTest.java
+++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/AbstractSchemaSelfTest.java
@@ -152,11 +152,12 @@ public class AbstractSchemaSelfTest extends GridCommonAbstractTest {
      * @param cacheName Cache name.
      * @param tblName Table name.
      * @param idxName Index name.
+     * @param inlineSize Inline size.
      * @param fields Fields.
      */
     protected static void assertIndex(String cacheName, String tblName, String idxName,
-        IgniteBiTuple<String, Boolean>... fields) {
-        assertIndex(cacheName, false, tblName, idxName, fields);
+        int inlineSize, IgniteBiTuple<String, Boolean>... fields) {
+        assertIndex(cacheName, false, tblName, idxName, inlineSize, fields);
     }
 
     /**
@@ -167,12 +168,13 @@ public class AbstractSchemaSelfTest extends GridCommonAbstractTest {
      *     affinity nodes as well.
      * @param tblName Table name.
      * @param idxName Index name.
+     * @param inlineSize Inline size.
      * @param fields Fields.
      */
     protected static void assertIndex(String cacheName, boolean checkNonAffinityNodes, String
tblName, String idxName,
-        IgniteBiTuple<String, Boolean>... fields) {
+        int inlineSize, IgniteBiTuple<String, Boolean>... fields) {
         for (Ignite node : Ignition.allGrids())
-            assertIndex(node, checkNonAffinityNodes, cacheName, tblName, idxName, fields);
+            assertIndex(node, checkNonAffinityNodes, cacheName, tblName, idxName, inlineSize,
fields);
     }
 
     /**
@@ -184,10 +186,11 @@ public class AbstractSchemaSelfTest extends GridCommonAbstractTest {
      * @param cacheName Cache name.
      * @param tblName Table name.
      * @param idxName Index name.
+     * @param inlineSize Inline size.
      * @param fields Fields.
      */
     protected static void assertIndex(Ignite node, boolean checkNonAffinityNode, String cacheName,
String tblName,
-        String idxName, IgniteBiTuple<String, Boolean>... fields) {
+        String idxName, int inlineSize, IgniteBiTuple<String, Boolean>... fields) {
         IgniteEx node0 = (IgniteEx)node;
 
         assertIndexDescriptor(node0, cacheName, tblName, idxName, fields);
@@ -195,7 +198,7 @@ public class AbstractSchemaSelfTest extends GridCommonAbstractTest {
         if (checkNonAffinityNode || affinityNode(node0, cacheName)) {
             QueryTypeDescriptorImpl typeDesc = typeExisting(node0, cacheName, tblName);
 
-            assertIndex(typeDesc, idxName, fields);
+            assertIndex(typeDesc, idxName, inlineSize, fields);
         }
     }
 
@@ -248,10 +251,11 @@ public class AbstractSchemaSelfTest extends GridCommonAbstractTest {
      *
      * @param typeDesc Type descriptor.
      * @param idxName Index name.
+     * @param inlineSize Inline size.
      * @param fields Fields (order is important).
      */
     protected static void assertIndex(QueryTypeDescriptorImpl typeDesc, String idxName,
-        IgniteBiTuple<String, Boolean>... fields) {
+        int inlineSize, IgniteBiTuple<String, Boolean>... fields) {
         QueryIndexDescriptorImpl idxDesc = typeDesc.index(idxName);
 
         assertNotNull(idxDesc);
@@ -259,6 +263,7 @@ public class AbstractSchemaSelfTest extends GridCommonAbstractTest {
         assertEquals(idxName, idxDesc.name());
         assertEquals(typeDesc, idxDesc.typeDescriptor());
         assertEquals(QueryIndexType.SORTED, idxDesc.type());
+        assertEquals(inlineSize, idxDesc.inlineSize());
 
         List<String> fieldNames = new ArrayList<>(idxDesc.fields());
 
@@ -489,6 +494,9 @@ public class AbstractSchemaSelfTest extends GridCommonAbstractTest {
 
         sql.a(')');
 
+        if (idx.getInlineSize() != QueryIndex.DFLT_INLINE_SIZE)
+            sql.a(" INLINE_SIZE ").a(idx.getInlineSize());
+
         executeSql(node, cacheName, sql.toString());
     }
 

http://git-wip-us.apache.org/repos/asf/ignite/blob/8ee6cb5c/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/DynamicIndexAbstractBasicSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/DynamicIndexAbstractBasicSelfTest.java
b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/DynamicIndexAbstractBasicSelfTest.java
index 56f28d4..f7d99b4 100644
--- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/DynamicIndexAbstractBasicSelfTest.java
+++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/DynamicIndexAbstractBasicSelfTest.java
@@ -24,6 +24,7 @@ import java.util.concurrent.Callable;
 import javax.cache.CacheException;
 import org.apache.ignite.Ignite;
 import org.apache.ignite.IgniteCheckedException;
+import org.apache.ignite.IgniteSystemProperties;
 import org.apache.ignite.Ignition;
 import org.apache.ignite.cache.CacheAtomicityMode;
 import org.apache.ignite.cache.CacheMode;
@@ -197,7 +198,7 @@ public abstract class DynamicIndexAbstractBasicSelfTest extends DynamicIndexAbst
         final QueryIndex idx = index(IDX_NAME_1, field(FIELD_NAME_1_ESCAPED));
 
         dynamicIndexCreate(CACHE_NAME, TBL_NAME, idx, false);
-        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, field(FIELD_NAME_1_ESCAPED));
+        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, QueryIndex.DFLT_INLINE_SIZE, field(FIELD_NAME_1_ESCAPED));
 
         assertSchemaException(new RunnableX() {
             @Override public void run() throws Exception {
@@ -206,7 +207,7 @@ public abstract class DynamicIndexAbstractBasicSelfTest extends DynamicIndexAbst
         }, IgniteQueryErrorCode.INDEX_ALREADY_EXISTS);
 
         dynamicIndexCreate(CACHE_NAME, TBL_NAME, idx, true);
-        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, field(FIELD_NAME_1_ESCAPED));
+        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, QueryIndex.DFLT_INLINE_SIZE, field(FIELD_NAME_1_ESCAPED));
 
         assertSimpleIndexOperations(SQL_SIMPLE_FIELD_1);
 
@@ -281,7 +282,8 @@ public abstract class DynamicIndexAbstractBasicSelfTest extends DynamicIndexAbst
         final QueryIndex idx = index(IDX_NAME_1, field(FIELD_NAME_1_ESCAPED), field(alias(FIELD_NAME_2_ESCAPED)));
 
         dynamicIndexCreate(CACHE_NAME, TBL_NAME, idx, false);
-        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, field(FIELD_NAME_1_ESCAPED), field(alias(FIELD_NAME_2_ESCAPED)));
+        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, QueryIndex.DFLT_INLINE_SIZE,
+            field(FIELD_NAME_1_ESCAPED), field(alias(FIELD_NAME_2_ESCAPED)));
 
         assertCompositeIndexOperations(SQL_COMPOSITE);
 
@@ -605,7 +607,7 @@ public abstract class DynamicIndexAbstractBasicSelfTest extends DynamicIndexAbst
         QueryIndex idx = index(IDX_NAME_1, field(alias(FIELD_NAME_2_ESCAPED)));
 
         dynamicIndexCreate(CACHE_NAME, TBL_NAME, idx, false);
-        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, field(alias(FIELD_NAME_2_ESCAPED)));
+        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, QueryIndex.DFLT_INLINE_SIZE, field(alias(FIELD_NAME_2_ESCAPED)));
 
         assertSimpleIndexOperations(SQL_SIMPLE_FIELD_2);
 
@@ -613,6 +615,135 @@ public abstract class DynamicIndexAbstractBasicSelfTest extends DynamicIndexAbst
     }
 
     /**
+     * Tests creating index with inline size for PARTITIONED ATOMIC cache.
+     *
+     * @throws Exception If failed.
+     */
+    public void testCreateIndexWithInlineSizePartitionedAtomic() throws Exception {
+        checkCreateIndexWithInlineSize(PARTITIONED, ATOMIC, false);
+    }
+
+    /**
+     * Tests creating index with inline size for PARTITIONED ATOMIC cache with near cache.
+     *
+     * @throws Exception If failed.
+     */
+    public void testCreateIndexWithInlineSizePartitionedAtomicNear() throws Exception {
+        checkCreateIndexWithInlineSize(PARTITIONED, ATOMIC, true);
+    }
+
+    /**
+     * Tests creating index with inline size for PARTITIONED TRANSACTIONAL cache.
+     *
+     * @throws Exception If failed.
+     */
+    public void testCreateIndexWithInlineSizePartitionedTransactional() throws Exception
{
+        checkCreateIndexWithInlineSize(PARTITIONED, TRANSACTIONAL, false);
+    }
+
+    /**
+     * Tests creating index with inline size for PARTITIONED TRANSACTIONAL cache with near
cache.
+     *
+     * @throws Exception If failed.
+     */
+    public void testCreateIndexWithInlineSizePartitionedTransactionalNear() throws Exception
{
+        checkCreateIndexWithInlineSize(PARTITIONED, TRANSACTIONAL, true);
+    }
+
+    /**
+     * Tests creating index with inline size for REPLICATED ATOMIC cache.
+     *
+     * @throws Exception If failed.
+     */
+    public void testCreateIndexWithInlineSizeReplicatedAtomic() throws Exception {
+        checkCreateIndexWithInlineSize(REPLICATED, ATOMIC, false);
+    }
+
+    /**
+     * Tests creating index with inline size option for REPLICATED TRANSACTIONAL cache.
+     *
+     * @throws Exception If failed.
+     */
+    public void testCreateIndexWithInlineSizeReplicatedTransactional() throws Exception {
+        checkCreateIndexWithInlineSize(REPLICATED, TRANSACTIONAL, false);
+    }
+
+    /**
+     * Checks that inline size parameter is correctly handled during index creation.
+     *
+     * @param mode Mode.
+     * @param atomicityMode Atomicity mode.
+     * @param near Near flag.
+     * @throws Exception If failed.
+     */
+    private void checkCreateIndexWithInlineSize(CacheMode mode, CacheAtomicityMode atomicityMode,
boolean near)
+        throws Exception {
+
+        initialize(mode, atomicityMode, near);
+
+        String prevFallbackPropVal = System.getProperty(IgniteSystemProperties.IGNITE_SQL_PARSER_DISABLE_H2_FALLBACK);
+
+        try {
+            System.setProperty(IgniteSystemProperties.IGNITE_SQL_PARSER_DISABLE_H2_FALLBACK,
"true");
+
+            checkNoIndexIsCreatedForInlineSize(-2, IgniteQueryErrorCode.PARSING);
+            checkNoIndexIsCreatedForInlineSize(Integer.MIN_VALUE, IgniteQueryErrorCode.PARSING);
+
+            checkIndexCreatedForInlineSize(0);
+            loadInitialData();
+            checkIndexCreatedForInlineSize(1);
+            loadInitialData();
+            checkIndexCreatedForInlineSize(Integer.MAX_VALUE);
+        }
+        finally {
+            if (prevFallbackPropVal != null)
+                System.setProperty(IgniteSystemProperties.IGNITE_SQL_PARSER_DISABLE_H2_FALLBACK,
prevFallbackPropVal);
+            else
+                System.clearProperty(IgniteSystemProperties.IGNITE_SQL_PARSER_DISABLE_H2_FALLBACK);
+        }
+    }
+
+    /**
+     * Verifies that index is created with the specified inline size.
+     *
+     * @param inlineSize Inline size to put into CREATE INDEX
+     * @throws Exception If failed.
+     */
+    private void checkIndexCreatedForInlineSize(int inlineSize) throws Exception {
+        QueryIndex idx = index(IDX_NAME_1, field(FIELD_NAME_1_ESCAPED));
+        idx.setInlineSize(inlineSize);
+
+        dynamicIndexCreate(CACHE_NAME, TBL_NAME, idx, false);
+
+        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, inlineSize, field(FIELD_NAME_1_ESCAPED));
+        assertSimpleIndexOperations(SQL_SIMPLE_FIELD_1);
+        assertIndexUsed(IDX_NAME_1, SQL_SIMPLE_FIELD_1, SQL_ARG_1);
+
+        dynamicIndexDrop(CACHE_NAME, IDX_NAME_1, false);
+
+        assertNoIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1);
+    }
+
+    /**
+     * Verifies that no index is created and an exception is thrown.
+     *
+     * @param inlineSize Inline size value in the CREATE INDEX statement.
+     * @param igniteQryErrorCode Expected error code in the thrown exception.
+     * @throws Exception If failed for any other reason than the expected exception.
+     */
+    private void checkNoIndexIsCreatedForInlineSize(final int inlineSize, int igniteQryErrorCode)
throws Exception {
+        assertSchemaException(new RunnableX() {
+            @Override public void run() throws Exception {
+                QueryIndex idx = index(IDX_NAME_1, field(FIELD_NAME_1_ESCAPED));
+                idx.setInlineSize(inlineSize);
+                dynamicIndexCreate(CACHE_NAME, TBL_NAME, idx, false);
+            }
+        }, igniteQryErrorCode);
+
+        assertNoIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1);
+    }
+
+    /**
      * Test simple index drop for PARTITIONED ATOMIC cache.
      *
      * @throws Exception If failed.
@@ -681,7 +812,7 @@ public abstract class DynamicIndexAbstractBasicSelfTest extends DynamicIndexAbst
         QueryIndex idx1 = index(IDX_NAME_1, field(FIELD_NAME_1_ESCAPED));
 
         dynamicIndexCreate(CACHE_NAME, TBL_NAME, idx1, false);
-        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, field(FIELD_NAME_1_ESCAPED));
+        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, QueryIndex.DFLT_INLINE_SIZE, field(FIELD_NAME_1_ESCAPED));
 
         assertIndexUsed(IDX_NAME_1, SQL_SIMPLE_FIELD_1, SQL_ARG_1);
 
@@ -691,7 +822,7 @@ public abstract class DynamicIndexAbstractBasicSelfTest extends DynamicIndexAbst
         QueryIndex idx2 = index(IDX_NAME_2, field(alias(FIELD_NAME_2_ESCAPED)));
 
         dynamicIndexCreate(CACHE_NAME, TBL_NAME, idx2, false);
-        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_2, field(alias(FIELD_NAME_2_ESCAPED)));
+        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_2, QueryIndex.DFLT_INLINE_SIZE, field(alias(FIELD_NAME_2_ESCAPED)));
 
         // Load some data.
         loadInitialData();
@@ -705,7 +836,7 @@ public abstract class DynamicIndexAbstractBasicSelfTest extends DynamicIndexAbst
         assertIndexNotUsed(IDX_NAME_1, SQL_SIMPLE_FIELD_1, SQL_ARG_1);
 
         // Make sure the second index is still there.
-        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_2, field(alias(FIELD_NAME_2_ESCAPED)));
+        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_2, QueryIndex.DFLT_INLINE_SIZE, field(alias(FIELD_NAME_2_ESCAPED)));
     }
 
     /**
@@ -906,7 +1037,7 @@ public abstract class DynamicIndexAbstractBasicSelfTest extends DynamicIndexAbst
         final QueryIndex idx = index(IDX_NAME_2, field(FIELD_NAME_1));
 
         dynamicIndexCreate(STATIC_CACHE_NAME, TBL_NAME, idx, true);
-        assertIndex(STATIC_CACHE_NAME, TBL_NAME, IDX_NAME_1, field(FIELD_NAME_1_ESCAPED));
+        assertIndex(STATIC_CACHE_NAME, TBL_NAME, IDX_NAME_1, QueryIndex.DFLT_INLINE_SIZE,
field(FIELD_NAME_1_ESCAPED));
 
         dynamicIndexDrop(STATIC_CACHE_NAME, IDX_NAME_1, true);
         assertNoIndex(STATIC_CACHE_NAME, TBL_NAME, IDX_NAME_1);

http://git-wip-us.apache.org/repos/asf/ignite/blob/8ee6cb5c/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/DynamicIndexAbstractConcurrentSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/DynamicIndexAbstractConcurrentSelfTest.java
b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/DynamicIndexAbstractConcurrentSelfTest.java
index 3190b5e..610688a 100644
--- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/DynamicIndexAbstractConcurrentSelfTest.java
+++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/DynamicIndexAbstractConcurrentSelfTest.java
@@ -170,7 +170,7 @@ public abstract class DynamicIndexAbstractConcurrentSelfTest extends DynamicInde
 
         idxFut1.get();
 
-        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, field(FIELD_NAME_1));
+        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, QueryIndex.DFLT_INLINE_SIZE, field(FIELD_NAME_1));
         assertIndexUsed(IDX_NAME_1, SQL_SIMPLE_FIELD_1, SQL_ARG_1);
         assertSqlSimpleData(SQL_SIMPLE_FIELD_1, KEY_AFTER - SQL_ARG_1);
 
@@ -191,7 +191,7 @@ public abstract class DynamicIndexAbstractConcurrentSelfTest extends DynamicInde
 
         idxFut2.get();
 
-        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_2, field(aliasUnescaped(FIELD_NAME_2)));
+        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_2, QueryIndex.DFLT_INLINE_SIZE, field(aliasUnescaped(FIELD_NAME_2)));
         assertIndexUsed(IDX_NAME_2, SQL_SIMPLE_FIELD_2, SQL_ARG_1);
         assertSqlSimpleData(SQL_SIMPLE_FIELD_2, KEY_AFTER - SQL_ARG_1);
     }
@@ -234,8 +234,8 @@ public abstract class DynamicIndexAbstractConcurrentSelfTest extends DynamicInde
         idxFut1.get();
         idxFut2.get();
 
-        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, field(FIELD_NAME_1));
-        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_2, field(aliasUnescaped(FIELD_NAME_2)));
+        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, QueryIndex.DFLT_INLINE_SIZE, field(FIELD_NAME_1));
+        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_2, QueryIndex.DFLT_INLINE_SIZE, field(aliasUnescaped(FIELD_NAME_2)));
 
         idxLatch.countDown();
 
@@ -277,7 +277,7 @@ public abstract class DynamicIndexAbstractConcurrentSelfTest extends DynamicInde
 
         idxLatch.countDown();
 
-        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, field(FIELD_NAME_1));
+        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, QueryIndex.DFLT_INLINE_SIZE, field(FIELD_NAME_1));
 
         put(srv1, 0, KEY_AFTER);
 
@@ -341,7 +341,7 @@ public abstract class DynamicIndexAbstractConcurrentSelfTest extends DynamicInde
         updateFut.get();
 
         // Make sure index is there.
-        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, field(FIELD_NAME_1));
+        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, QueryIndex.DFLT_INLINE_SIZE, field(FIELD_NAME_1));
         assertIndexUsed(IDX_NAME_1, SQL_SIMPLE_FIELD_1, SQL_ARG_1);
 
         // Get expected values.
@@ -423,7 +423,7 @@ public abstract class DynamicIndexAbstractConcurrentSelfTest extends DynamicInde
         // Validate index state.
         idxFut.get();
 
-        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, field(FIELD_NAME_1));
+        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, QueryIndex.DFLT_INLINE_SIZE, field(FIELD_NAME_1));
 
         assertIndexUsed(IDX_NAME_1, SQL_SIMPLE_FIELD_1, SQL_ARG_1);
         assertSqlSimpleData(SQL_SIMPLE_FIELD_1, LARGE_CACHE_SIZE - SQL_ARG_1);
@@ -539,7 +539,7 @@ public abstract class DynamicIndexAbstractConcurrentSelfTest extends DynamicInde
         queryProcessor(cli).dynamicIndexDrop(CACHE_NAME, CACHE_NAME, IDX_NAME_1, true).get();
         queryProcessor(cli).dynamicIndexCreate(CACHE_NAME, CACHE_NAME, TBL_NAME, idx, true).get();
 
-        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, field(FIELD_NAME_1));
+        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, QueryIndex.DFLT_INLINE_SIZE, field(FIELD_NAME_1));
 
         put(cli, 0, KEY_AFTER);
 
@@ -670,7 +670,8 @@ public abstract class DynamicIndexAbstractConcurrentSelfTest extends DynamicInde
             }
         });
 
-        assertIndex(cli, true, CACHE_NAME, TBL_NAME, IDX_NAME_1, field(FIELD_NAME_1));
+        assertIndex(cli, true, CACHE_NAME, TBL_NAME, IDX_NAME_1,
+            QueryIndex.DFLT_INLINE_SIZE, field(FIELD_NAME_1));
         assertIndexUsed(IDX_NAME_1, SQL_SIMPLE_FIELD_1, SQL_ARG_1);
 
         // Check index drop.
@@ -689,7 +690,8 @@ public abstract class DynamicIndexAbstractConcurrentSelfTest extends DynamicInde
 
         queryProcessor(srv).dynamicIndexCreate(CACHE_NAME, CACHE_NAME, TBL_NAME, idx, false).get();
 
-        assertIndex(cli, true, CACHE_NAME, TBL_NAME, IDX_NAME_2, field(aliasUnescaped(FIELD_NAME_2)));
+        assertIndex(cli, true, CACHE_NAME, TBL_NAME, IDX_NAME_2, QueryIndex.DFLT_INLINE_SIZE,
+            field(aliasUnescaped(FIELD_NAME_2)));
         assertIndexUsed(IDX_NAME_2, SQL_SIMPLE_FIELD_2, SQL_ARG_2);
 
         reconnectClientNode(srv, cli, restartCache, new RunnableX() {
@@ -703,7 +705,8 @@ public abstract class DynamicIndexAbstractConcurrentSelfTest extends DynamicInde
             }
         });
 
-        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_2, field(FIELD_NAME_1), field(aliasUnescaped(FIELD_NAME_2)));
+        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_2, QueryIndex.DFLT_INLINE_SIZE, field(FIELD_NAME_1),
+            field(aliasUnescaped(FIELD_NAME_2)));
         assertIndexUsed(IDX_NAME_2, SQL_COMPOSITE, SQL_ARG_1, SQL_ARG_2);
     }
 
@@ -861,7 +864,7 @@ public abstract class DynamicIndexAbstractConcurrentSelfTest extends DynamicInde
         queryProcessor(cli).dynamicIndexDrop(CACHE_NAME, CACHE_NAME, IDX_NAME_1, true).get();
         queryProcessor(cli).dynamicIndexCreate(CACHE_NAME, CACHE_NAME, TBL_NAME, idx, true).get();
 
-        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, field(FIELD_NAME_1));
+        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, QueryIndex.DFLT_INLINE_SIZE, field(FIELD_NAME_1));
 
         put(cli, 0, KEY_AFTER);
 
@@ -962,7 +965,7 @@ public abstract class DynamicIndexAbstractConcurrentSelfTest extends DynamicInde
         queryProcessor(cli).dynamicIndexDrop(CACHE_NAME, CACHE_NAME, IDX_NAME_1, true).get();
         queryProcessor(cli).dynamicIndexCreate(CACHE_NAME, CACHE_NAME, TBL_NAME, idx, true).get();
 
-        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, field(FIELD_NAME_1));
+        assertIndex(CACHE_NAME, TBL_NAME, IDX_NAME_1, QueryIndex.DFLT_INLINE_SIZE, field(FIELD_NAME_1));
 
         put(cli, 0, KEY_AFTER);
 

http://git-wip-us.apache.org/repos/asf/ignite/blob/8ee6cb5c/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/SchemaExchangeSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/SchemaExchangeSelfTest.java
b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/SchemaExchangeSelfTest.java
index 0524c75..1d0e973 100644
--- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/SchemaExchangeSelfTest.java
+++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/SchemaExchangeSelfTest.java
@@ -480,7 +480,7 @@ public class SchemaExchangeSelfTest extends AbstractSchemaSelfTest {
 
         assertIndex(CACHE_NAME,
             QueryUtils.normalizeObjectName(TBL_NAME, true),
-            QueryUtils.normalizeObjectName(IDX_NAME_1, false),
+            QueryUtils.normalizeObjectName(IDX_NAME_1, false), QueryIndex.DFLT_INLINE_SIZE,
             field(QueryUtils.normalizeObjectName(FIELD_NAME_1_ESCAPED, false)));
     }
 

http://git-wip-us.apache.org/repos/asf/ignite/blob/8ee6cb5c/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/h2/sql/GridQueryParsingTest.java
----------------------------------------------------------------------
diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/h2/sql/GridQueryParsingTest.java
b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/h2/sql/GridQueryParsingTest.java
index a1fe04b..dc72c31 100644
--- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/h2/sql/GridQueryParsingTest.java
+++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/h2/sql/GridQueryParsingTest.java
@@ -508,28 +508,34 @@ public class GridQueryParsingTest extends GridCommonAbstractTest {
      */
     public void testParseCreateIndex() throws Exception {
         assertCreateIndexEquals(
-            buildCreateIndex(null, "Person", "sch1", false, QueryIndexType.SORTED, "name",
true),
+            buildCreateIndex(null, "Person", "sch1", false, QueryIndexType.SORTED,
+            QueryIndex.DFLT_INLINE_SIZE,"name", true),
             "create index on Person (name)");
 
         assertCreateIndexEquals(
-            buildCreateIndex("idx", "Person", "sch1", false, QueryIndexType.SORTED, "name",
true),
+            buildCreateIndex("idx", "Person", "sch1", false, QueryIndexType.SORTED,
+            QueryIndex.DFLT_INLINE_SIZE, "name", true),
             "create index idx on Person (name ASC)");
 
         assertCreateIndexEquals(
-            buildCreateIndex("idx", "Person", "sch1", false, QueryIndexType.GEOSPATIAL, "name",
true),
+            buildCreateIndex("idx", "Person", "sch1", false, QueryIndexType.GEOSPATIAL,
+            QueryIndex.DFLT_INLINE_SIZE, "name", true),
             "create spatial index sch1.idx on sch1.Person (name ASC)");
 
         assertCreateIndexEquals(
-            buildCreateIndex("idx", "Person", "sch1", true, QueryIndexType.SORTED, "name",
true),
+            buildCreateIndex("idx", "Person", "sch1", true, QueryIndexType.SORTED,
+            QueryIndex.DFLT_INLINE_SIZE, "name", true),
             "create index if not exists sch1.idx on sch1.Person (name)");
 
         // When we specify schema for the table and don't specify it for the index, resulting
schema is table's
         assertCreateIndexEquals(
-            buildCreateIndex("idx", "Person", "sch1", true, QueryIndexType.SORTED, "name",
false),
+            buildCreateIndex("idx", "Person", "sch1", true, QueryIndexType.SORTED,
+            QueryIndex.DFLT_INLINE_SIZE,"name", false),
             "create index if not exists idx on sch1.Person (name dEsC)");
 
         assertCreateIndexEquals(
-            buildCreateIndex("idx", "Person", "sch1", true, QueryIndexType.GEOSPATIAL, "old",
true, "name", false),
+            buildCreateIndex("idx", "Person", "sch1", true, QueryIndexType.GEOSPATIAL,
+            QueryIndex.DFLT_INLINE_SIZE, "old", true, "name", false),
             "create spatial index if not exists idx on Person (old, name desc)");
 
         // Schemas for index and table must match
@@ -955,7 +961,7 @@ public class GridQueryParsingTest extends GridCommonAbstractTest {
      *
      */
     private static GridSqlCreateIndex buildCreateIndex(String name, String tblName, String
schemaName,
-        boolean ifNotExists, QueryIndexType type, Object... flds) {
+        boolean ifNotExists, QueryIndexType type, int inlineSize, Object... flds) {
         QueryIndex idx = new QueryIndex();
 
         idx.setName(name);
@@ -969,6 +975,7 @@ public class GridQueryParsingTest extends GridCommonAbstractTest {
 
         idx.setFields(trueFlds);
         idx.setIndexType(type);
+        idx.setInlineSize(inlineSize);
 
         GridSqlCreateIndex res = new GridSqlCreateIndex();
 


Mime
View raw message