You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ignite.apache.org by GitBox <gi...@apache.org> on 2021/06/10 08:44:23 UTC

[GitHub] [ignite] vladErmakov07 opened a new pull request #9164: IGNITE-14120 select count * returns multiple rows

vladErmakov07 opened a new pull request #9164:
URL: https://github.com/apache/ignite/pull/9164


   Thank you for submitting the pull request to the Apache Ignite.
   
   In order to streamline the review of the contribution 
   we ask you to ensure the following steps have been taken:
   
   ### The Contribution Checklist
   - [ ] There is a single JIRA ticket related to the pull request. 
   - [ ] The web-link to the pull request is attached to the JIRA ticket.
   - [ ] The JIRA ticket has the _Patch Available_ state.
   - [ ] The pull request body describes changes that have been made. 
   The description explains _WHAT_ and _WHY_ was made instead of _HOW_.
   - [ ] The pull request title is treated as the final commit message. 
   The following pattern must be used: `IGNITE-XXXX Change summary` where `XXXX` - number of JIRA issue.
   - [ ] A reviewer has been mentioned through the JIRA comments 
   (see [the Maintainers list](https://cwiki.apache.org/confluence/display/IGNITE/How+to+Contribute#HowtoContribute-ReviewProcessandMaintainers)) 
   - [ ] The pull request has been checked by the Teamcity Bot and 
   the `green visa` attached to the JIRA ticket (see [TC.Bot: Check PR](https://mtcga.gridgain.com/prs.html))
   
   ### Notes
   - [How to Contribute](https://cwiki.apache.org/confluence/display/IGNITE/How+to+Contribute)
   - [Coding abbreviation rules](https://cwiki.apache.org/confluence/display/IGNITE/Abbreviation+Rules)
   - [Coding Guidelines](https://cwiki.apache.org/confluence/display/IGNITE/Coding+Guidelines)
   - [Apache Ignite Teamcity Bot](https://cwiki.apache.org/confluence/display/IGNITE/Apache+Ignite+Teamcity+Bot)
   
   If you need any help, please email dev@ignite.apache.org or ask anу advice on http://asf.slack.com _#ignite_ channel.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [ignite] vladErmakov07 commented on a change in pull request #9164: IGNITE-14120 fix multiple results bug when query parallelism is enabled.

Posted by GitBox <gi...@apache.org>.
vladErmakov07 commented on a change in pull request #9164:
URL: https://github.com/apache/ignite/pull/9164#discussion_r649325350



##########
File path: modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSinglePartitionMultiParallelismTest.java
##########
@@ -0,0 +1,162 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.ignite.internal.processors.query;
+
+import java.util.Collections;
+import java.util.List;
+import org.apache.ignite.IgniteCache;
+import org.apache.ignite.cache.query.SqlFieldsQuery;
+import org.apache.ignite.configuration.CacheConfiguration;
+import org.apache.ignite.internal.processors.cache.index.AbstractIndexingCommonTest;
+import org.apache.ignite.testframework.GridTestUtils;
+import org.junit.Rule;
+import org.junit.Test;
+import org.junit.rules.Timeout;
+
+import static org.apache.ignite.cache.CacheAtomicityMode.TRANSACTIONAL;
+import static org.apache.ignite.cache.CacheMode.PARTITIONED;
+import static org.apache.ignite.cache.PartitionLossPolicy.READ_WRITE_SAFE;
+
+/**
+ * IGNITE-14120 Test for correct results in case of query with single partition and cache with parallelism > 1
+ */
+public class IgniteSqlSinglePartitionMultiParallelismTest extends AbstractIndexingCommonTest {
+    /** */
+    private static final String CACHE_NAME = "SC_NULL_TEST";
+
+    /** Test timeout. */
+    @Rule
+    public Timeout globalTimeout = new Timeout((int)GridTestUtils.DFLT_TEST_TIMEOUT);
+
+    /** {@inheritDoc} */
+    @Override protected void beforeTestsStarted() throws Exception {
+        startGrids(1);
+    }
+
+    /** {@inheritDoc} */
+    @Override protected void afterTest() throws Exception {
+        super.afterTest();
+
+        grid(0).destroyCaches(Collections.singletonList(CACHE_NAME));

Review comment:
       Looked at this closely, it is not necessary. Moved it to beforeTestsStarted function




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [ignite] vladErmakov07 commented on a change in pull request #9164: IGNITE-14120 fix multiple results bug when query parallelism is enabled.

Posted by GitBox <gi...@apache.org>.
vladErmakov07 commented on a change in pull request #9164:
URL: https://github.com/apache/ignite/pull/9164#discussion_r649339698



##########
File path: modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSinglePartitionMultiParallelismTest.java
##########
@@ -0,0 +1,153 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.ignite.internal.processors.query;
+
+import java.util.Collections;
+import java.util.List;
+import org.apache.ignite.IgniteCache;
+import org.apache.ignite.cache.query.SqlFieldsQuery;
+import org.apache.ignite.configuration.CacheConfiguration;
+import org.apache.ignite.internal.processors.cache.index.AbstractIndexingCommonTest;
+import org.junit.Test;
+
+import static org.apache.ignite.cache.CacheAtomicityMode.TRANSACTIONAL;
+import static org.apache.ignite.cache.CacheMode.PARTITIONED;
+import static org.apache.ignite.cache.PartitionLossPolicy.READ_WRITE_SAFE;
+
+/**
+ * IGNITE-14120 Test for correct results in case of query with single partition and cache with parallelism > 1.
+ */
+public class IgniteSqlSinglePartitionMultiParallelismTest extends AbstractIndexingCommonTest {
+    /** */
+    private static final String CACHE_NAME = "SC_NULL_TEST";
+
+    /** {@inheritDoc} */
+    @Override protected void beforeTestsStarted() throws Exception {
+        startGrids(1);
+        ignite(0).createCache(cacheConfig());
+        createTable();
+    }
+
+    /** {@inheritDoc} */
+    @Override protected void afterTestsStopped() throws Exception {
+        grid(0).destroyCaches(Collections.singletonList(CACHE_NAME));
+    }
+
+    /**
+     * @return Cache configuration.
+     */
+    protected CacheConfiguration<Integer, Integer> cacheConfig() {
+        return new CacheConfiguration<Integer, Integer>()
+            .setName(CACHE_NAME)
+            .setCacheMode(PARTITIONED)
+            .setReadFromBackup(false)
+            .setStatisticsEnabled(true)
+            .setQueryParallelism(100)
+            .setSqlIndexMaxInlineSize(64)
+            .setBackups(0)
+            .setPartitionLossPolicy(READ_WRITE_SAFE)
+            .setAtomicityMode(TRANSACTIONAL);
+    }
+
+    /**
+     * Check common case without partitions. Should be single result.
+     */
+    @Test
+    public void assertSimpleCountQuery() throws Exception {
+        run(() -> {
+            List<List<?>> results = runQuery("select count(*) from SC_NULL_TEST");
+
+            Long res = (Long) results.get(0).get(0);
+
+            assertEquals(1, results.size());
+            assertEquals(Long.valueOf(999), res);
+        });
+    }
+
+    /**
+     * Check case with 1 partition. Partition segment must be calculated correctly.
+     */
+    @Test
+    public void assertWhereCountFirstPartitionQuery() throws Exception {
+        run(() -> {
+            List<List<?>> results = runQuery("select count(*) from SC_NULL_TEST where ID=1");
+
+            Long res = (Long) results.get(0).get(0);
+
+            assertEquals(1, results.size());
+            assertEquals(Long.valueOf(1), res);
+        });
+    }
+
+    /**
+     * Check case with 1 partition. Partition segment must be calculated correctly.
+     */
+    @Test
+    public void assertWhereCountAnotherPartitionQuery() throws Exception {
+        run(() -> {
+            List<List<?>> results = runQuery("select count(*) from SC_NULL_TEST where ID=973");
+
+            Long res = (Long) results.get(0).get(0);
+
+            assertEquals(1, results.size());
+            assertEquals(Long.valueOf(1), res);
+        });
+    }
+
+    /**
+     * Check case with 2 partition. Multiple partitions should not be affected.
+     */
+    @Test
+    public void assertWhereCountMultiPartitionsQuery() throws Exception {
+        run(() -> {
+            List<List<?>> results = runQuery("select count(*) from SC_NULL_TEST where ID=5 or ID=995");
+
+            Long res = (Long) results.get(0).get(0);
+
+            assertEquals(1, results.size());
+            assertEquals(Long.valueOf(2), res);
+        });
+    }
+
+    /** */
+    private void run(Runnable test) throws Exception {

Review comment:
       Forgot about it, removed.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [ignite] vladErmakov07 commented on a change in pull request #9164: IGNITE-14120 fix multiple results bug when query parallelism is enabled.

Posted by GitBox <gi...@apache.org>.
vladErmakov07 commented on a change in pull request #9164:
URL: https://github.com/apache/ignite/pull/9164#discussion_r649324547



##########
File path: modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSinglePartitionMultiParallelismTest.java
##########
@@ -0,0 +1,162 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.ignite.internal.processors.query;
+
+import java.util.Collections;
+import java.util.List;
+import org.apache.ignite.IgniteCache;
+import org.apache.ignite.cache.query.SqlFieldsQuery;
+import org.apache.ignite.configuration.CacheConfiguration;
+import org.apache.ignite.internal.processors.cache.index.AbstractIndexingCommonTest;
+import org.apache.ignite.testframework.GridTestUtils;
+import org.junit.Rule;
+import org.junit.Test;
+import org.junit.rules.Timeout;
+
+import static org.apache.ignite.cache.CacheAtomicityMode.TRANSACTIONAL;
+import static org.apache.ignite.cache.CacheMode.PARTITIONED;
+import static org.apache.ignite.cache.PartitionLossPolicy.READ_WRITE_SAFE;
+
+/**
+ * IGNITE-14120 Test for correct results in case of query with single partition and cache with parallelism > 1
+ */
+public class IgniteSqlSinglePartitionMultiParallelismTest extends AbstractIndexingCommonTest {
+    /** */
+    private static final String CACHE_NAME = "SC_NULL_TEST";
+
+    /** Test timeout. */
+    @Rule
+    public Timeout globalTimeout = new Timeout((int)GridTestUtils.DFLT_TEST_TIMEOUT);

Review comment:
       Thx, removed it.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [ignite] korlov42 commented on a change in pull request #9164: IGNITE-14120 fix multiple results bug when query parallelism is enabled.

Posted by GitBox <gi...@apache.org>.
korlov42 commented on a change in pull request #9164:
URL: https://github.com/apache/ignite/pull/9164#discussion_r649299854



##########
File path: modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSinglePartitionMultiParallelismTest.java
##########
@@ -0,0 +1,162 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.ignite.internal.processors.query;
+
+import java.util.Collections;
+import java.util.List;
+import org.apache.ignite.IgniteCache;
+import org.apache.ignite.cache.query.SqlFieldsQuery;
+import org.apache.ignite.configuration.CacheConfiguration;
+import org.apache.ignite.internal.processors.cache.index.AbstractIndexingCommonTest;
+import org.apache.ignite.testframework.GridTestUtils;
+import org.junit.Rule;
+import org.junit.Test;
+import org.junit.rules.Timeout;
+
+import static org.apache.ignite.cache.CacheAtomicityMode.TRANSACTIONAL;
+import static org.apache.ignite.cache.CacheMode.PARTITIONED;
+import static org.apache.ignite.cache.PartitionLossPolicy.READ_WRITE_SAFE;
+
+/**
+ * IGNITE-14120 Test for correct results in case of query with single partition and cache with parallelism > 1
+ */
+public class IgniteSqlSinglePartitionMultiParallelismTest extends AbstractIndexingCommonTest {
+    /** */
+    private static final String CACHE_NAME = "SC_NULL_TEST";
+
+    /** Test timeout. */
+    @Rule
+    public Timeout globalTimeout = new Timeout((int)GridTestUtils.DFLT_TEST_TIMEOUT);

Review comment:
       test timeout is already handled by GridAbstractTest#runRule




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [ignite] korlov42 commented on a change in pull request #9164: IGNITE-14120 fix multiple results bug when query parallelism is enabled.

Posted by GitBox <gi...@apache.org>.
korlov42 commented on a change in pull request #9164:
URL: https://github.com/apache/ignite/pull/9164#discussion_r649337290



##########
File path: modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSinglePartitionMultiParallelismTest.java
##########
@@ -0,0 +1,153 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.ignite.internal.processors.query;
+
+import java.util.Collections;
+import java.util.List;
+import org.apache.ignite.IgniteCache;
+import org.apache.ignite.cache.query.SqlFieldsQuery;
+import org.apache.ignite.configuration.CacheConfiguration;
+import org.apache.ignite.internal.processors.cache.index.AbstractIndexingCommonTest;
+import org.junit.Test;
+
+import static org.apache.ignite.cache.CacheAtomicityMode.TRANSACTIONAL;
+import static org.apache.ignite.cache.CacheMode.PARTITIONED;
+import static org.apache.ignite.cache.PartitionLossPolicy.READ_WRITE_SAFE;
+
+/**
+ * IGNITE-14120 Test for correct results in case of query with single partition and cache with parallelism > 1.
+ */
+public class IgniteSqlSinglePartitionMultiParallelismTest extends AbstractIndexingCommonTest {
+    /** */
+    private static final String CACHE_NAME = "SC_NULL_TEST";
+
+    /** {@inheritDoc} */
+    @Override protected void beforeTestsStarted() throws Exception {
+        startGrids(1);
+        ignite(0).createCache(cacheConfig());
+        createTable();
+    }
+
+    /** {@inheritDoc} */
+    @Override protected void afterTestsStopped() throws Exception {
+        grid(0).destroyCaches(Collections.singletonList(CACHE_NAME));
+    }
+
+    /**
+     * @return Cache configuration.
+     */
+    protected CacheConfiguration<Integer, Integer> cacheConfig() {
+        return new CacheConfiguration<Integer, Integer>()
+            .setName(CACHE_NAME)
+            .setCacheMode(PARTITIONED)
+            .setReadFromBackup(false)
+            .setStatisticsEnabled(true)
+            .setQueryParallelism(100)
+            .setSqlIndexMaxInlineSize(64)
+            .setBackups(0)
+            .setPartitionLossPolicy(READ_WRITE_SAFE)
+            .setAtomicityMode(TRANSACTIONAL);
+    }
+
+    /**
+     * Check common case without partitions. Should be single result.
+     */
+    @Test
+    public void assertSimpleCountQuery() throws Exception {
+        run(() -> {
+            List<List<?>> results = runQuery("select count(*) from SC_NULL_TEST");
+
+            Long res = (Long) results.get(0).get(0);
+
+            assertEquals(1, results.size());
+            assertEquals(Long.valueOf(999), res);
+        });
+    }
+
+    /**
+     * Check case with 1 partition. Partition segment must be calculated correctly.
+     */
+    @Test
+    public void assertWhereCountFirstPartitionQuery() throws Exception {
+        run(() -> {
+            List<List<?>> results = runQuery("select count(*) from SC_NULL_TEST where ID=1");
+
+            Long res = (Long) results.get(0).get(0);
+
+            assertEquals(1, results.size());
+            assertEquals(Long.valueOf(1), res);
+        });
+    }
+
+    /**
+     * Check case with 1 partition. Partition segment must be calculated correctly.
+     */
+    @Test
+    public void assertWhereCountAnotherPartitionQuery() throws Exception {
+        run(() -> {
+            List<List<?>> results = runQuery("select count(*) from SC_NULL_TEST where ID=973");
+
+            Long res = (Long) results.get(0).get(0);
+
+            assertEquals(1, results.size());
+            assertEquals(Long.valueOf(1), res);
+        });
+    }
+
+    /**
+     * Check case with 2 partition. Multiple partitions should not be affected.
+     */
+    @Test
+    public void assertWhereCountMultiPartitionsQuery() throws Exception {
+        run(() -> {
+            List<List<?>> results = runQuery("select count(*) from SC_NULL_TEST where ID=5 or ID=995");
+
+            Long res = (Long) results.get(0).get(0);
+
+            assertEquals(1, results.size());
+            assertEquals(Long.valueOf(2), res);
+        });
+    }
+
+    /** */
+    private void run(Runnable test) throws Exception {

Review comment:
       this method is useless now 




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [ignite] tledkov-gridgain merged pull request #9164: IGNITE-14120 fix multiple results bug when query parallelism is enabled.

Posted by GitBox <gi...@apache.org>.
tledkov-gridgain merged pull request #9164:
URL: https://github.com/apache/ignite/pull/9164


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [ignite] korlov42 commented on a change in pull request #9164: IGNITE-14120 fix multiple results bug when query parallelism is enabled.

Posted by GitBox <gi...@apache.org>.
korlov42 commented on a change in pull request #9164:
URL: https://github.com/apache/ignite/pull/9164#discussion_r649301268



##########
File path: modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSinglePartitionMultiParallelismTest.java
##########
@@ -0,0 +1,162 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.ignite.internal.processors.query;
+
+import java.util.Collections;
+import java.util.List;
+import org.apache.ignite.IgniteCache;
+import org.apache.ignite.cache.query.SqlFieldsQuery;
+import org.apache.ignite.configuration.CacheConfiguration;
+import org.apache.ignite.internal.processors.cache.index.AbstractIndexingCommonTest;
+import org.apache.ignite.testframework.GridTestUtils;
+import org.junit.Rule;
+import org.junit.Test;
+import org.junit.rules.Timeout;
+
+import static org.apache.ignite.cache.CacheAtomicityMode.TRANSACTIONAL;
+import static org.apache.ignite.cache.CacheMode.PARTITIONED;
+import static org.apache.ignite.cache.PartitionLossPolicy.READ_WRITE_SAFE;
+
+/**
+ * IGNITE-14120 Test for correct results in case of query with single partition and cache with parallelism > 1
+ */
+public class IgniteSqlSinglePartitionMultiParallelismTest extends AbstractIndexingCommonTest {
+    /** */
+    private static final String CACHE_NAME = "SC_NULL_TEST";
+
+    /** Test timeout. */
+    @Rule
+    public Timeout globalTimeout = new Timeout((int)GridTestUtils.DFLT_TEST_TIMEOUT);
+
+    /** {@inheritDoc} */
+    @Override protected void beforeTestsStarted() throws Exception {
+        startGrids(1);
+    }
+
+    /** {@inheritDoc} */
+    @Override protected void afterTest() throws Exception {
+        super.afterTest();
+
+        grid(0).destroyCaches(Collections.singletonList(CACHE_NAME));

Review comment:
       is it really necessary to recreate the table for every test?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [ignite] vladErmakov07 commented on pull request #9164: IGNITE-14120 fix multiple results bug when query parallelism is enabled.

Posted by GitBox <gi...@apache.org>.
vladErmakov07 commented on pull request #9164:
URL: https://github.com/apache/ignite/pull/9164#issuecomment-858635813


   @korlov42 could you please take a look?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [ignite] korlov42 commented on a change in pull request #9164: IGNITE-14120 fix multiple results bug when query parallelism is enabled.

Posted by GitBox <gi...@apache.org>.
korlov42 commented on a change in pull request #9164:
URL: https://github.com/apache/ignite/pull/9164#discussion_r649305008



##########
File path: modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSinglePartitionMultiParallelismTest.java
##########
@@ -0,0 +1,162 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.ignite.internal.processors.query;
+
+import java.util.Collections;
+import java.util.List;
+import org.apache.ignite.IgniteCache;
+import org.apache.ignite.cache.query.SqlFieldsQuery;
+import org.apache.ignite.configuration.CacheConfiguration;
+import org.apache.ignite.internal.processors.cache.index.AbstractIndexingCommonTest;
+import org.apache.ignite.testframework.GridTestUtils;
+import org.junit.Rule;
+import org.junit.Test;
+import org.junit.rules.Timeout;
+
+import static org.apache.ignite.cache.CacheAtomicityMode.TRANSACTIONAL;
+import static org.apache.ignite.cache.CacheMode.PARTITIONED;
+import static org.apache.ignite.cache.PartitionLossPolicy.READ_WRITE_SAFE;
+
+/**
+ * IGNITE-14120 Test for correct results in case of query with single partition and cache with parallelism > 1

Review comment:
       missed dot at the end




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [ignite] vladErmakov07 commented on a change in pull request #9164: IGNITE-14120 fix multiple results bug when query parallelism is enabled.

Posted by GitBox <gi...@apache.org>.
vladErmakov07 commented on a change in pull request #9164:
URL: https://github.com/apache/ignite/pull/9164#discussion_r649325759



##########
File path: modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSinglePartitionMultiParallelismTest.java
##########
@@ -0,0 +1,162 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.ignite.internal.processors.query;
+
+import java.util.Collections;
+import java.util.List;
+import org.apache.ignite.IgniteCache;
+import org.apache.ignite.cache.query.SqlFieldsQuery;
+import org.apache.ignite.configuration.CacheConfiguration;
+import org.apache.ignite.internal.processors.cache.index.AbstractIndexingCommonTest;
+import org.apache.ignite.testframework.GridTestUtils;
+import org.junit.Rule;
+import org.junit.Test;
+import org.junit.rules.Timeout;
+
+import static org.apache.ignite.cache.CacheAtomicityMode.TRANSACTIONAL;
+import static org.apache.ignite.cache.CacheMode.PARTITIONED;
+import static org.apache.ignite.cache.PartitionLossPolicy.READ_WRITE_SAFE;
+
+/**
+ * IGNITE-14120 Test for correct results in case of query with single partition and cache with parallelism > 1

Review comment:
       Fixed




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org