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

[20584] Effectively assert automatic/manual_by_participant liveliness #4501

Merged
merged 6 commits into from
Mar 21, 2024

Conversation

Mario-DL
Copy link
Member

@Mario-DL Mario-DL commented Mar 5, 2024

Description

This PR brings a bugfix when asserting AUTOMATIC MANUAL_BY_PARTICIPANT liveliness kinds. In the scenario of having a participant with two datareaders (each of them with a lease duration of 2 secs) and other two participants with one publisher each one configured with AUTOMATIC_LIVELINESS. If we suddenly kill one of the publishers (network disconnection or Ctrl+C), the on_liveliness_changed() is not received on the reader side when we would expect it to happen (after 2 secs).

The problem stems from the fact that currently, in the reader-side participant, it is enough having an alive writer with the same kind (AUTOMATIC_LIVELINESS) to assert the liveliness of all of its readers with the same kind regardless of the participant.

This PR makes the liveliness assertion participant-aware by means of the guidPrefix.

@Mergifyio backport 2.13.x 2.12.x 2.10.x 2.6.x

Fixes #4373

Contributor Checklist

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

Reviewer Checklist

  • The PR has a milestone assigned.
  • The title and description correctly express the PR's purpose.
  • Check contributor checklist is correct.
  • Check CI results: changes do not issue any warning.
  • Check CI results: failing tests are unrelated with the changes.

@Mario-DL Mario-DL added this to the v2.14.1 milestone Mar 5, 2024
@Mario-DL
Copy link
Member Author

Mario-DL commented Mar 5, 2024

@richiprosima please test linux test discovery_server

@Mario-DL Mario-DL added needs-review PR that is ready to be reviewed ci-pending PR which CI is running labels Mar 5, 2024
@MiguelCompany
Copy link
Member

@Mergifyio rebase

Copy link
Contributor

mergify bot commented Mar 11, 2024

rebase

✅ Branch has been successfully rebased

@MiguelCompany MiguelCompany removed the needs-review PR that is ready to be reviewed label Mar 13, 2024
MiguelCompany
MiguelCompany previously approved these changes Mar 13, 2024
@JesusPoderoso
Copy link
Contributor

@richiprosima please test this

@Mario-DL
Copy link
Member Author

@richiprosima please test this

@EduPonz
Copy link

EduPonz commented Mar 20, 2024

@Mergifyio rebase master

Signed-off-by: Mario Dominguez <[email protected]>
Signed-off-by: Mario Dominguez <[email protected]>
Signed-off-by: Mario Dominguez <[email protected]>
… writer announcement period and lease duration test's writers

Signed-off-by: Mario Dominguez <[email protected]>
Copy link
Contributor

mergify bot commented Mar 20, 2024

rebase master

✅ Branch has been successfully rebased

@EduPonz
Copy link

EduPonz commented Mar 20, 2024

@richiprosima please test this

@EduPonz EduPonz removed the ci-pending PR which CI is running label Mar 21, 2024
@EduPonz
Copy link

EduPonz commented Mar 21, 2024

@Mergifyio backport 2.13.x 2.10.x 2.6.x

Copy link
Contributor

mergify bot commented Mar 21, 2024

@EduPonz EduPonz merged commit f708244 into master Mar 21, 2024
13 of 15 checks passed
@EduPonz EduPonz deleted the bugfix/20584 branch March 21, 2024 06:47
mergify bot pushed a commit that referenced this pull request Mar 21, 2024
* Refs #20584: Add BB test

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Fix

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Update LivelinessManager tests

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Linter

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Apply reviewer suggestions

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Fix PubSubParticipant comparison and add padding between writer announcement period and lease duration test's writers

Signed-off-by: Mario Dominguez <[email protected]>

---------

Signed-off-by: Mario Dominguez <[email protected]>
(cherry picked from commit f708244)
mergify bot pushed a commit that referenced this pull request Mar 21, 2024
* Refs #20584: Add BB test

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Fix

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Update LivelinessManager tests

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Linter

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Apply reviewer suggestions

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Fix PubSubParticipant comparison and add padding between writer announcement period and lease duration test's writers

Signed-off-by: Mario Dominguez <[email protected]>

---------

Signed-off-by: Mario Dominguez <[email protected]>
(cherry picked from commit f708244)
mergify bot pushed a commit that referenced this pull request Mar 21, 2024
* Refs #20584: Add BB test

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Fix

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Update LivelinessManager tests

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Linter

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Apply reviewer suggestions

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Fix PubSubParticipant comparison and add padding between writer announcement period and lease duration test's writers

Signed-off-by: Mario Dominguez <[email protected]>

---------

Signed-off-by: Mario Dominguez <[email protected]>
(cherry picked from commit f708244)
EduPonz pushed a commit that referenced this pull request Mar 26, 2024
…#4596)

* Refs #20584: Add BB test

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Fix

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Update LivelinessManager tests

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Linter

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Apply reviewer suggestions

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Fix PubSubParticipant comparison and add padding between writer announcement period and lease duration test's writers

Signed-off-by: Mario Dominguez <[email protected]>

---------

Signed-off-by: Mario Dominguez <[email protected]>
(cherry picked from commit f708244)

Co-authored-by: Mario Domínguez López <[email protected]>
EduPonz pushed a commit that referenced this pull request Mar 28, 2024
…#4594)

* Refs #20584: Add BB test

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Fix

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Update LivelinessManager tests

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Linter

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Apply reviewer suggestions

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Fix PubSubParticipant comparison and add padding between writer announcement period and lease duration test's writers

Signed-off-by: Mario Dominguez <[email protected]>

---------

Signed-off-by: Mario Dominguez <[email protected]>
(cherry picked from commit f708244)

Co-authored-by: Mario Domínguez López <[email protected]>
MiguelCompany pushed a commit that referenced this pull request Mar 30, 2024
* Refs #20584: Add BB test

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Fix

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Update LivelinessManager tests

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Linter

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Apply reviewer suggestions

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Fix PubSubParticipant comparison and add padding between writer announcement period and lease duration test's writers

Signed-off-by: Mario Dominguez <[email protected]>

---------

Signed-off-by: Mario Dominguez <[email protected]>
(cherry picked from commit f708244)
MiguelCompany pushed a commit that referenced this pull request Mar 31, 2024
…#4595)

* Refs #20584: Add BB test

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Fix

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Update LivelinessManager tests

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Linter

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Apply reviewer suggestions

Signed-off-by: Mario Dominguez <[email protected]>

* Refs #20584: Fix PubSubParticipant comparison and add padding between writer announcement period and lease duration test's writers

Signed-off-by: Mario Dominguez <[email protected]>

---------

Signed-off-by: Mario Dominguez <[email protected]>
(cherry picked from commit f708244)

Co-authored-by: Mario Domínguez López <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

The Reader's Liveliness state does not change when the connection with the remote Participant is lost
4 participants