Skip to content

Conversation

@emiliocuestaf
Copy link
Contributor

@emiliocuestaf emiliocuestaf commented Nov 25, 2025

Description

The issue that started this investigation was the case where a Safe DDS Writer and a Safe DDS Reader in different domains talked to one another through a DDS Router in a KEYED topic.

  • If the router had RTPS participants, samples were all written in the same instance (the default) in the Safe DDS Reader, because they were sent as being valid
  • If the router had DDS participants, the issue was in the DDS Router participants. The Writer placed all changes in the same instance (default), the Reader rejected because the instance had never been initialised, but the rejection reason was misleading

<style type="text/css"></style>

  instanceHandle (in change/write) compute_key current behavior expected result notes (on the expected result)
RTPSWriter NULL or UNDEF X provided KEY_HASH sent (it was read as valid*) no KEY_HASH sent but message is sent anyway Case required to allow forwarding in router with RTPS participants
OK X inlineQoS KEY_HASH sent in message inlineQoS KEY_HASH sent in message  
DDSWriter NULL or UNDEF TRUE computed KEY_HASH sent in message computed KEY_HASH sent in message  
OK TRUE In Release: The key is not recomputedIn Debug: The key is recomputed, if they differ, PRECONDITION_NOT_MET In Release: The key is not recomputedIn Debug: The key is recomputed, if they differ, PRECONDITION_NOT_MET  
NULL or UNDEF FALSE (or returned undef handle) provided KEY_HASH sent (it was read as valid*) PRECONDITION NOT MET If we don't throw error, we don't know in which history each sample should be stored and samples are at risk of being overwritten
OK FALSE (or returned undef handle) In Release: The key is not recomputedIn Debug: The key is recomputed, if they differ, PRECONDITION_NOT_MET In Release: The key is not recomputedIn Debug: The key is recomputed, if they differ, PRECONDITION_NOT_MET  

<style type="text/css"></style>

  instanceHandle (from msg) compute_key current behavior expected result notes (on the expected result)
RTPSReader NULL or UNDEF X ok ok Case required to allow forwarding in router with RTPS participants
OK X ok ok  
DDSReader NULL or UNDEF TRUE uses computed key uses computed key  
OK TRUE uses provided key uses provided key Could recompute and check for an error?
NULL or UNDEF FALSE (or returned undef handle) REJECTED_BY_INSTANCES_LIMIT REJECTED_BY_UNKNOWN_INSTANCE Added category to be more explicit
OK FALSE (or returned undef handle) uses provided key uses provided key  

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.
  • 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.
  • New feature has been added to the versions.md file (if applicable).
  • 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.

@emiliocuestaf emiliocuestaf changed the title Undefined InstanceHandle is forwarded as defined Undefined InstanceHandle forwarded as defined Nov 25, 2025
@github-actions github-actions bot added the ci-pending PR which CI is running label Nov 26, 2025
@mergify
Copy link
Contributor

mergify bot commented Nov 27, 2025

🧪 CI Insights

Here's what we observed from your CI run for ae0a3f2.

❌ Job Failures

Pipeline Job Health on master Retries 🔍 CI Insights 📄 Logs
Fast DDS MacOS CI mac-ci / fastdds_test () Unknown 0 View View
Fast DDS Windows CI windows-ci / fastdds_test (RelWithDebInfo, examples), v142 Unknown 0 View View
windows-ci / fastdds_test (RelWithDebInfo, examples), v143 Unknown 1 View View

@emiliocuestaf emiliocuestaf requested review from richiprosima and removed request for richiprosima November 28, 2025 05:54
@MiguelCompany MiguelCompany added this to the v3.4.2 milestone Nov 28, 2025
@emiliocuestaf emiliocuestaf requested review from richiprosima and removed request for richiprosima December 1, 2025 14:39
@emiliocuestaf emiliocuestaf changed the title Undefined InstanceHandle forwarded as defined [#23986] Undefined InstanceHandle forwarded as defined Dec 2, 2025
@emiliocuestaf emiliocuestaf changed the title [#23986] Undefined InstanceHandle forwarded as defined [23986] Undefined InstanceHandle forwarded as defined Dec 2, 2025
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
@emiliocuestaf emiliocuestaf force-pushed the hotfix/undefined-instance-handle-fix branch from a18884f to e7728b6 Compare December 3, 2025 06:15
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
@emiliocuestaf emiliocuestaf requested review from richiprosima and removed request for richiprosima December 3, 2025 06:31
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
@emiliocuestaf emiliocuestaf force-pushed the hotfix/undefined-instance-handle-fix branch from c8307bf to 537427b Compare December 3, 2025 06:53
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.

3 participants