ignite-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pavel Tupitsyn (JIRA)" <j...@apache.org>
Subject [jira] [Created] (IGNITE-5786) .NET: Transaction fails with multiple write-through caches
Date Wed, 19 Jul 2017 16:49:00 GMT
Pavel Tupitsyn created IGNITE-5786:

             Summary: .NET: Transaction fails with multiple write-through caches
                 Key: IGNITE-5786
                 URL: https://issues.apache.org/jira/browse/IGNITE-5786
             Project: Ignite
          Issue Type: Bug
          Components: platforms
    Affects Versions: 1.6
            Reporter: Pavel Tupitsyn
            Assignee: Pavel Tupitsyn
             Fix For: 2.2

To reproduce: create two caches with {{WriteThrough=true}} and some {{CacheStore}} (implementation
can be empty).

Attempt to update both caches within a transaction:

            using (var tx = ignite.GetTransactions().TxStart())
                cache1.Put(1, 1);
                cache2.Put(1, 1);


Exception occurs:
(err) Failed to notify listener: o.a.i.i.processors.cache.distributed.near.GridNearTxLocal$16@17695df3javax.cache.integration.CacheWriterException:
PlatformNativeException [cause=System.InvalidOperationException [idHash=1909546776, hash=1265661973,
ClassName=System.InvalidOperationException, Data=null, ExceptionMethod=8
Apache.Ignite.Core, Version=, Culture=neutral, PublicKeyToken=a487a7ff0b2aaa4a
T Get[T](Int64, Boolean), HelpURL=null, HResult=-2146233079, InnerException=null, Message=Resource
handle has been released (is Ignite stopping?)., RemoteStackIndex=0, RemoteStackTraceString=null,
Source=Apache.Ignite.Core, StackTraceString=   at Apache.Ignite.Core.Impl.Handle.HandleRegistry.Get[T](Int64
id, Boolean throwOnAbsent) in C:\w\incubator-ignite\modules\platforms\dotnet\Apache.Ignite.Core\Impl\Handle\HandleRegistry.cs:line
   at Apache.Ignite.Core.Impl.Cache.Store.CacheStoreInternal`2.Invoke(IBinaryStream stream,
Ignite grid) in C:\w\incubator-ignite\modules\platforms\dotnet\Apache.Ignite.Core\Impl\Cache\Store\CacheStoreInternal.cs:line
   at Apache.Ignite.Core.Impl.Cache.Store.CacheStore.Invoke(PlatformMemoryStream stream, Ignite
grid) in C:\w\incubator-ignite\modules\platforms\dotnet\Apache.Ignite.Core\Impl\Cache\Store\CacheStore.cs:line
   at Apache.Ignite.Core.Impl.Unmanaged.UnmanagedCallbacks.CacheStoreInvoke(Int64 memPtr)
in C:\w\incubator-ignite\modules\platforms\dotnet\Apache.Ignite.Core\Impl\Unmanaged\UnmanagedCallbacks.cs:line

* Cache stores share same session within a transaction
* Session in Java is uses to store .NET session handle, so both stores have the same .NET
session (which is good: consistent with Java)
* Each store calls sessionEnd, so session gets released multiple times - this causes HandleRegistry

Current unit test uses Spring XML with shared {{PlatformDotNetCacheStoreFactory}}, which caches
created store instance for some reason, so the bug is hidden, since both caches use the same
store instance.

This message was sent by Atlassian JIRA

View raw message