DDS-XRCE	
DDS	for	Extremely	Resource	Contained	Networks	
Dra<	specifica?on	presented	at	OMG	Brussels,	June	2017	
mars/17-06-11	
Joint Submission: RTI, TwinOaks, eProsima
Contact: Gerardo Pardo-Castellote, Ph.D.
Outline	
•  Background	
•  High	Level	Overview	
•  Key	Concepts	and	Features	
•  An	example	
•  Status	
©2017	Real-Time	Innova?ons,	Inc.
Backgrond	
•  Two	ini?al	submissions	in	Chicago,	9/2016	
– Joint	Submission	RTI,	TwinOaks,	eProsima	
– Submission	by	PrismTech	
•  Presenta?ons	in	Reston	focused	on	differences	
– Goal	was	explore	joining	submissions	
•  Joining	Submission	stalled		
– Technical	details	and	documents	a	moving	target	
©2017	Real-Time	Innova?ons,	Inc.
Real-Time	Innova?ons,	Inc.	
High	Level	Overview
Common	approach:	Agent-Based	deployment	model	
XRCE	
Agent	
Global	Data	Space	DDS/	RTPS	
Client	
Client	
Client	
DDS-XRCE	
XRCE	
Agent	
Client	
Client	
Client	
DDS	App	
DDS	App	
DDS	App	
DDS	App	
DDS	App
Agent-Based	deployment	model	
XRCE	
Agent	Client	
XRCE	Protocol	
Global	Data	Space	
DDS/	RTPS	
Exis?ng	DDS	
Interoperability	
Wire	Protocol	
New	protocol	defined	
by	the	DDS-XRCE	
specifica?on	
Resource	Constrained	
Network	
~	40Kbps,	100Byte	MTU	
Resource	Constrained	
Device:	~	100	KB	RAM	
Babery	Powered	
Sleep	Cycles
Formal	specifica?on	of	the	Agent	and	Protocol	
XRCE	
Agent	Client	
XRCE	Protocol	
Global	Data	Space	
DDS/	RTPS	
XRCE	
Protocol	
DDS/RTPS	
Protocol
Formal	specifica?on	of	the	Agent	and	Protocol	
Client	
XRCE	Protocol	
Global	Data	Space	
DDS/	RTPS	
HEADER	 MSG1	 MSG2	
XRCE	Object	Model	
Message	Structure	
+	
Interac=on	Model	
+
Real-Time	Innova?ons,	Inc.	
XRCE	Object	Model
XRCE	Agent	
Object	Model	
class DDS-Mapping
DdsXrce::
DomainParticipant
DdsXrce::Publisher
DdsXrce::Subscriber
DdsXrce::
DataWriter
DdsXrce::DataReader
DdsXrce::Topic
DDS::DomainParticipantFactory
DDS::DomainParticipant
DDS::Publisher
DDS::Subscriber
DDS::TopicDescription
DDS::Topic
DDS::ContentFilteredTopic
DDS::DataReader
DDS::DataWriter
«value»
DdsXrce::Qos
«value»
DdsXrce::
QosProfile
Qos
+ DataReaderQos
+ DataWriterQos
+ DomainParticipantQos
+ PublisherQos
+ SubscriberQos
+ TopicQos
(from DDS)
DdsXrce::Application
«use»
«use»
«use»
«use»
«use»
«use»
«use»
«use»
0..*
«use»
«use»
«use»
XRCE	Object	Model	highlights	
•  Uses	UML	to	model	Agent	behavior	
•  XRCE	Objects	modeled	as	“resources”	
– Addressable	by	their	“name”	
– CRUD	opera?ons:	
•  Create/Read/Update(Write)/Delete	
	
©2017	Real-Time	Innova?ons,	Inc.
©2017	Real-Time	Innova?ons,	Inc.	
class Application
DdsXrce::Application
+ create_participant(): ReturnStatus
+ update_participant(): ReturnStatus
+ delete_participant(): ReturnStatus
+ create_waitset(): ReturnStatus
+ update_waitset(): ReturnStatus
+ delete_waitset(): ReturnStatus
DdsXrce::DomainParticipant
DDS::DomainParticipant
DDS::
DomainParticipantFactory
DdsXrce::AccessController
+ check_permissions(): ReturnStatus
DdsXrce::WaitSet
«value»
DdsXrce::Type
«value»
DdsXrce::
QosProfile
DdsXrce::QosLibrary
«use»
«use»
«use»
«use»
«use»
0..*
«use»
©2017	Real-Time	Innova?ons,	Inc.	
class Participant
DdsXrce::Application
DdsXrce::DomainParticipant
+ register_type(): ReturnStatus
+ unregister_type(): ReturnStatus
+ create_topic(): ReturnStatus
+ update_topic(): ReturnStatus
+ delete_topic(): ReturnStatus
+ create_publisher(): ReturnStatus
+ update_publisher(): ReturnStatus
+ delete_publisher(): ReturnStatus
+ create_subscriber(): ReturnStatus
+ update_subscriber(): ReturnStatus
+ delete_subscriber(): ReturnStatus
+ get_topics(): ReturnStatus
+ get_publishers(): ReturnStatus
+ get_subscribers(): ReturnStatus
DDS::DomainParticipant
DDS::
DomainParticipantFactory
DdsXrce::AccessController
+ check_permissions(): ReturnStatus
DdsXrce::Topic DdsXrce::
Publisher
DdsXrce::
Subscriber
«value»
DdsXrce::Type
DdsXrce::
RegisteredType
«interface»
DdsXrce::Entity
+ name: string
«use»
«use»
0..*
«use»
«use»
«use»
«use»
«use»
typeName
registeredTypeName
©2017	Real-Time	Innova?ons,	Inc.	
class DataWriter
DdsXrce::DataWriter
+ create_instance(): ReturnStatus
+ update_instance(): ReturnStatus
+ delete_instance(): ReturnStatus
+ write(): ReturnStatus
DDS::DataWriter
DdsXrce::
Publisher
DdsXrce::Topic
DDS::Publisher
TopicDescription
DDS::Topic
«interface»
DdsXrce::Entity
+ name: string
«use»
«use»
«use»
©2017	Real-Time	Innova?ons,	Inc.	
class DataReader
DdsXrce::
Subscriber
DdsXrce::DataReader
+ get(): ReturnStatus
DdsXrce::Topic
- registeredTypeName: string
- topicName: string
DDS::
TopicDescription
DDS::Topic
DDS::DataReader
DDS::Subscriber
«interface»
DdsXrce::Entity
+ name: string
«use»
«use»
«use»
«use»
©2017	Real-Time	Innova?ons,	Inc.	
class AccessController
DdsXrce::AccessController
+ check_permissions(): ReturnStatus
«singleton»
DdsXrce::Root
DdsXrce::Application
DdsXrce::
Publisher
DdsXrce::
Subscriber
DdsXrce::
DomainParticipant
DdsXrce::Client
- clientAPIKey: string
0..*
«use»
«use»
«use»
«use»
0..*
0..*
1
0..*
Resource	Names,	Representa?on,	and	ID	
•  Each	resource	has:	
–  A	name	(addresses	it	within	the	Agent)	and	Context	
•  Example	the	type	“ShapeType”	
–  A	representa?on.	Describes	the	resource	
•  Declara?ve	way	to	configure	Agent	resources	
•  Not	expected	to	go	on	the	wire	in	most	cases	
•  Example:	 	
<struct name="ShapeStruct">
<member name="color" type="string"/>
<member name="x" type="int32"/>
<member name="y" type="int32"/>
<member name="shapesize" type="int32"/>
</struct>
–  An	ID.	Provides	(integer)	shortcurt	for	Client	to	reference	XRCE	object/resource	
•  Note:	Mul?ple	representa?ons	possible	
–  Currently	leverages	exis?ng	XML	formats	
•  As	defined	in	various	exis?ng	DDS	specifica?ons	
–  JSON	and	Binary	are	possible	alterna?ves,	if	required	
©2017	Real-Time	Innova?ons,	Inc.
Qos	Representa?on	
•  Expect	pre-defined	profiles	in	Agent	
– Just	send	QosPofile	name	
•  Allow	sending	Qos	using	XML	(or	JSON	format)	
– JSON	could	be	added	
•  Can	configure	complete	set	of	DDS	Qos	policies	
©2017	Real-Time	Innova?ons,	Inc.
Real-Time	Innova?ons,	Inc.	
Message	Structure
Message	Header	+	Submessages			
©2017	Real-Time	Innova?ons,	Inc.	
XRCE	Header	 Submessage	 Submessage	 Submessage	
0 8 16 24 31
+---------------+---------------+---------------+---------------+
| clientKey |
+---------------+---------------+---------------+---------------+
| sessionId | streamId | sequenceNr |
+---------------+-------+-------+---------------+---------------+
0 4 8 16 24 31
+---------------+---------------+---------------+---------------+
| smId | flags | resourceType | submessageLength |
+-------+-------+---------------+---------------+---------------+
| resourceId | count |
+-------+-------+---------------+---------------+---------------+
~ <payload – depends on smId & resourceType > ~
+-------+-------+---------------+---------------+---------------+
XRCE	Header	
Submessage
12	kind	of	Sub	Messages	
©2017	Real-Time	Innova?ons,	Inc.	
class Submessages
DdsXrce::Submessage
DdsXrce::
Submessage::
CREATE
DdsXrce::
Submessage::
GET_INFO
DdsXrce::
Submessage::
DELETE
DdsXrce::
Submessage::
INFO
DdsXrce::
Submessage::
STATUS
DdsXrce::
Submessage::
ACKNACK
DdsXrce::
Submessage::
HEARTBEAT
DdsXrce::Submessage::
SubmessageHeader
- submessageId: byte
- flags: byte
- submessageLength: short
DdsXrce::
Submessage::
DATA
DdsXrce::
Submessage::
FRAGMENT
DdsXrce::
Submessage::
READ_DATA
DdsXrce::
Submessage::
WRITE_DATA
DdsXrce::
Submessage::
RESET
1
Submessage	kinds	
©2017	Real-Time	Innova?ons,	Inc.	
SubmessageId Value Note
CREATE 1 Client to Agent. Specifies resource Name or Representation
GET_INFO 2 Client to Agent.
DELETE 3 Client to Agent.
STATUS 4 Response to CREATE, UPDATE or DELETE.
INFO 5 Response to a GET_INFO. Contains information about an Xrce: Object.
WRITE_DATA 6 Client to Agent. Used to write data using a Xrce::DataWriter.
READ_DATA 7 Client to Agent. Used to read data using a Xrce::DataReader.
DATA 8 Agent to Client in response to a READ_DATA
ACKNACK 9 Bi-directional.
HEARTBEAT 10 Bi-directional.
RESET 11 Agent to Client.
FRAGMENT 12 Bi-directional
Example:	DATA	Message	
©2017	Real-Time	Innova?ons,	Inc.	
0 8 16 24 31
+---------------+---------------+---------------+---------------+
| clientKey |
+---------------+---------------+---------------+---------------+
| sessionId | streamId | sequenceNr |
+---------------+---------------+---------------+---------------+
| DATA | flags | submessageLength |
+-------+-------+---------------+---------------+---------------+
| dataWriterResourceId | count |
+-------+-------+---------------+---------------+---------------+
~ <payload – data [0] ~
~ <payload – data [1] ~
~ <payload – data [count -1] ~
+---------------+-------+-------+---------------+---------------+
Payload	format	
Depends	on	flags	
	
Serializa?on	uses	DDS-
XTYPES	format
Example:	DATA	with	Timestamp	Message	
©2017	Real-Time	Innova?ons,	Inc.	
0 8 16 24 31
+---------------+---------------+---------------+---------------+
| clientKey |
+---------------+---------------+---------------+---------------+
| sessionId | streamId | sequenceNr |
+---------------+---------------+---------------+---------------+
| DATA | flags | submessageLength |
+-------+-------+---------------+---------------+---------------+
| dataWriterResourceId | count |
+-------+-------+---------------+---------------+---------------+
~ <payload – common timestamp> ~
~ <payload – data [0] ~
~ <payload – data [1] ~
~ <payload – data [count -1] ~
+---------------+-------+-------+---------------+---------------+
Example:	DATA	with	Timestamp	Message	
©2017	Real-Time	Innova?ons,	Inc.	
0 8 16 24 31
+---------------+---------------+---------------+---------------+
| clientKey |
+---------------+---------------+---------------+---------------+
| sessionId | streamId | sequenceNr |
+---------------+---------------+---------------+---------------+
| DATA | flags | submessageLength |
+-------+-------+---------------+---------------+---------------+
| dataWriterResourceId | count |
+-------+-------+---------------+---------------+---------------+
~ <payload – timestamp_base> ~
~ <payload – timestamp_offset[0] ~
~ <payload – data [0] ~
~ <payload – timestamp_offset[1] ~
~ <payload – data [1] ~
~ <payload – timestamp_offset[count -1] ~
~ <payload – data [count -1] ~
+---------------+-------+-------+---------------+---------------+
Real-Time	Innova?ons,	Inc.	
Interac?on	Model
©2017	Real-Time	Innova?ons,	Inc.	
sd Client Agent
XRCE AgentXRCE Client
RESOURCE_STATUS(DataWriter)
RESOURCE_STATUS(Session)
ASSERT_RESOURCE(Session)
WRITE_DATA(DataWriter)
WRITE_DATA(DataWriter)
ASSERT_RESOURCE(DataWriter)
DELETE_RESOURCE(DataWriter, Session)
WRITE_DATA(DataWriter)
ASSERT_RESOURCE	iden?fies	(preconfigured)	
resource	by	means	its	Name	and	retrieves	
resourceId	
	
Note:	Using	CREATE	instead	of	
ASSERT_RESOURCE	can	create	the	resource	
from	its	representa?on
©2017	Real-Time	Innova?ons,	Inc.	
sd Minimal Publisher
XRCE Client XRCE Agent
DELETE_RESOURCE()
WRITE_DATA()
ASSERT_RESOURCE(Session)
WRITE_DATA()
RESOURCE_STATUS()
WRITE_DATA()
The	resourceId	for	specific	objects	(e.g.	a	
DataWriter)	can	also	be	pre-configured.	
	
This	saves	having	to	ASSERT	it.
©2017	Real-Time	Innova?ons,	Inc.	
sd Minimal Subscriber
XRCE Client XRCE Agent
DATA()
DATA()
ASSERT_RESOURCE(Session)
DELETE_RESOURCE()
DATA()
CONFIG_READ()
Real-Time	Innova?ons,	Inc.	
Transport	Model
Transport	requirements	
•  Packet-oriented	or	connec?on	oriented	
•  It	does	not	need	to	provide	reliability	
–  Messages	may	be	dropped	
•  It	does	not	need	to	provide	ordering	
–  Messages	may	arrive	out	of	order	
•  It	does	not	need	to	provide	no?fica?on	of	dropped	messages	
•  Must	support	transport-level	security	(e.g.	TLS	or	DTLS)	
©2017	Real-Time	Innova?ons,	Inc.
Reliability	
•  Reliability	per	stream,		mul?ple	(256)	streams	
–  Buil?n	streams	0-5	are	present	on	every	session	
–  Even-numbered	streamIds	are	best-efforts.		
–  Reliable	streams	use	HB/	ACKNACK	protocol	
•  Similar	to	DDS/RTPS	
•  Mul?ple	Writers	can	share	same	stream	as	configured	by	client	
•  Mul?ple	Readers	can	also	share	the	same	stream	
©2017	Real-Time	Innova?ons,	Inc.
Real-Time	Innova?ons,	Inc.	
Security
Security	approach	
•  Assumes	transport-level	security	is	in	place	
•  Message	Header	includes	(4-Byte)	secret	ClientKey	
•  Agent	uses	ClientKey	to	determine	client	permissions	and	
Iden?ty	
– Leverages	DDS-Security	iden?ty	and		permissions	documents	
– Proxy	DDS	DomainPar?cipant	are	exclusive	to	a	single	Client	
©2017	Real-Time	Innova?ons,	Inc.
Real-Time	Innova?ons,	Inc.	
Other
Other	points	
•  Reuses	CDR	(XTYPES)	serializa?on	
•  Serialized	Resource	format	described	in	IDL	
•  Data	serialized	using	CDR.	Data	can	be	relayed	serialized	
•  Supports	fragmenta?on	
•  Supports	mul?ple	concurrent	sessions	
•  Full	“DDS	reachability”	
–  Any	Qos	available	in	DDS	
–  Any	data	type	available	in	DDS-XTYPES		
©2017	Real-Time	Innova?ons,	Inc.
Real-Time	Innova?ons,	Inc.	
RFP	equirements
RFP	mandatory	requirements	
©2017	Real-Time	Innova?ons,	Inc.	
RFP	requirement	 Submission	
DDS-XRCE	protocol	between	a	Client	and	an	Agent	 YES	
DDS-XRCE	clients	to	be	perceived	by	DDS	Par?cipants	as	at	least	
minimum	profile	DDS	Par?cipants	
YES,		the	can	full	DDS	
Par?cipants,	not	limited	to	
minimum	profile	
DDS-XRCE	protocol	overhead,	when	sending	or	receiving	user	data,	shall	
not	exceed	24	bytes	per	packet	
YES,	less	than	20	bytes	
Address	clients	opera?ng	with	sleep/wakeup	periods	 YES,	state	maintained	by	
Agent,	“stateless”	messages	
DDS-XRCE	protocol	for	the	UDP/IP	transport.		
DDS-XRCE	protocol	for	the	TCP/IP	transport	
	
YES,	protocol	is	independent	
from	transport.
Real-Time	Innova?ons,	Inc.	
Path	forward	
Does	it	s?ll	make	sense	to	try	to	merge?
Path	forward	
•  Revised	Submission	in	September	2017	
•  Con?nue	inves?ga?on	of	possible	combined	submission	
	
©2017	Real-Time	Innova?ons,	Inc.

DDS-XRCE (Extremely Resource Constrained Environments)