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.