Valentin Kulichenko created IGNITE-1988: -------------------------------------------
Summary: NPE when explicit lock is acquired within a transaction Key: IGNITE-1988 URL: https://issues.apache.org/jira/browse/IGNITE-1988 Project: Ignite Issue Type: Bug Components: cache Reporter: Valentin Kulichenko Priority: Critical Fix For: 1.5 This code: {code} try (Transaction tx = Ignition.ignite().transactions().txStart()) { cache.lock(1).lock(); } {code} result in the NPE: {code} Exception in thread "main" java.lang.NullPointerException at org.apache.ignite.internal.processors.cache.distributed.dht.colocated.GridDhtColocatedLockFuture.addEntry(GridDhtColocatedLockFuture.java:294) at org.apache.ignite.internal.processors.cache.distributed.dht.colocated.GridDhtColocatedLockFuture.addLocalKey(GridDhtColocatedLockFuture.java:1172) at org.apache.ignite.internal.processors.cache.distributed.dht.colocated.GridDhtColocatedLockFuture.mapAsPrimary(GridDhtColocatedLockFuture.java:1118) at org.apache.ignite.internal.processors.cache.distributed.dht.colocated.GridDhtColocatedLockFuture.map(GridDhtColocatedLockFuture.java:736) at org.apache.ignite.internal.processors.cache.distributed.dht.colocated.GridDhtColocatedLockFuture.mapOnTopology(GridDhtColocatedLockFuture.java:677) at org.apache.ignite.internal.processors.cache.distributed.dht.colocated.GridDhtColocatedLockFuture.map(GridDhtColocatedLockFuture.java:629) at org.apache.ignite.internal.processors.cache.distributed.dht.colocated.GridDhtColocatedCache.lockAllAsync(GridDhtColocatedCache.java:628) at org.apache.ignite.internal.processors.cache.distributed.GridDistributedCacheAdapter.lockAllAsync(GridDistributedCacheAdapter.java:117) at org.apache.ignite.internal.processors.cache.GridCacheAdapter.lockAll(GridCacheAdapter.java:3150) at org.apache.ignite.internal.processors.cache.CacheLockImpl.lock(CacheLockImpl.java:72) at org.apache.ignite.examples.datagrid.CacheTransactionExample.deposit(CacheTransactionExample.java:92) at org.apache.ignite.examples.datagrid.CacheTransactionExample.main(CacheTransactionExample.java:70) {code} If such usage is invalid, proper exception should be thrown. -- This message was sent by Atlassian JIRA (v6.3.4#6332)