ignite-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Artem Shutak (JIRA)" <j...@apache.org>
Subject [jira] [Created] (IGNITE-804) [Test] Synchronous evicts may cause a deadlock
Date Fri, 24 Apr 2015 15:06:38 GMT
Artem Shutak created IGNITE-804:
-----------------------------------

             Summary: [Test] Synchronous evicts may cause a deadlock
                 Key: IGNITE-804
                 URL: https://issues.apache.org/jira/browse/IGNITE-804
             Project: Ignite
          Issue Type: Bug
            Reporter: Artem Shutak
            Assignee: Yakov Zhdanov
             Fix For: sprint-5


See gg-5276

{noformat}
[20:22:49,442][INFO ][start-stop-thread-1][GridDataLoaderProcessorSelfTest] >>>>>>>
Started node: 2ed6cd2e-f581-4831-81e5-7e8063e020c4
java.lang.Exception: <20:22:49,911><DEBUG><gridgain-#1467%dataload.GridDataLoaderProcessorSelfTest4%>
>>>>>>>>>>>>>>>>>>>
	at org.gridgain.grid.util.GridUtils.dumpStack(GridUtils.java:661)
	at org.gridgain.grid.kernal.processors.cache.distributed.dht.GridDhtPartitionTopologyImpl.wLock(GridDhtPartitionTopologyImpl.java:179)
	at org.gridgain.grid.kernal.processors.cache.distributed.dht.GridDhtPartitionTopologyImpl.onEvicted(GridDhtPartitionTopologyImpl.java:1105)
	at org.gridgain.grid.kernal.processors.cache.distributed.dht.preloader.GridDhtPreloader.onPartitionEvicted(GridDhtPreloader.java:475)
	at org.gridgain.grid.kernal.processors.cache.distributed.dht.GridDhtLocalPartition.tryEvict(GridDhtLocalPartition.java:393)
	at org.gridgain.grid.kernal.processors.cache.distributed.dht.GridDhtLocalPartition.onRemoved(GridDhtLocalPartition.java:188)
	at org.gridgain.grid.kernal.processors.cache.distributed.dht.GridDhtPartitionTopologyImpl.onRemoved(GridDhtPartitionTopologyImpl.java:567)
	at org.gridgain.grid.kernal.processors.cache.distributed.dht.GridDhtCacheEntry.onMarkedObsolete(GridDhtCacheEntry.java:97)
	at org.gridgain.grid.kernal.processors.cache.GridCacheMapEntry.evictInternal(GridCacheMapEntry.java:2187)
	at org.gridgain.grid.kernal.processors.cache.GridCacheEvictionManager.evict0(GridCacheEvictionManager.java:693)
	at org.gridgain.grid.kernal.processors.cache.GridCacheEvictionManager.access$2200(GridCacheEvictionManager.java:49)
	at org.gridgain.grid.kernal.processors.cache.GridCacheEvictionManager$EvictionFuture.prepare0(GridCacheEvictionManager.java:1678)
	at org.gridgain.grid.kernal.processors.cache.GridCacheEvictionManager$EvictionFuture.prepare(GridCacheEvictionManager.java:1591)
	at org.gridgain.grid.kernal.processors.cache.GridCacheEvictionManager.addToCurrentFuture(GridCacheEvictionManager.java:1052)
	at org.gridgain.grid.kernal.processors.cache.GridCacheEvictionManager.checkEvictionQueue(GridCacheEvictionManager.java:1008)
	at org.gridgain.grid.kernal.processors.cache.GridCacheEvictionManager.unwind(GridCacheEvictionManager.java:1278)
	at org.gridgain.grid.kernal.processors.cache.GridCacheUtils.unwindEvicts(GridCacheUtils.java:1402)
	at org.gridgain.grid.kernal.processors.cache.GridCacheIoManager.processUnordered(GridCacheIoManager.java:210)
	at org.gridgain.grid.kernal.processors.cache.GridCacheIoManager.access$500(GridCacheIoManager.java:35)
	at org.gridgain.grid.kernal.processors.cache.GridCacheIoManager$1.onMessage(GridCacheIoManager.java:113)
	at org.gridgain.grid.kernal.managers.communication.GridIoManager$GridFilteredMessageListener.onMessage(GridIoManager.java:1612)
	at org.gridgain.grid.kernal.managers.communication.GridIoManager.processRegularMessage0(GridIoManager.java:675)
	at org.gridgain.grid.kernal.managers.communication.GridIoManager.access$1900(GridIoManager.java:50)
	at org.gridgain.grid.kernal.managers.communication.GridIoManager$6.body(GridIoManager.java:636)
	at org.gridgain.grid.util.worker.GridWorker.run(GridWorker.java:139)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
	at java.lang.Thread.run(Thread.java:722)
{noformat}

To debug this, I have added a check before write lock acquisition:

{noformat}
    private void wLock() {
        int cnt0 = cnt.get();

        if (cnt0 > 0)
            U.dumpStack(">>>>>>>>>>>>>>>>>>>");

        lock.writeLock().lock();
    }
{noformat}

cnt here is a thread local that holds count of read locks hold by current thread.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message