I have a few questions on some things I've come across during some development:
- Is there a way to speed up how long it takes for readers and writers to "release"? I currently have a couple dozen parallel loops running to on a NI Linux x64 real time target, and it takes close to a minute or two for all of the readers and writers to release. A couple things i have tried:
- Before starting any readers and writers, we use the0 "Set Configuration Parmeters.vi" to set the "Timeout to Delete Inactive..." to 0.
- After all of the readers and writers have been closed, I run "DDS Release Unused Entities.vi.
Are the Release Writer.vi or Release Reader.vi able to be made re-entrant (pre-allocated or shared clones)? It looks like it's default state is non-reentrant and that is unable to be edited due to password protection.
2. We are using rings to represent enums as we have some sparsely populated enums. Those work fine. Our writers are conected directly to the outports of simulink models. If one of those simulink models outputs an invalid enum value (e.g. 0 as that is a common default value to write out before the models put valid data out), the writer crashes hard. I tried to put some error handling in there to clear the error and try again, but it looks like as soon as you give it an invalid value, the reference to the writer goes away and it causes a hard crash of labview. Is there a better way to be handling an invalid enum value that would still allow use to report an error, but not cause the writer to completely crash and lose it's reference?
Hello,
1. About the Release Writers/Readers, the "Timeout to Delete Inactive..." set to 0 means that a DDS DataWriter and DataReader will be deleted at the moment that you call the "release' subVI. This may increase the release time of your application as you are deleting each DDS entity individually. About reentrancy, the problem is that there are several resources shared across different entities and therefore, we need to remove these entities sequentially.
Something that you can try is to set the "Timeout to Delete Inactive Entities" to 10 seconds (default). Then after all release subVIs are called, wait 10 seconds and call remove unused entities subVI. Please let me know if this makes any difference.
2. About the second point with the rings, let me know if I understand it correctly:
Is this scenario correct?
If it is, something that comes to my mind to mitigate these crashes is to add a new element to the enums with value 0 that means ERROR. Is this possible in your case?