Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[14749] Solving sanitizer issue 4139 <master> #2685

Merged
merged 7 commits into from
Jun 6, 2022
Merged

Conversation

MiguelBarro
Copy link
Contributor

@MiguelBarro MiguelBarro commented May 18, 2022

For sanitizer CI see #2679

Description

LivelinessManager should be refactored in order to solve lock inversion issues reported in several issues like 4139.
The class has now a

    std::mutex mutex_;

devoted to safeguarding the class data (including member collection contents). And a

   shared_mutex col_mutex_;

devoted to protecting member collections and allowing their safe traversal without taking any writer lock that will lead to lock inversion.
The code was reordered in order to prevent any callbacks (potencial deadlock sources) with any lock taken (only shared_lock or none is allowed.

Contributor Checklist

  • Commit messages follow the project guidelines.
  • The code follows the style guidelines of this project.
  • NA Tests that thoroughly check the new feature have been added/Regression tests checking the bug and its fix have been added.
  • Any new/modified methods have been properly documented using Doxygen.
  • Fast DDS test suite has been run locally.
  • Changes are ABI compatible.
  • Changes are API compatible.
  • Documentation builds and tests pass locally.
  • NA New feature has been added to the versions.md file (if applicable).
  • NA New feature has been documented/Current behavior is correctly described in the documentation.

Reviewer Checklist

  • Check contributor checklist is correct.
  • Check CI results: changes do not issue any warning.
  • Check CI results: failing tests are unrelated with the changes.

@MiguelBarro MiguelBarro changed the title Solving sanitizer issue 4139 Solving sanitizer issue 4139 <master> May 19, 2022
@EduPonz EduPonz added this to the v2.6.1 milestone Jun 1, 2022
@MiguelBarro MiguelBarro changed the title Solving sanitizer issue 4139 <master> [14749] Solving sanitizer issue 4139 <master> Jun 2, 2022
@MiguelBarro MiguelBarro force-pushed the test/issue/4139 branch 2 times, most recently from ec2218b to c1744b2 Compare June 3, 2022 11:31
@MiguelBarro MiguelBarro added skip-ci Automatically pass CI no-aarch Skip build & test for aarch64 labels Jun 6, 2022
Miguel Barro and others added 7 commits June 6, 2022 15:43
Signed-off-by: Javier Santiago <javiersantiago@eprosima.com>
Signed-off-by: Javier Santiago <javiersantiago@eprosima.com>
Signed-off-by: Javier Santiago <javiersantiago@eprosima.com>
Signed-off-by: Miguel Barro <miguelbarro@eprosima.com>
Signed-off-by: Miguel Barro <miguelbarro@eprosima.com>
Copy link
Contributor

@jsan-rt jsan-rt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@MiguelCompany MiguelCompany added no-test Skip CI tests if PR marked with this label and removed skip-ci Automatically pass CI labels Jun 6, 2022
@MiguelCompany
Copy link
Member

@richiprosima Please test this

@MiguelCompany MiguelCompany merged commit 8a074ce into master Jun 6, 2022
@MiguelCompany MiguelCompany deleted the test/issue/4139 branch June 6, 2022 17:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
no-aarch Skip build & test for aarch64 no-test Skip CI tests if PR marked with this label
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants