RTI Connext Java API  Version 5.0.0
LifespanQosPolicy Class Reference

Specifies how long the data written by the com.rti.dds.publication.DataWriter is considered valid. More...

Inheritance diagram for LifespanQosPolicy:
QosPolicy

Public Attributes

final Duration_t duration
 Maximum duration for the data's validity.
 
- Public Attributes inherited from QosPolicy
final QosPolicyId_t id
 The ID of this QoS policy.
 
final String policy_name
 The name of this QoS policy.
 

Additional Inherited Members

- Public Member Functions inherited from Struct
abstract boolean equals (Object obj)
 
abstract int hashCode ()
 
String toString ()
 
- Protected Member Functions inherited from Struct
 Struct ()
 
abstract void pull_from_nativeI (long native_status)
 
abstract void push_to_nativeI (long native_status)
 

Detailed Description

Specifies how long the data written by the com.rti.dds.publication.DataWriter is considered valid.

Each data sample written by the com.rti.dds.publication.DataWriter has an associated expiration time beyond which the data should not be delivered to any application. Once the sample expires, the data will be removed from the com.rti.dds.subscription.DataReader caches as well as from the transient and persistent information caches.

The expiration time of each sample from the com.rti.dds.publication.DataWriter's cache is computed by adding the duration specified by this QoS policy to the sample's source timestamp. The expiration time of each sample from the com.rti.dds.subscription.DataReader's cache is computed by adding the duration to the reception timestamp.

See Also
com.rti.ndds.example.FooDataWriter.write
com.rti.ndds.example.FooDataWriter.write_w_timestamp
Entity:
com.rti.dds.topic.Topic, com.rti.dds.publication.DataWriter
Properties:
RxO = N/A
Changeable = YES

Usage

The Lifespan QoS policy can be used to control how much data is stored by RTI Connext. Even if it is configured to store "all" of the data sent or received for a topic (see com.rti.dds.infrastructure.HistoryQosPolicy), the total amount of data it stores may be limited by this QoS policy.

You may also use this QoS policy to ensure that applications do not receive or act on data, commands or messages that are too old and have 'expired.'

To avoid inconsistencies, multiple writers of the same instance should have the same lifespan.

See Also
com.rti.dds.subscription.SampleInfo.source_timestamp
com.rti.dds.subscription.SampleInfo.reception_timestamp

Member Data Documentation

final Duration_t duration

Maximum duration for the data's validity.

[default] com.rti.dds.infrastructure.Duration_t.INFINITE

[range] [1 nanosec, 1 year] or com.rti.dds.infrastructure.Duration_t.INFINITE


RTI Connext Java API Version 5.0.0 Copyright © Thu Aug 30 2012 Real-Time Innovations, Inc