Repository: ignite Updated Branches: refs/heads/ignite-gg-14206 17f017896 -> ba13ed956
IGNITE-9390: MVCC: added new properties to .NET IgniteConfiguration and CacheAtomicityMode. This closes #4887. Project: http://git-wip-us.apache.org/repos/asf/ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/45721371 Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/45721371 Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/45721371 Branch: refs/heads/ignite-gg-14206 Commit: 457213713a442b734cddb59c1c8310fc6d9cd340 Parents: 96c271b Author: devozerov <voze...@gridgain.com> Authored: Tue Oct 2 14:27:39 2018 +0300 Committer: devozerov <voze...@gridgain.com> Committed: Tue Oct 2 14:27:39 2018 +0300 ---------------------------------------------------------------------- .../apache/ignite/cache/CacheAtomicityMode.java | 10 +++-- .../configuration/IgniteConfiguration.java | 30 +++++++-------- .../utils/PlatformConfigurationUtils.java | 8 ++++ .../ApiParity/IgniteConfigurationParityTest.cs | 4 +- .../Cache/CachePartitionedTest.cs | 37 ++++++++++++++++++ .../Config/full-config.xml | 2 +- .../IgniteConfigurationSerializerTest.cs | 3 ++ .../IgniteConfigurationTest.cs | 7 ++++ .../Cache/Configuration/CacheAtomicityMode.cs | 30 ++++++++++++++- .../Apache.Ignite.Core/IgniteConfiguration.cs | 40 ++++++++++++++++++++ .../IgniteConfigurationSection.xsd | 11 ++++++ .../Impl/Binary/BinaryReaderExtensions.cs | 8 ++++ .../Impl/Binary/BinaryWriterExtensions.cs | 16 +++++++- 13 files changed, 182 insertions(+), 24 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/ignite/blob/45721371/modules/core/src/main/java/org/apache/ignite/cache/CacheAtomicityMode.java ---------------------------------------------------------------------- diff --git a/modules/core/src/main/java/org/apache/ignite/cache/CacheAtomicityMode.java b/modules/core/src/main/java/org/apache/ignite/cache/CacheAtomicityMode.java index 43c561c..5b101bf 100644 --- a/modules/core/src/main/java/org/apache/ignite/cache/CacheAtomicityMode.java +++ b/modules/core/src/main/java/org/apache/ignite/cache/CacheAtomicityMode.java @@ -38,6 +38,10 @@ public enum CacheAtomicityMode { * <b>Note!</b> In this mode, transactional consistency is guaranteed for key-value API operations only. * To enable ACID capabilities for SQL transactions, use the {@code TRANSACTIONAL_SNAPSHOT} mode. * <p> + * <b>Note!</b> This atomicity mode is not compatible with the other modes within the same transaction. + * if a transaction is executed over multiple caches, all caches must have the same atomicity mode, + * either {@code TRANSACTIONAL_SNAPSHOT} or {@code TRANSACTIONAL}. + * <p> * See {@link Transaction} for more information about transactions. */ TRANSACTIONAL, @@ -109,9 +113,9 @@ public enum CacheAtomicityMode { * by the coordinator. This snapshot ensures that the transaction works with a consistent database state * during its execution period. * <p> - * Note! This atomicity mode is not compatible with the other modes within the same transaction. - * If a transaction is executed over multiple caches, all caches must have the same mode, - * either {@code TRANSACTIONAL_SNAPSHOT} or {@code TRANSACTIONAL} + * <b>Note!</b> This atomicity mode is not compatible with the other modes within the same transaction. + * If a transaction is executed over multiple caches, all caches must have the same atomicity mode, + * either {@code TRANSACTIONAL_SNAPSHOT} or {@code TRANSACTIONAL}. * <p> * See {@link Transaction} for more information about transactions. */ http://git-wip-us.apache.org/repos/asf/ignite/blob/45721371/modules/core/src/main/java/org/apache/ignite/configuration/IgniteConfiguration.java ---------------------------------------------------------------------- diff --git a/modules/core/src/main/java/org/apache/ignite/configuration/IgniteConfiguration.java b/modules/core/src/main/java/org/apache/ignite/configuration/IgniteConfiguration.java index 6a0c7cb..964c73b 100644 --- a/modules/core/src/main/java/org/apache/ignite/configuration/IgniteConfiguration.java +++ b/modules/core/src/main/java/org/apache/ignite/configuration/IgniteConfiguration.java @@ -214,11 +214,11 @@ public class IgniteConfiguration { /** Default timeout after which long query warning will be printed. */ public static final long DFLT_LONG_QRY_WARN_TIMEOUT = 3000; - /** Default size of MVCC vacuum thread pool. */ + /** Default number of MVCC vacuum threads.. */ public static final int DFLT_MVCC_VACUUM_THREAD_CNT = 2; - /** Default time interval between vacuum process runs (ms). */ - public static final int DFLT_MVCC_VACUUM_FREQUENCY = 5000; + /** Default time interval between MVCC vacuum runs in milliseconds. */ + public static final long DFLT_MVCC_VACUUM_FREQUENCY = 5000; /** Optional local Ignite instance name. */ private String igniteInstanceName; @@ -496,8 +496,8 @@ public class IgniteConfiguration { /** Size of MVCC vacuum thread pool. */ private int mvccVacuumThreadCnt = DFLT_MVCC_VACUUM_THREAD_CNT; - /** Time interval between vacuum process runs (ms). */ - private int mvccVacuumFreq = DFLT_MVCC_VACUUM_FREQUENCY; + /** Time interval between vacuum runs (ms). */ + private long mvccVacuumFreq = DFLT_MVCC_VACUUM_FREQUENCY; /** User authentication enabled. */ private boolean authEnabled; @@ -2998,18 +2998,18 @@ public class IgniteConfiguration { } /** - * Returns number of MVCC vacuum cleanup threads. + * Returns number of MVCC vacuum threads. * - * @return Number of MVCC vacuum cleanup threads. + * @return Number of MVCC vacuum threads. */ public int getMvccVacuumThreadCount() { return mvccVacuumThreadCnt; } /** - * Sets number of MVCC vacuum cleanup threads. + * Sets number of MVCC vacuum threads. * - * @param mvccVacuumThreadCnt Number of MVCC vacuum cleanup threads. + * @param mvccVacuumThreadCnt Number of MVCC vacuum threads. * @return {@code this} for chaining. */ public IgniteConfiguration setMvccVacuumThreadCount(int mvccVacuumThreadCnt) { @@ -3019,21 +3019,21 @@ public class IgniteConfiguration { } /** - * Returns time interval between vacuum runs. + * Returns time interval between MVCC vacuum runs in milliseconds. * - * @return Time interval between vacuum runs. + * @return Time interval between MVCC vacuum runs in milliseconds. */ - public int getMvccVacuumFrequency() { + public long getMvccVacuumFrequency() { return mvccVacuumFreq; } /** - * Sets time interval between vacuum runs. + * Sets time interval between MVCC vacuum runs in milliseconds. * - * @param mvccVacuumFreq Time interval between vacuum runs. + * @param mvccVacuumFreq Time interval between MVCC vacuum runs in milliseconds. * @return {@code this} for chaining. */ - public IgniteConfiguration setMvccVacuumFrequency(int mvccVacuumFreq) { + public IgniteConfiguration setMvccVacuumFrequency(long mvccVacuumFreq) { this.mvccVacuumFreq = mvccVacuumFreq; return this; http://git-wip-us.apache.org/repos/asf/ignite/blob/45721371/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/utils/PlatformConfigurationUtils.java ---------------------------------------------------------------------- diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/utils/PlatformConfigurationUtils.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/utils/PlatformConfigurationUtils.java index cd67f15..8e66102 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/utils/PlatformConfigurationUtils.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/utils/PlatformConfigurationUtils.java @@ -654,6 +654,10 @@ public class PlatformConfigurationUtils { cfg.setActiveOnStart(in.readBoolean()); if (in.readBoolean()) cfg.setAuthenticationEnabled(in.readBoolean()); + if (in.readBoolean()) + cfg.setMvccVacuumFrequency(in.readLong()); + if (in.readBoolean()) + cfg.setMvccVacuumThreadCount(in.readInt()); int sqlSchemasCnt = in.readInt(); @@ -1201,6 +1205,10 @@ public class PlatformConfigurationUtils { w.writeBoolean(cfg.isActiveOnStart()); w.writeBoolean(true); w.writeBoolean(cfg.isAuthenticationEnabled()); + w.writeBoolean(true); + w.writeLong(cfg.getMvccVacuumFrequency()); + w.writeBoolean(true); + w.writeInt(cfg.getMvccVacuumThreadCount()); if (cfg.getSqlSchemas() == null) w.writeInt(-1); http://git-wip-us.apache.org/repos/asf/ignite/blob/45721371/modules/platforms/dotnet/Apache.Ignite.Core.Tests/ApiParity/IgniteConfigurationParityTest.cs ---------------------------------------------------------------------- diff --git a/modules/platforms/dotnet/Apache.Ignite.Core.Tests/ApiParity/IgniteConfigurationParityTest.cs b/modules/platforms/dotnet/Apache.Ignite.Core.Tests/ApiParity/IgniteConfigurationParityTest.cs index 5b4106a..1fd8e72 100644 --- a/modules/platforms/dotnet/Apache.Ignite.Core.Tests/ApiParity/IgniteConfigurationParityTest.cs +++ b/modules/platforms/dotnet/Apache.Ignite.Core.Tests/ApiParity/IgniteConfigurationParityTest.cs @@ -80,9 +80,7 @@ namespace Apache.Ignite.Core.Tests.ApiParity "TimeServerPortBase", "TimeServerPortRange", "IncludeProperties", - "isAutoActivationEnabled", // IGNITE-7301 - "MvccVacuumFrequency", //TODO: IGNITE-9390: Remove when Mvcc support will be added. - "MvccVacuumThreadCount" //TODO: IGNITE-9390: Remove when Mvcc support will be added. + "isAutoActivationEnabled" // IGNITE-7301 }; /// <summary> http://git-wip-us.apache.org/repos/asf/ignite/blob/45721371/modules/platforms/dotnet/Apache.Ignite.Core.Tests/Cache/CachePartitionedTest.cs ---------------------------------------------------------------------- diff --git a/modules/platforms/dotnet/Apache.Ignite.Core.Tests/Cache/CachePartitionedTest.cs b/modules/platforms/dotnet/Apache.Ignite.Core.Tests/Cache/CachePartitionedTest.cs index 68546b9..c9100b2 100644 --- a/modules/platforms/dotnet/Apache.Ignite.Core.Tests/Cache/CachePartitionedTest.cs +++ b/modules/platforms/dotnet/Apache.Ignite.Core.Tests/Cache/CachePartitionedTest.cs @@ -17,6 +17,9 @@ namespace Apache.Ignite.Core.Tests.Cache { + using Apache.Ignite.Core.Cache; + using Apache.Ignite.Core.Cache.Configuration; + using Apache.Ignite.Core.Transactions; using NUnit.Framework; [Category(TestUtils.CategoryIntensive)] @@ -41,5 +44,39 @@ namespace Apache.Ignite.Core.Tests.Cache { return 1; } + + /// <summary> + /// Test MVCC transaction. + /// </summary> + [Test] + public void TestMvccTransaction() + { + IIgnite ignite = GetIgnite(0); + + ICache<int, int> cache = ignite.GetOrCreateCache<int, int>(new CacheConfiguration + { + Name = "mvcc", + AtomicityMode = CacheAtomicityMode.TransactionalSnapshot + }); + + ITransaction tx = ignite.GetTransactions().TxStart(); + + cache.Put(1, 1); + cache.Put(2, 2); + + tx.Commit(); + + Assert.AreEqual(1, cache.Get(1)); + Assert.AreEqual(2, cache.Get(2)); + + tx = ignite.GetTransactions().TxStart(); + + Assert.AreEqual(1, cache.Get(1)); + Assert.AreEqual(2, cache.Get(2)); + + tx.Commit(); + + ignite.DestroyCache("mvcc"); + } } } http://git-wip-us.apache.org/repos/asf/ignite/blob/45721371/modules/platforms/dotnet/Apache.Ignite.Core.Tests/Config/full-config.xml ---------------------------------------------------------------------- diff --git a/modules/platforms/dotnet/Apache.Ignite.Core.Tests/Config/full-config.xml b/modules/platforms/dotnet/Apache.Ignite.Core.Tests/Config/full-config.xml index b091a49..4aa5190 100644 --- a/modules/platforms/dotnet/Apache.Ignite.Core.Tests/Config/full-config.xml +++ b/modules/platforms/dotnet/Apache.Ignite.Core.Tests/Config/full-config.xml @@ -23,7 +23,7 @@ workDirectory='c:' JvmMaxMemoryMb='1024' MetricsLogFrequency='0:0:10' isDaemon='true' isLateAffinityAssignment='false' springConfigUrl='c:\myconfig.xml' autoGenerateIgniteInstanceName='true' peerAssemblyLoadingMode='CurrentAppDomain' longQueryWarningTimeout='1:2:3' isActiveOnStart='false' - consistentId='someId012' redirectJavaConsoleOutput='false' authenticationEnabled='true'> + consistentId='someId012' redirectJavaConsoleOutput='false' authenticationEnabled='true' mvccVacuumFrequency='10000' mvccVacuumThreadCount='4'> <localhost>127.1.1.1</localhost> <binaryConfiguration compactFooter='false' keepDeserialized='true'> <nameMapper type='Apache.Ignite.Core.Tests.IgniteConfigurationSerializerTest+NameMapper' bar='testBar' /> http://git-wip-us.apache.org/repos/asf/ignite/blob/45721371/modules/platforms/dotnet/Apache.Ignite.Core.Tests/IgniteConfigurationSerializerTest.cs ---------------------------------------------------------------------- diff --git a/modules/platforms/dotnet/Apache.Ignite.Core.Tests/IgniteConfigurationSerializerTest.cs b/modules/platforms/dotnet/Apache.Ignite.Core.Tests/IgniteConfigurationSerializerTest.cs index e2ece20..ec9d4fd 100644 --- a/modules/platforms/dotnet/Apache.Ignite.Core.Tests/IgniteConfigurationSerializerTest.cs +++ b/modules/platforms/dotnet/Apache.Ignite.Core.Tests/IgniteConfigurationSerializerTest.cs @@ -100,6 +100,9 @@ namespace Apache.Ignite.Core.Tests Assert.IsFalse(cfg.IsActiveOnStart); Assert.IsTrue(cfg.AuthenticationEnabled); + Assert.AreEqual(10000, cfg.MvccVacuumFrequency); + Assert.AreEqual(4, cfg.MvccVacuumThreadCount); + Assert.IsNotNull(cfg.SqlSchemas); Assert.AreEqual(2, cfg.SqlSchemas.Count); Assert.IsTrue(cfg.SqlSchemas.Contains("SCHEMA_1")); http://git-wip-us.apache.org/repos/asf/ignite/blob/45721371/modules/platforms/dotnet/Apache.Ignite.Core.Tests/IgniteConfigurationTest.cs ---------------------------------------------------------------------- diff --git a/modules/platforms/dotnet/Apache.Ignite.Core.Tests/IgniteConfigurationTest.cs b/modules/platforms/dotnet/Apache.Ignite.Core.Tests/IgniteConfigurationTest.cs index a03d09c..2861c30 100644 --- a/modules/platforms/dotnet/Apache.Ignite.Core.Tests/IgniteConfigurationTest.cs +++ b/modules/platforms/dotnet/Apache.Ignite.Core.Tests/IgniteConfigurationTest.cs @@ -242,6 +242,9 @@ namespace Apache.Ignite.Core.Tests AssertExtensions.ReflectionEqual(cfg.DataStorageConfiguration, resCfg.DataStorageConfiguration); + Assert.AreEqual(cfg.MvccVacuumFrequency, resCfg.MvccVacuumFrequency); + Assert.AreEqual(cfg.MvccVacuumThreadCount, resCfg.MvccVacuumThreadCount); + Assert.IsNotNull(resCfg.SqlSchemas); Assert.AreEqual(2, resCfg.SqlSchemas.Count); Assert.IsTrue(resCfg.SqlSchemas.Contains("SCHEMA_3")); @@ -498,6 +501,8 @@ namespace Apache.Ignite.Core.Tests cfg.ClientConnectorConfigurationEnabled); Assert.AreEqual(IgniteConfiguration.DefaultRedirectJavaConsoleOutput, cfg.RedirectJavaConsoleOutput); Assert.AreEqual(IgniteConfiguration.DefaultAuthenticationEnabled, cfg.AuthenticationEnabled); + Assert.AreEqual(IgniteConfiguration.DefaultMvccVacuumFrequency, cfg.MvccVacuumFrequency); + Assert.AreEqual(IgniteConfiguration.DefaultMvccVacuumThreadCount, cfg.MvccVacuumThreadCount); // Thread pools. Assert.AreEqual(IgniteConfiguration.DefaultManagementThreadPoolSize, cfg.ManagementThreadPoolSize); @@ -836,6 +841,8 @@ namespace Apache.Ignite.Core.Tests } }, AuthenticationEnabled = false, + MvccVacuumFrequency = 20000, + MvccVacuumThreadCount = 8, SqlSchemas = new List<string> { "SCHEMA_3", "schema_4" } }; http://git-wip-us.apache.org/repos/asf/ignite/blob/45721371/modules/platforms/dotnet/Apache.Ignite.Core/Cache/Configuration/CacheAtomicityMode.cs ---------------------------------------------------------------------- diff --git a/modules/platforms/dotnet/Apache.Ignite.Core/Cache/Configuration/CacheAtomicityMode.cs b/modules/platforms/dotnet/Apache.Ignite.Core/Cache/Configuration/CacheAtomicityMode.cs index 8c36a77..49e5d12 100644 --- a/modules/platforms/dotnet/Apache.Ignite.Core/Cache/Configuration/CacheAtomicityMode.cs +++ b/modules/platforms/dotnet/Apache.Ignite.Core/Cache/Configuration/CacheAtomicityMode.cs @@ -26,6 +26,13 @@ namespace Apache.Ignite.Core.Cache.Configuration { /// <summary> /// Specifies fully ACID-compliant transactional cache behavior. + /// <para /> + /// <b>Note!</b> In this mode, transactional consistency is guaranteed for key-value API operations only. + /// To enable ACID capabilities for SQL transactions, use TRANSACTIONAL_SNAPSHOT mode. + /// <para /> + /// <b>Note!</b> This atomicity mode is not compatible with the other atomicity modes within the same transaction. + /// If a transaction is executed over multiple caches, all caches must have the same atomicity mode, + /// either TRANSACTIONAL_SNAPSHOT or TRANSACTIONAL. /// </summary> Transactional, @@ -49,6 +56,27 @@ namespace Apache.Ignite.Core.Cache.Configuration /// Also note that all data modifications in <see cref="Atomic"/> mode are guaranteed to be atomic /// and consistent with writes to the underlying persistent store, if one is configured. /// </summary> - Atomic + Atomic, + + /// <summary> + /// Specifies fully ACID-compliant transactional cache behavior for both key-value API and SQL transactions. + /// <para/> + /// This atomicity mode enables multiversion concurrency control (MVCC) for the cache. In MVCC-enabled caches, + /// when a transaction updates a row, it creates a new version of that row instead of overwriting it. + /// Other users continue to see the old version of the row until the transaction is committed. + /// In this way, readers and writers do not conflict with each other and always work with a consistent dataset. + /// The old version of data is cleaned up when it's no longer accessed by anyone. + /// <para /> + /// With this mode enabled, one node is elected as an MVCC coordinator. This node tracks all in-flight transactions + /// and queries executed in the cluster. Each transaction or query executed over the cache with + /// TRANSACTIONAL_SNAPSHOT mode works with a current snapshot of data generated for this transaction or query + /// by the coordinator. This snapshot ensures that the transaction works with a consistent database state + /// during its execution period. + /// <para /> + /// <b>Note!</b> This atomicity mode is not compatible with the other atomicity modes within the same transaction. + /// If a transaction is executed over multiple caches, all caches must have the same atomicity mode, + /// either TRANSACTIONAL_SNAPSHOT or TRANSACTIONAL. + /// </summary> + TransactionalSnapshot, } } \ No newline at end of file http://git-wip-us.apache.org/repos/asf/ignite/blob/45721371/modules/platforms/dotnet/Apache.Ignite.Core/IgniteConfiguration.cs ---------------------------------------------------------------------- diff --git a/modules/platforms/dotnet/Apache.Ignite.Core/IgniteConfiguration.cs b/modules/platforms/dotnet/Apache.Ignite.Core/IgniteConfiguration.cs index bd53118..315b27d 100644 --- a/modules/platforms/dotnet/Apache.Ignite.Core/IgniteConfiguration.cs +++ b/modules/platforms/dotnet/Apache.Ignite.Core/IgniteConfiguration.cs @@ -205,6 +205,12 @@ namespace Apache.Ignite.Core /** Map from user-defined listener to it's id. */ private Dictionary<object, int> _localEventListenerIds; + /** MVCC vacuum frequency. */ + private long? _mvccVacuumFreq; + + /** MVCC vacuum thread count. */ + private int? _mvccVacuumThreadCnt; + /// <summary> /// Default network retry count. /// </summary> @@ -231,6 +237,16 @@ namespace Apache.Ignite.Core public const bool DefaultAuthenticationEnabled = false; /// <summary> + /// Default value for <see cref="MvccVacuumFrequency"/> property. + /// </summary> + public const long DefaultMvccVacuumFrequency = 5000; + + /// <summary> + /// Default value for <see cref="MvccVacuumThreadCount"/> property. + /// </summary> + public const int DefaultMvccVacuumThreadCount = 2; + + /// <summary> /// Initializes a new instance of the <see cref="IgniteConfiguration"/> class. /// </summary> public IgniteConfiguration() @@ -309,6 +325,8 @@ namespace Apache.Ignite.Core writer.WriteTimeSpanAsLongNullable(_longQueryWarningTimeout); writer.WriteBooleanNullable(_isActiveOnStart); writer.WriteBooleanNullable(_authenticationEnabled); + writer.WriteLongNullable(_mvccVacuumFreq); + writer.WriteIntNullable(_mvccVacuumThreadCnt); if (SqlSchemas == null) writer.WriteInt(-1); @@ -675,6 +693,8 @@ namespace Apache.Ignite.Core _longQueryWarningTimeout = r.ReadTimeSpanNullable(); _isActiveOnStart = r.ReadBooleanNullable(); _authenticationEnabled = r.ReadBooleanNullable(); + _mvccVacuumFreq = r.ReadLongNullable(); + _mvccVacuumThreadCnt = r.ReadIntNullable(); int sqlSchemasCnt = r.ReadInt(); @@ -1550,6 +1570,26 @@ namespace Apache.Ignite.Core } /// <summary> + /// Time interval between MVCC vacuum runs in milliseconds. + /// </summary> + [DefaultValue(DefaultMvccVacuumFrequency)] + public long MvccVacuumFrequency + { + get { return _mvccVacuumFreq ?? DefaultMvccVacuumFrequency; } + set { _mvccVacuumFreq = value; } + } + + /// <summary> + /// Number of MVCC vacuum threads. + /// </summary> + [DefaultValue(DefaultMvccVacuumThreadCount)] + public int MvccVacuumThreadCount + { + get { return _mvccVacuumThreadCnt ?? DefaultMvccVacuumThreadCount; } + set { _mvccVacuumThreadCnt = value; } + } + + /// <summary> /// Gets or sets predefined failure handlers implementation. /// A failure handler handles critical failures of Ignite instance accordingly: /// <para><see cref="NoOpFailureHandler"/> -- do nothing.</para> http://git-wip-us.apache.org/repos/asf/ignite/blob/45721371/modules/platforms/dotnet/Apache.Ignite.Core/IgniteConfigurationSection.xsd ---------------------------------------------------------------------- diff --git a/modules/platforms/dotnet/Apache.Ignite.Core/IgniteConfigurationSection.xsd b/modules/platforms/dotnet/Apache.Ignite.Core/IgniteConfigurationSection.xsd index ebbef67..4040610 100644 --- a/modules/platforms/dotnet/Apache.Ignite.Core/IgniteConfigurationSection.xsd +++ b/modules/platforms/dotnet/Apache.Ignite.Core/IgniteConfigurationSection.xsd @@ -2265,6 +2265,17 @@ <xs:documentation>Whether user authentication is enabled for the cluster.</xs:documentation> </xs:annotation> </xs:attribute> + <xs:attribute name="mvccVacuumFrequency" type="xs:long"> + <xs:annotation> + <xs:documentation>Time interval between MVCC vacuum runs in milliseconds.</xs:documentation> + </xs:annotation> + </xs:attribute> + + <xs:attribute name="mvccVacuumThreadCount" type="xs:int"> + <xs:annotation> + <xs:documentation>Number of MVCC vacuum threads.</xs:documentation> + </xs:annotation> + </xs:attribute> <xs:attribute name="clientConnectorConfigurationEnabled" type="xs:boolean"> <xs:annotation> <xs:documentation>Whether client connector should be enabled (allow thin clients, ODBC and JDBC drivers to work with Ignite).</xs:documentation> http://git-wip-us.apache.org/repos/asf/ignite/blob/45721371/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/BinaryReaderExtensions.cs ---------------------------------------------------------------------- diff --git a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/BinaryReaderExtensions.cs b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/BinaryReaderExtensions.cs index b13318c..5fca62d 100644 --- a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/BinaryReaderExtensions.cs +++ b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/BinaryReaderExtensions.cs @@ -79,6 +79,14 @@ namespace Apache.Ignite.Core.Impl.Binary } /// <summary> + /// Reads the nullable long. + /// </summary> + public static long? ReadLongNullable(this IBinaryRawReader reader) + { + return reader.ReadBoolean() ? reader.ReadLong() : (long?) null; + } + + /// <summary> /// Reads the nullable bool. /// </summary> public static bool? ReadBooleanNullable(this IBinaryRawReader reader) http://git-wip-us.apache.org/repos/asf/ignite/blob/45721371/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/BinaryWriterExtensions.cs ---------------------------------------------------------------------- diff --git a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/BinaryWriterExtensions.cs b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/BinaryWriterExtensions.cs index e504d75..b965bca 100644 --- a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/BinaryWriterExtensions.cs +++ b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/BinaryWriterExtensions.cs @@ -44,7 +44,7 @@ namespace Apache.Ignite.Core.Impl.Binary } /// <summary> - /// Writes the nullable boolean. + /// Writes the nullable int. /// </summary> public static void WriteIntNullable(this IBinaryRawWriter writer, int? value) { @@ -58,6 +58,20 @@ namespace Apache.Ignite.Core.Impl.Binary } /// <summary> + /// Writes the nullable long. + /// </summary> + public static void WriteLongNullable(this IBinaryRawWriter writer, long? value) + { + if (value != null) + { + writer.WriteBoolean(true); + writer.WriteLong(value.Value); + } + else + writer.WriteBoolean(false); + } + + /// <summary> /// Writes the timespan. /// </summary> public static void WriteTimeSpanAsLong(this IBinaryRawWriter writer, TimeSpan value)