You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ignite.apache.org by se...@apache.org on 2017/03/28 15:12:09 UTC
[1/3] ignite git commit: Fixed.
Repository: ignite
Updated Branches:
refs/heads/master d44de994e -> db21f7354
Fixed.
Project: http://git-wip-us.apache.org/repos/asf/ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/088b3c0f
Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/088b3c0f
Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/088b3c0f
Branch: refs/heads/master
Commit: 088b3c0f6255f47cbaa81d3f365c1f0925d675b4
Parents: 8362fe7
Author: Andrey V. Mashenkov <an...@gmail.com>
Authored: Wed Mar 15 18:35:21 2017 +0300
Committer: Andrey V. Mashenkov <an...@gmail.com>
Committed: Wed Mar 15 19:30:03 2017 +0300
----------------------------------------------------------------------
.../query/h2/opt/GridH2TreeIndex.java | 4 +--
.../query/IgniteSqlSegmentedIndexSelfTest.java | 30 ++++++++++++++++++--
2 files changed, 30 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ignite/blob/088b3c0f/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/opt/GridH2TreeIndex.java
----------------------------------------------------------------------
diff --git a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/opt/GridH2TreeIndex.java b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/opt/GridH2TreeIndex.java
index 2873211..663d863 100644
--- a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/opt/GridH2TreeIndex.java
+++ b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/opt/GridH2TreeIndex.java
@@ -286,8 +286,8 @@ public class GridH2TreeIndex extends GridH2IndexBase implements Comparator<GridS
* @param row Search row.
* @return Row.
*/
- public GridH2Row findOne(GridSearchRowPointer row) {
- int seg = threadLocalSegment();
+ GridH2Row findOne(GridSearchRowPointer row) {
+ int seg = segmentForRow(row);
return segments[seg].get(row);
}
http://git-wip-us.apache.org/repos/asf/ignite/blob/088b3c0f/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSegmentedIndexSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSegmentedIndexSelfTest.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSegmentedIndexSelfTest.java
index f8c9dd5..800138c 100644
--- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSegmentedIndexSelfTest.java
+++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSegmentedIndexSelfTest.java
@@ -27,6 +27,7 @@ import org.apache.ignite.IgniteCache;
import org.apache.ignite.cache.CacheAtomicityMode;
import org.apache.ignite.cache.CacheKeyConfiguration;
import org.apache.ignite.cache.CacheMode;
+import org.apache.ignite.cache.eviction.fifo.FifoEvictionPolicy;
import org.apache.ignite.cache.query.SqlFieldsQuery;
import org.apache.ignite.cache.query.annotations.QuerySqlField;
import org.apache.ignite.configuration.CacheConfiguration;
@@ -34,6 +35,7 @@ import org.apache.ignite.configuration.IgniteConfiguration;
import org.apache.ignite.spi.discovery.tcp.TcpDiscoverySpi;
import org.apache.ignite.spi.discovery.tcp.ipfinder.TcpDiscoveryIpFinder;
import org.apache.ignite.spi.discovery.tcp.ipfinder.vm.TcpDiscoveryVmIpFinder;
+import org.apache.ignite.spi.swapspace.file.FileSwapSpaceSpi;
import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest;
/**
@@ -63,6 +65,8 @@ public class IgniteSqlSegmentedIndexSelfTest extends GridCommonAbstractTest {
cfg.setDiscoverySpi(disco);
+ cfg.setSwapSpaceSpi(new FileSwapSpaceSpi());
+
return cfg;
}
@@ -77,7 +81,7 @@ public class IgniteSqlSegmentedIndexSelfTest extends GridCommonAbstractTest {
* @param idxTypes Indexed types.
* @return Cache configuration.
*/
- private static <K, V> CacheConfiguration<K, V> cacheConfig(String name, boolean partitioned, Class<?>... idxTypes) {
+ protected <K, V> CacheConfiguration<K, V> cacheConfig(String name, boolean partitioned, Class<?>... idxTypes) {
return new CacheConfiguration<K, V>()
.setName(name)
.setCacheMode(partitioned ? CacheMode.PARTITIONED : CacheMode.REPLICATED)
@@ -104,6 +108,28 @@ public class IgniteSqlSegmentedIndexSelfTest extends GridCommonAbstractTest {
}
/**
+ * Run tests on single-node grid
+ * @throws Exception If failed.
+ */
+ public void testSingleNodeIndexSegmentationWithSwapEnabled() throws Exception {
+ startGridsMultiThreaded(1, true);
+
+ final IgniteCache<Object, Object> cache = ignite(0).createCache(cacheConfig("org", true, Integer.class, Organization.class)
+ .setOffHeapMaxMemory(-1)
+ .setSwapEnabled(true)
+ .setEvictionPolicy(new FifoEvictionPolicy(10)));
+
+ for (int i = 0; i < 20; i++)
+ cache.put(i, new Organization("org-" + i));
+
+ String select0 = "select name from \"org\".Organization";
+
+ List<List<?>> result = cache.query(new SqlFieldsQuery(select0)).getAll();
+
+ assertEquals(20, result.size());
+ }
+
+ /**
* Run tests on multi-node grid
* @throws Exception If failed.
*/
@@ -170,7 +196,7 @@ public class IgniteSqlSegmentedIndexSelfTest extends GridCommonAbstractTest {
Set<Integer> localOrgIds = new HashSet<>();
- for(Cache.Entry<Integer, Organization> e : c2.localEntries())
+ for (Cache.Entry<Integer, Organization> e : c2.localEntries())
localOrgIds.add(e.getKey());
int expectedPersons = 0;
[3/3] ignite git commit: Merge remote-tracking branch 'origin/master'
Posted by se...@apache.org.
Merge remote-tracking branch 'origin/master'
Project: http://git-wip-us.apache.org/repos/asf/ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/db21f735
Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/db21f735
Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/db21f735
Branch: refs/heads/master
Commit: db21f73548efca8a3380b24577a08aad88b964fe
Parents: 118492d d44de99
Author: Sergi Vladykin <se...@gmail.com>
Authored: Tue Mar 28 18:12:05 2017 +0300
Committer: Sergi Vladykin <se...@gmail.com>
Committed: Tue Mar 28 18:12:05 2017 +0300
----------------------------------------------------------------------
.../internal/binary/BinaryClassDescriptor.java | 10 +-
.../ignite/internal/binary/BinaryContext.java | 2 +-
.../internal/binary/BinaryFieldMetadata.java | 127 +++++++++++
.../ignite/internal/binary/BinaryMetadata.java | 20 +-
.../binary/BinaryMetadataCollector.java | 17 +-
.../ignite/internal/binary/BinaryUtils.java | 14 +-
.../binary/builder/BinaryObjectBuilderImpl.java | 14 +-
.../binary/CacheObjectBinaryProcessor.java | 3 +-
.../binary/CacheObjectBinaryProcessorImpl.java | 3 +-
.../platform/PlatformContextImpl.java | 82 +++----
modules/platforms/cpp/binary/Makefile.am | 2 +-
.../platforms/cpp/binary/include/Makefile.am | 1 +
.../include/ignite/binary/binary_object.h | 75 ++++++-
.../ignite/impl/binary/binary_field_meta.h | 110 ++++++++++
.../ignite/impl/binary/binary_id_resolver.h | 96 +++++++-
.../ignite/impl/binary/binary_object_header.h | 13 ++
.../ignite/impl/binary/binary_object_impl.h | 124 +++++++++--
.../include/ignite/impl/binary/binary_schema.h | 10 +-
.../ignite/impl/binary/binary_type_handler.h | 47 ++--
.../ignite/impl/binary/binary_type_manager.h | 48 ++--
.../ignite/impl/binary/binary_type_snapshot.h | 82 +++++--
.../ignite/impl/binary/binary_type_updater.h | 19 +-
.../ignite/impl/binary/binary_writer_impl.h | 17 +-
.../cpp/binary/project/vs/binary.vcxproj | 3 +-
.../binary/project/vs/binary.vcxproj.filters | 9 +-
.../src/impl/binary/binary_field_meta.cpp | 42 ++++
.../src/impl/binary/binary_object_impl.cpp | 139 +++++++++++-
.../src/impl/binary/binary_type_handler.cpp | 45 +---
.../src/impl/binary/binary_type_manager.cpp | 187 +++++++---------
.../src/impl/binary/binary_type_snapshot.cpp | 50 ++---
.../src/impl/binary/binary_type_updater.cpp | 32 ---
.../cpp/core-test/config/cache-identity.xml | 33 +++
.../core-test/include/ignite/binary_test_defs.h | 5 +
.../src/binary_identity_resolver_test.cpp | 91 +++++++-
.../cpp/core-test/src/binary_object_test.cpp | 220 ++++++++++++++++++-
.../cpp/core-test/src/cache_invoke_test.cpp | 2 +
.../cpp/core-test/src/cluster_test.cpp | 5 +-
.../impl/binary/binary_type_updater_impl.h | 6 +-
.../cpp/core/include/ignite/impl/ignite_impl.h | 11 +
.../ignite/impl/interop/interop_target.h | 2 +-
.../impl/binary/binary_type_updater_impl.cpp | 101 +++++++--
.../cpp/core/src/impl/ignite_environment.cpp | 4 +-
.../core/src/impl/interop/interop_target.cpp | 2 +-
.../Apache.Ignite.Core.csproj | 1 +
.../Impl/Binary/BinaryObjectBuilder.cs | 2 +-
.../Impl/Binary/BinaryProcessor.cs | 3 +-
.../Impl/Binary/BinaryWriter.cs | 2 +-
.../Impl/Binary/Marshaller.cs | 6 +-
.../Impl/Binary/Metadata/BinaryField.cs | 72 ++++++
.../Impl/Binary/Metadata/BinaryType.cs | 38 +++-
.../Binary/Metadata/BinaryTypeHashsetHandler.cs | 10 +-
.../Impl/Binary/Metadata/BinaryTypeHolder.cs | 9 +-
.../Impl/Binary/Metadata/IBinaryTypeHandler.cs | 2 +-
53 files changed, 1586 insertions(+), 484 deletions(-)
----------------------------------------------------------------------
[2/3] ignite git commit: Merge branch 'ignite-4826' of
https://github.com/gridgain/apache-ignite
Posted by se...@apache.org.
Merge branch 'ignite-4826' of https://github.com/gridgain/apache-ignite
Project: http://git-wip-us.apache.org/repos/asf/ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/118492d5
Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/118492d5
Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/118492d5
Branch: refs/heads/master
Commit: 118492d57bba1dcdae740839977de61240fc3158
Parents: 8ae3d5b 088b3c0
Author: Sergi Vladykin <se...@gmail.com>
Authored: Tue Mar 28 18:11:05 2017 +0300
Committer: Sergi Vladykin <se...@gmail.com>
Committed: Tue Mar 28 18:11:05 2017 +0300
----------------------------------------------------------------------
.../query/h2/opt/GridH2TreeIndex.java | 4 +--
.../query/IgniteSqlSegmentedIndexSelfTest.java | 30 ++++++++++++++++++--
2 files changed, 30 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ignite/blob/118492d5/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/opt/GridH2TreeIndex.java
----------------------------------------------------------------------