Destructor for SenderResouce

asked 2017-12-28 20:23:45 -0500

glkhobragade gravatar image

updated 2017-12-29 08:15:32 -0500

Once participant is created in the Fast-RTPS (i.e. Real time publisher subscriber, one of the DDS implementation) layer or any publisher is created, senderResource objects are created by the network factory inside RTPSParticipantImpl.cpp and keep the senderResource object with itself in a vector.

But if the publisher is removed, the corresponding senderResource object has to be deleted. But I am not able to find where/when the destructor of correspoding senderResource is called when corresponding Endpoint(reader/writer) is removed.

The vector inside RTPSParticipantImpl which has all senderResources is erased at the destruction of RTPSParticipantImpl only, which should not be the case. The entries should be removed on deletion of endpoint as well. Kindly clarify my understanding.

Code Link: https://github.com/eProsima/Fast-RTPS... https://github.com/eProsima/Fast-RTPS...

Please let me know if further information is required.

edit retag flag offensive close merge delete

Comments

Can you please update your question with more information (such as source code, what packages you're using, etc.)? It is not clear at all (to me) what you're talking about. Acronyms (RTPS) may be clear to you, but not to everyone else. As is, I can't tell if this is a ROS question or not.

jayess gravatar image jayess  ( 2017-12-29 02:05:03 -0500 )edit

The references to RTPS and Participant seem to indicate that this is a ROS2 related question.

@glkhobragade: please do what @jayess asks and make your question more of a question: add some context, perhaps some links to pieces of code, etc. As it is, this has little value.

gvdhoorn gravatar image gvdhoorn  ( 2017-12-29 07:00:20 -0500 )edit

I have refactored the code as @jayess mentioned. Kindly let me know if further info is required. Also this doubt is mostly related to Fast-RTPS layer, so is this the right forum to ask this question here. I thought ROS is supporting fast-rtps as default DDS implementation, so its find to clarifyhere

glkhobragade gravatar image glkhobragade  ( 2017-12-29 08:10:16 -0500 )edit

If this is all about fast-rtps, you should really ask this on their issue tracker / forum.

For ROS2, fast-rtps is one of the supported middlewares, but this forum is for ROS-specific questions, not for eProsima product support.

gvdhoorn gravatar image gvdhoorn  ( 2017-12-29 08:15:13 -0500 )edit

ok, thank you.

glkhobragade gravatar image glkhobragade  ( 2017-12-29 08:16:36 -0500 )edit

@gvdhoom, are you aware of such forum for fast-rtps like ros2.

glkhobragade gravatar image glkhobragade  ( 2017-12-29 08:17:29 -0500 )edit

No, I'm not aware of a forum for fast-rtps.

I would just try to post to the issue tracker they have on their Github repositories.

gvdhoorn gravatar image gvdhoorn  ( 2017-12-29 08:39:11 -0500 )edit