Skip to content

[23213] Add localhost capability only to UDP & TCP transports (backport #5864)#5869

Merged
MiguelCompany merged 1 commit into
2.14.xfrom
mergify/bp/2.14.x/pr-5864
Jun 13, 2025
Merged

[23213] Add localhost capability only to UDP & TCP transports (backport #5864)#5869
MiguelCompany merged 1 commit into
2.14.xfrom
mergify/bp/2.14.x/pr-5864

Conversation

@mergify

@mergify mergify Bot commented Jun 11, 2025

Copy link
Copy Markdown
Contributor

Description

PR #3733 introduced a new proxy parameter (network configuration) used to transmit in discovery the information of whether transformation of locators to localhost can be applied for each transport kind. In this parameter, the value of each possible locator kind (powers of 2) is used to conform the binary mask corresponding to the network configuration parameter. However, in PR #5116 the value of shared memory kind was modified in a way that may pollute the values corresponding to UDP transport kinds.

This PR solves the issue by only setting the corresponding localhost network configuration for transports supporting it (UDP and TCP). It also adds an extra assertion verifying the bit operation can be safely done.

@Mergifyio backport 3.2.x 2.14.x

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

  • N/A Any new/modified methods have been properly documented using Doxygen.

  • N/A Any new configuration API has an equivalent XML API (with the corresponding XSD extension)

  • Changes are backport compatible: they do NOT break ABI nor change library core behavior.

  • 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.
  • If this is a critical bug fix, backports to the critical-only supported branches have been requested.
  • Check CI results: changes do not issue any warning.
  • Check CI results: failing tests are unrelated with the changes.

This is an automatic backport of pull request #5864 done by [Mergify](https://mergify.com).

@mergify mergify Bot added the conflicts Backport PR wich git cherry pick failed label Jun 11, 2025
@mergify

mergify Bot commented Jun 11, 2025

Copy link
Copy Markdown
Contributor Author

Cherry-pick of 401ccad has failed:

On branch mergify/bp/2.14.x/pr-5864
Your branch is up to date with 'origin/2.14.x'.

You are currently cherry-picking commit 401ccad5.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Changes to be committed:
	modified:   include/fastdds/rtps/transport/TransportInterface.h
	new file:   src/cpp/rtps/network/NetworkConfiguration.cpp
	new file:   src/cpp/rtps/network/NetworkConfiguration.hpp
	modified:   src/cpp/rtps/network/NetworkFactory.cpp

Unmerged paths:
  (use "git add/rm <file>..." as appropriate to mark resolution)
	deleted by them: include/fastdds/rtps/builtin/data/NetworkConfiguration.hpp
	both modified:   src/cpp/CMakeLists.txt
	both modified:   src/cpp/rtps/builtin/discovery/participant/PDPSimple.cpp
	both modified:   test/blackbox/common/BlackboxTestsNetworkConf.cpp
	both modified:   test/blackbox/common/DDSBlackboxTestsMonitorService.cpp
	both modified:   test/unittest/dds/publisher/CMakeLists.txt
	both modified:   test/unittest/rtps/discovery/CMakeLists.txt
	both modified:   test/unittest/rtps/network/CMakeLists.txt
	both modified:   test/unittest/rtps/reader/CMakeLists.txt
	both modified:   test/unittest/statistics/dds/CMakeLists.txt
	both modified:   test/unittest/statistics/rtps/CMakeLists.txt
	both modified:   test/unittest/transport/CMakeLists.txt

To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally

Signed-off-by: Juan Lopez Fernandez <juanlopez@eprosima.com>
@juanlofer-eprosima
juanlofer-eprosima force-pushed the mergify/bp/2.14.x/pr-5864 branch from 2fec630 to 205e745 Compare June 12, 2025 06:06
@juanlofer-eprosima
juanlofer-eprosima requested review from MiguelCompany and removed request for MiguelCompany June 12, 2025 06:06
@juanlofer-eprosima juanlofer-eprosima removed the conflicts Backport PR wich git cherry pick failed label Jun 12, 2025
@juanlofer-eprosima
juanlofer-eprosima requested review from MiguelCompany and removed request for MiguelCompany June 12, 2025 09:48
@github-actions github-actions Bot added the ci-pending PR which CI is running label Jun 12, 2025
@MiguelCompany
MiguelCompany merged commit 30ceff8 into 2.14.x Jun 13, 2025
29 of 30 checks passed
@MiguelCompany
MiguelCompany deleted the mergify/bp/2.14.x/pr-5864 branch June 13, 2025 15:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci-pending PR which CI is running

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants