You have two options for how to access data that a DataReader receives.
You should never block in a listener callback. There are many negative consequences of blocking in a listener callback:
When using a WaitSet, you can be notified of new data arriving two ways:
An application has multiple ways to be notified about data becoming available in a DataReader, depending on the application’s requirements - between these options, WaitSets are the safest.
This website uses cookies in order to optimize your browsing experience, better meet your needs, and perform analytical tasks.