[ 
https://issues.apache.org/jira/browse/DISPATCH-2183?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17376001#comment-17376001
 ] 

Charles E. Rolke commented on DISPATCH-2183:
--------------------------------------------

Commit 2b7a4 adds
 * printouts of the router server start/stop times
 * deadlock analysis

Two recurring deadlocks happen in multiple routers:
h3. CONNECTOR - ENTITY_CACHE

This lock inversion occurs after startup and before shutdown and should be 
mitigated.
{code:java}
371179227080 Server  begin time: 2021-07-06 14:22:59.698457, ticks: 371179227080
371179227358 TID:       0x513580   LOCK        CONNECTOR       ALLOC_INIT     
ENTITY_CACHE ==> [ LOCK acquire_uS 0 ]
371179227407 TID:       0x513580 UNLOCK        CONNECTOR       ALLOC_INIT     
ENTITY_CACHE <== [0x17bb488 UNLOCK acquire_uS 0 use 49 total  49 ]
371228850930 TID:       0x513580   LOCK           PYTHON           ROUTER     
ENTITY_CACHE        CONNECTOR ==> [ LOCK acquire_uS 0 ]
371228850938 TID:       0x513580 UNLOCK           PYTHON           ROUTER     
ENTITY_CACHE        CONNECTOR <== [0x1b1c848 UNLOCK acquire_uS 0 use 8 total  8 
]
371229387480 Server    end time: 2021-07-06 14:23:49.858857, ticks: 371229387480
{code}
h3. LOG - ENTITY_CACHE

This inversion appears less problematic as code holding the LOG lock and taking 
the ENTITY_CACHE lock happens only at startup.
 At runtime code holding the ENTITY_CACHE lock routinely takes the LOG lock.
{code:java}
371179125586 TID:       0x513580   LOCK              LOG     ENTITY_CACHE ==> [ 
LOCK acquire_uS 0 ]
371179125591 TID:       0x513580 UNLOCK              LOG     ENTITY_CACHE <== 
[0x17bb488 UNLOCK acquire_uS 0 use 5 total  5 ]
371179220368 TID:       0x513580   LOCK           PYTHON              LOG     
ENTITY_CACHE ==> [ LOCK acquire_uS 0 ]
371179220372 TID:       0x513580 UNLOCK           PYTHON              LOG     
ENTITY_CACHE <== [0x17bb488 UNLOCK acquire_uS 0 use 4 total  4 ]

371179227080 Server  begin time: 2021-07-06 14:22:59.698457, ticks: 371179227080
371228849932 TID:       0x513580   LOCK           PYTHON           ROUTER     
ENTITY_CACHE              LOG ==> [ LOCK acquire_uS 1 ]
371229387480 Server    end time: 2021-07-06 14:23:49.858857, ticks: 371229387480
{code}

> Thread locking analysis
> -----------------------
>
>                 Key: DISPATCH-2183
>                 URL: https://issues.apache.org/jira/browse/DISPATCH-2183
>             Project: Qpid Dispatch
>          Issue Type: Test
>          Components: Router Node
>    Affects Versions: 1.16.0
>            Reporter: Charles E. Rolke
>            Assignee: Charles E. Rolke
>            Priority: Major
>              Labels: performance
>         Attachments: 
> DISPATCH-2183_3f2bd_router-mesh_three-router-test_routerb.txt, 
> DISPATCH-2183_85f805_topology-disposition-routerA.txt
>
>
> This issue holds files related to thread locking analysis tracked in 
> [https://github.com/apache/qpid-dispatch/pull/1261|PR-1261]. As the PR 
> progresses analysis results will be posted here.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to