Skip to content

Race condition in MultiThreadedExecutor with intra_process communication resulting in dequeuing ring buffer before enqueuing #1007

Description

@brawner

There is a race condition in the MultiThreadedExecutor that happens during the test_multithreahed.multi_consumer_intra_process test in test_rclcpp. The intra_process_buffer's ring_buffer_implementation has dequeue() called without any data. It may be that some process is calling dequeue() right after another has checked has_data().

This bug results in a flakey test with test_rclcpp, but it's fairly reliable to reproduce with sufficient repeat-until-fail iterations.

https://ci.ros2.org/view/nightly/job/nightly_linux_repeated/1780/testReport/(root)/projectroot/gtest_multithreaded__rmw_fastrtps_cpp/
https://ci.ros2.org/job/ci_windows/9412/testReport/

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions