Configure Your QoS Through Profiles

For better reusability and maintenance of your code, design your QoS as sets of reusable profiles instead of tuning each data flow separately.

There are several ways to define and use QoS, and regardless of which one you are using, you can use profiles:

  • If you are using the built-in QoS profiles provided with version 5.1.0 and later, you can use the generic profiles that are provided with the product.  Inherit from the built-in profiles when you need QoS that are specific to a single data flow.
  • If your are defining your own QoS in XML files, when you define a QoS profile, name it after the pattern of data flow, if applicable.  Inherit from generic patterns when you need QoS that are specific to a single data flow.
  • If you are defining your QoS in code, create a structure such as a map that will map between a name of your QoS profile and the values of fields.

The available builtin QoS profiles are in the file BuiltinProfiles.documentationONLY.xml. For the current release, look in your installation's resource/xml directory. For release 5.1.0, this file is in the installation directory under resources/qos_profiles_5.1.0/xml. You can see the 5.1.0 version here. The builtin profiles are documented here for the current release or here for release 5.1.0.   

A few examples of built-in profiles:

   <!-- A QoS profile for reliable streaming data --> 
   <qos_profile name="Pattern.ReliableStreaming" base_name="Generic.KeepLastReliable">
       ...
   </qos_profile> 

   <!-- A QoS profile for data including alarms that are designed as events --> 
   <qos_profile name="Pattern.AlarmEvent" base_name="Pattern.Event"/> 

   <!-- A QoS profile for data including alarms that are designed as state/status data -->
   <qos_profile name="Pattern.AlarmStatus" base_name="Pattern.Status"/> 

An example of defining QoS in your own XML file and inheriting from a base profile:

    <qos_profile name="HighThroughputMulticast" base_name="Generic.StrictReliable.HighThroughput">
        <!-- Only need to set the QoS that overrides the base QoS --> 
        <datareader_qos>
            <multicast>
                <value>
                    <element>
                        <receive_address>239.255.1.2</receive_address>
                    </element>  
                </value>  
            </multicast>  
        </datareader_qos>
    </qos_profile>