Proper way to shutdown RTI Threads (C#)

2 posts / 0 new
Last post
Offline
Last seen: 6 years 7 months ago
Joined: 12/19/2013
Posts: 2
Proper way to shutdown RTI Threads (C#)

Hi, I'm currently working on RTI and until now, I was mainly doing small proof of concepts.

Now I'm trying to implement RTI in a more consequent application, and during my debug sessions I found myself stuck by the fact that some thread keeps running after I stop the debug mode.
This is kind of bothering since, it's impossible de recompile without killing the exe.

So the real question would be:

Is there a way to dispose of RTI for unmanaged application crash (unrelated to RTI)

 

Thanks

Cyril

rose's picture
Offline
Last seen: 1 day 11 hours ago
Joined: 08/22/2011
Posts: 147

Hello Cyril!

Are you able to catch any exceptions before the application crashes, or do any cleanup at all?  If you can catch exceptions, you can call participant.delete_contained_entities() to destroy all DataWriters and DataReaders, and then delete the DomainParticipant to finish deleting its threads.

Thank you,

Rose