Francesco Nigro created ARTEMIS-2347:
----------------------------------------

             Summary: JournalStorageManager::stopReplication can deadlock while 
stopping
                 Key: ARTEMIS-2347
                 URL: https://issues.apache.org/jira/browse/ARTEMIS-2347
             Project: ActiveMQ Artemis
          Issue Type: Bug
          Components: Broker
    Affects Versions: 2.8.1
            Reporter: Francesco Nigro
             Fix For: 2.9.0
         Attachments: deadlock_stacktrace.txt

JournalStorageManager::stopReplication needs to:
 # acquires the manager write lock
 # acquires (if any) large message intrinsic locks during 
performCachedLargeMessageDeletes
 # acquires the manager read lock on confirmPendingLargeMessage

JournalStorageManager::stop needs to:
 # acquires (if any) large message intrinsic locks during 
performCachedLargeMessageDeletes
 # acquires the manager read lock on confirmPendingLargeMessage

A racing call to JournalStorageManager::stopReplication while stopping could 
deadlock
 the broker:
 # JournalStorageManager::stop acquires a large message intrinsic locks during 
performCachedLargeMessageDeletes
 # JournalStorageManager::stopReplication acquires the manager write lock
 # JournalStorageManager::stop wait is blocked on the manager write lock before 
releasing the lock on large message
 # JournalStorageManager::stopReplication is blocked on the large message 
intrinsic lock before releasing the manager write lock
 # deadlock occurred: none can proceed



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to