You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@qpid.apache.org by "Ken Giusti (Jira)" <ji...@apache.org> on 2021/05/18 20:43:00 UTC

[jira] [Created] (DISPATCH-2135) data race accessing Q2 holdoff state

Ken Giusti created DISPATCH-2135:
------------------------------------

             Summary: data race accessing Q2 holdoff state
                 Key: DISPATCH-2135
                 URL: https://issues.apache.org/jira/browse/DISPATCH-2135
             Project: Qpid Dispatch
          Issue Type: Bug
          Components: Router Node
    Affects Versions: 1.16.0
            Reporter: Ken Giusti
            Assignee: Ken Giusti
             Fix For: 1.17.0


qd_message_Q2_holdoff_disable() modifies the disable_q2_holdoff flag without holding the message content lock.  In the below trace the holdoff is being disabled by the timer thread while being read by an I/O thread:

 

74: WARNING: ThreadSanitizer: data race (pid=643055) 
74: Write of size 1 at 0x7b64000658b5 by thread T2: 
74: #0 qd_message_Q2_holdoff_disable /home/kgiusti/work/dispatch/qpid-dispatch/src/message.c:2876 (libqpid-dispatch.so+0x9a2bc) 
74: #1 qdr_tcp_deliver /home/kgiusti/work/dispatch/qpid-dispatch/src/adaptors/tcp_adaptor.c:1405 (libqpid-dispatch.so+0x65f91) 
74: #2 qdr_link_process_deliveries /home/kgiusti/work/dispatch/qpid-dispatch/src/router_core/transfer.c:178 (libqpid-dispatch.so+0x1045c6) 
74: #3 qdr_tcp_push /home/kgiusti/work/dispatch/qpid-dispatch/src/adaptors/tcp_adaptor.c:1392 (libqpid-dispatch.so+0x65e9b) 
74: #4 qdr_connection_process /home/kgiusti/work/dispatch/qpid-dispatch/src/router_core/connections.c:414 (libqpid-dispatch.so+0xc4bec) 
74: #5 on_activate /home/kgiusti/work/dispatch/qpid-dispatch/src/adaptors/tcp_adaptor.c:155 (libqpid-dispatch.so+0x5e251) 
74: #6 qd_timer_visit /home/kgiusti/work/dispatch/qpid-dispatch/src/timer.c:317 (libqpid-dispatch.so+0x135b52) 
74: #7 handle /home/kgiusti/work/dispatch/qpid-dispatch/src/server.c:1006 (libqpid-dispatch.so+0x12fc8d) 
74: #8 thread_run /home/kgiusti/work/dispatch/qpid-dispatch/src/server.c:1121 (libqpid-dispatch.so+0x13063a) 
74: #9 _thread_init /home/kgiusti/work/dispatch/qpid-dispatch/src/posix/threading.c:172 (libqpid-dispatch.so+0xad37a) 
74: #10 <null> <null> (libtsan.so.0+0x2d33f) 
74: 
74: Previous read of size 1 at 0x7b64000658b5 by thread T3 (mutexes: write M2644): 
74: #0 qd_message_Q2_holdoff_should_block /home/kgiusti/work/dispatch/qpid-dispatch/src/message.c:2885 (libqpid-dispatch.so+0x9a327) 
74: #1 qd_message_extend /home/kgiusti/work/dispatch/qpid-dispatch/src/message.c:2400 (libqpid-dispatch.so+0x97eda) 
74: #2 qd_message_stream_data_append /home/kgiusti/work/dispatch/qpid-dispatch/src/message.c:2965 (libqpid-dispatch.so+0x9a7ae) 
74: #3 handle_incoming /home/kgiusti/work/dispatch/qpid-dispatch/src/adaptors/tcp_adaptor.c:393 (libqpid-dispatch.so+0x5fb17) 
74: #4 handle_connection_event /home/kgiusti/work/dispatch/qpid-dispatch/src/adaptors/tcp_adaptor.c:850 (libqpid-dispatch.so+0x6232c) 
74: #5 handle_event_with_context /home/kgiusti/work/dispatch/qpid-dispatch/src/server.c:802 (libqpid-dispatch.so+0x12ecb6) 
74: #6 do_handle_raw_connection_event /home/kgiusti/work/dispatch/qpid-dispatch/src/server.c:808 (libqpid-dispatch.so+0x12ed08) 
74: #7 handle /home/kgiusti/work/dispatch/qpid-dispatch/src/server.c:1089 (libqpid-dispatch.so+0x1304e6) 
74: #8 thread_run /home/kgiusti/work/dispatch/qpid-dispatch/src/server.c:1121 (libqpid-dispatch.so+0x13063a) 
74: #9 _thread_init /home/kgiusti/work/dispatch/qpid-dispatch/src/posix/threading.c:172 (libqpid-dispatch.so+0xad37a) 
74: #10 <null> <null> (libtsan.so.0+0x2d33f)



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

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@qpid.apache.org
For additional commands, e-mail: dev-help@qpid.apache.org