Unique ID PreviousNext
Data Distribution Service (DDS) Forum > DDS Technical Forum >
Next message dddddd  posted on Wednesday, April 02, 2008 - 09:04 am
Hi all,

This may sound too elemantary for you guys but, I would like to know if there is a built-in ID for every DDS topic by which one can identify the entity uniquely. I came across to get_instance_handle but could not be sure of it since I am a newbie.

Next message Niels Kortstee  posted on Wednesday, April 02, 2008 - 09:23 am
A Topic is identified by its name, which must be unique in the whole Domain.

Cheers, Niels
Next message Erik Hendriks  posted on Wednesday, April 02, 2008 - 09:33 am
Every topic created in a DDS Domain is represented by a so called builtin-topic, that describes its name, its datatype, its Qos settings and some other stuff. The keyfields of this builtin-topic sample are guaranteed to be unique in your DDS Domain.

These builtin topic samples can be accessed using the DCPSTopicDataReader in the builtin Subscriber. Every sample accessed this way is accompanied by an instance_handle that makes that sample unique within that specific DCPSTopicDataReader. The handle can only be used in the context of that specific DataReader instance, and has no meaning in another DCPSTopicDataReader instance.

The handle you receive when invoking the get_instance_handle() operation on the Topic object is the instance_handle that corresponds to the builtin topic sample that describes the state of that Topic object within the DCPSTopicDataReader of your builtin Subscriber. The instance_handle you receive that way is therefore only unique within your builtin Subscriber and thus your own DomainParticipant: not within the rest of the Domain. However, the keyfields in your builtin topic sample are unique throughout the entire Domain.

Next message dddddd  posted on Wednesday, April 02, 2008 - 09:33 am
Sorry, I asked the wrong question. I wonder if every INSTANCE is uniquely identified, not if a topic is identified uniquely.
Next message Erik Hendriks  posted on Wednesday, April 02, 2008 - 09:51 am
Just to avoid confusion over terminology in the rest of the discussion:

- A Topic is a combination of datatype (e.g. an IDL struct with a keylist definition) with a QoS setting that is identified by a unique name (the topic name).

- An instance is an instantiation of the datatype that is uniquely identified by the values of its keyfields.

Next message Hans van 't Hag  posted on Tuesday, April 08, 2008 - 12:01 pm
so the answer to the question would be YES: a topic-instance is uniquely identified by the value of its key-field(s)
Next message Sachin  posted on Friday, December 11, 2009 - 07:52 pm
Hi Hans,
can you please explain me how exactly we will combine the received topics in our application to make a complete structure for our use.The problem is that the topics that are going to be used to make complete structure will be received at different time and in different methods(say listener)?
How will i come to know that my structure is completely filled i.e. all topics have been copied to structure?

Back to top
Add Your Message Here
Username: Posting Information:
This is a private posting area. Only registered users and moderators may post messages here.
Options: Post as "Anonymous"
Enable HTML code in message
Automatically activate URLs in message