Hello All,
I am trying to use the UserData QoS Policy of DataReader.
For that I have done the following changes:
1) Creation of Subscriber and DataReader of DDS_Builtintopic_Subscription type (Topic name is "DCPSSubscription")
2) Using the Example Builtin topics application for Subcribing to this "DCPSSubscription" topic
3) When a DataReader is created in the domain, I am able to receive the notification that a node has joined.
4) When a DatReader is Deleted in the daomain, I am able to receive the notification that a node has been stopped.
Ques: I have a system with two builtintopics Reader running within a domain.
I am able to receive the notification of joining and stopping the node in both these Builtintopic subscriber, but not able to receive the updated userData Qos on both. When a DataReader changes its QoS policy i.e userdata values, than the updated qos should also be broacasted and other builtintopic Subscrober should receive that updated userdata.
Any help in this will be highly Appreciated.
Hi Ajmal,
So, how are you changing/setting the UserData QoS on the datareader?
Hi Howard,
Thanks for responding to my post.
How big is the user data that you're trying to set/send? The default length is 256 bytes.
Also, if you used the Builtin Topic example from community.rti.com as the basis for your own code to subscribe to the builtin topics, you need to change the datareader() take to take ANY_VIEW_STATE...it's currently only going to provide samples of data of newly created datareaders/writers/participants
change
retcode = builtin_reader->take(
data_seq,
info_seq,
DDS_LENGTH_UNLIMITED,
DDS_ANY_SAMPLE_STATE,
DDS_NEW_VIEW_STATE,
DDS_ANY_INSTANCE_STATE);
to
retcode = builtin_reader->take(
data_seq,
info_seq,
DDS_LENGTH_UNLIMITED,
DDS_ANY_SAMPLE_STATE,
DDS_ANY_VIEW_STATE,
DDS_ANY_INSTANCE_STATE);