![]() |
OpenSplice Java 5 DCPS
v6.x
OpenSplice Java 5 OpenSplice Data Distribution Service Data-Centric Publish-Subscribe API
|
Specifies the behavior of the org.omg.dds.sub.DataReader with regards to the life cycle of the data instances it manages. More...
Public Member Functions | |
Duration | getAutoPurgeDisposedSamplesDelay () |
Duration | getAutoPurgeNoWriterSamplesDelay () |
ServiceEnvironment | getEnvironment () |
ReaderDataLifecycle | withAutoPurgeDisposedSamplesDelay (Duration autoPurgeDisposedSamplesDelay) |
Copy this policy and override the value of the property. More... | |
ReaderDataLifecycle | withAutoPurgeDisposedSamplesDelay (long autoPurgeDisposedSamplesDelay, TimeUnit unit) |
Copy this policy and override the value of the property. More... | |
ReaderDataLifecycle | withAutoPurgeNoWriterSamplesDelay (Duration autoPurgeNoWriterSamplesDelay) |
Copy this policy and override the value of the property. More... | |
ReaderDataLifecycle | withAutoPurgeNoWriterSamplesDelay (long autoPurgeNoWriterSamplesDelay, TimeUnit unit) |
Copy this policy and override the value of the property. More... | |
Specifies the behavior of the org.omg.dds.sub.DataReader with regards to the life cycle of the data instances it manages.
Concerns: org.omg.dds.sub.DataReader
RxO: N/A
Changeable: Yes
This policy controls the behavior of the DataReader with regards to the lifecycle of the data instances it manages, that is, the data instance that have been received and for which the DataReader maintains some internal resources.
The DataReader internally maintains the samples that have not been taken by the application, subject to the constraints imposed by other QoS policies such as org.omg.dds.core.policy.History and org.omg.dds.core.policy.ResourceLimits.
The DataReader also maintains information regarding the identity, org.omg.dds.sub.ViewState and org.omg.dds.sub.InstanceState of data instances even after all samples have been 'taken.' This is needed to properly compute the states when future samples arrive.
Under normal circumstances the DataReader can only reclaim all resources for instances for which there are no writers and for which all samples have been 'taken.' The last sample the DataReader will have taken for that instance will have an instance state of either org.omg.dds.sub.InstanceState#NOT_ALIVE_NO_WRITERS or org.omg.dds.sub.InstanceState#NOT_ALIVE_DISPOSED depending on whether the last writer that had ownership of the instance disposed it or not. In the absence of the READER_DATA_LIFECYCLE QoS this behavior could cause problems if the application "forgets" to 'take' those samples. The 'untaken' samples will prevent the DataReader from reclaiming the resources and they would remain in the DataReader indefinitely.
The autoPurgeNoWriterSamplesDelay defines the maximum duration for which the DataReader will maintain information regarding an instance once its instance state becomes NOT_ALIVE_NO_WRITERS. After this time elapses, the DataReader will purge all internal information regarding the instance; any untaken samples will also be lost.
The autoPurgeDisposedSamplesDelay defines the maximum duration for which the DataReader will maintain samples for an instance once its instance state becomes NOT_ALIVE_DISPOSED. After this time elapses, the DataReader will purge all samples for the instance.
Definition at line 77 of file ReaderDataLifecycle.java.
Duration org.omg.dds.core.policy.ReaderDataLifecycle.getAutoPurgeDisposedSamplesDelay | ( | ) |
Implemented in org.opensplice.dds.core.policy.ReaderDataLifecycleImpl.
Duration org.omg.dds.core.policy.ReaderDataLifecycle.getAutoPurgeNoWriterSamplesDelay | ( | ) |
Implemented in org.opensplice.dds.core.policy.ReaderDataLifecycleImpl.
|
inherited |
Implemented in org.omg.dds.core.ServiceEnvironment, org.opensplice.dds.sub.ReflectionDataReader< TYPE, OUT_TYPE >, org.opensplice.dds.core.ModifiableTimeImpl, org.opensplice.dds.pub.ReflectionDataWriter< TYPE >, org.opensplice.dds.core.DurationImpl, org.opensplice.dds.topic.ContentFilteredTopicImpl< TYPE >, org.opensplice.dds.sub.ReadConditionImpl< TYPE >, org.opensplice.dds.core.EntityQosImpl< T extends QosPolicy >, org.opensplice.dds.type.TypeSupportImpl< TYPE >, org.opensplice.dds.topic.PublicationBuiltinTopicDataImpl, org.opensplice.dds.topic.SubscriptionBuiltinTopicDataImpl, org.opensplice.dds.topic.TopicBuiltinTopicDataImpl, org.opensplice.dds.domain.DomainParticipantFactoryImpl, org.opensplice.dds.core.QosProviderImpl, org.opensplice.dds.core.status.OfferedIncompatibleQosStatusImpl, org.opensplice.dds.core.status.RequestedIncompatibleQosStatusImpl, org.opensplice.dds.core.InstanceHandleImpl, org.opensplice.dds.core.StatusConditionImpl< T extends Entity<?, ?>, org.opensplice.dds.core.status.LivelinessChangedStatusImpl, org.opensplice.dds.core.status.PublicationMatchedStatusImpl, org.opensplice.dds.core.status.SubscriptionMatchedStatusImpl, org.opensplice.dds.sub.SampleImpl< TYPE >, org.opensplice.dds.core.policy.ShareImpl, org.opensplice.dds.core.status.OfferedDeadlineMissedStatusImpl, org.opensplice.dds.core.status.SampleRejectedStatusImpl, org.opensplice.dds.core.WaitSetImpl, org.opensplice.dds.topic.ParticipantBuiltinTopicDataImpl, org.opensplice.dds.core.status.RequestedDeadlineMissedStatusImpl, org.opensplice.dds.topic.BuiltinTopicKeyImpl, org.opensplice.dds.core.GuardConditionImpl, org.opensplice.dds.core.event.AllDataDisposedEventImpl< TYPE >, org.opensplice.dds.core.policy.QosPolicyCountImpl, org.opensplice.dds.core.status.InconsistentTopicStatusImpl, org.opensplice.dds.core.status.LivelinessLostStatusImpl, org.opensplice.dds.core.status.SampleLostStatusImpl, org.opensplice.dds.core.policy.QosPolicyImpl, org.opensplice.dds.core.status.AllDataDisposedStatusImpl, org.opensplice.dds.core.IllegalArgumentExceptionImpl, org.opensplice.dds.core.InconsistentPolicyExceptionImpl, org.opensplice.dds.core.policy.PolicyFactoryImpl, org.opensplice.dds.core.policy.TypeConsistencyEnforcementImpl, org.opensplice.dds.core.PreconditionNotMetExceptionImpl, org.opensplice.dds.core.AlreadyClosedExceptionImpl, org.opensplice.dds.core.IllegalOperationExceptionImpl, org.opensplice.dds.core.ImmutablePolicyExceptionImpl, org.opensplice.dds.core.NotEnabledExceptionImpl, org.opensplice.dds.core.OutOfResourcesExceptionImpl, org.opensplice.dds.core.DDSExceptionImpl, org.opensplice.dds.core.status.DataAvailableStatusImpl, and org.opensplice.dds.core.status.DataOnReadersStatusImpl.
ReaderDataLifecycle org.omg.dds.core.policy.ReaderDataLifecycle.withAutoPurgeDisposedSamplesDelay | ( | Duration | autoPurgeDisposedSamplesDelay | ) |
Copy this policy and override the value of the property.
autoPurgeDisposedSamplesDelay | Specifies a duration autoPurgeDisposedSamplesDelay for which the DataReader will maintain information regarding a data instance for which the instance_state becomes NOT_ALIVE_DISPOSED. By default the duration value is DURATION_INFINITE. When the delay time has expired, the data instance is marked so that it can be purged in the next garbage collection sweep. |
Implemented in org.opensplice.dds.core.policy.ReaderDataLifecycleImpl.
ReaderDataLifecycle org.omg.dds.core.policy.ReaderDataLifecycle.withAutoPurgeDisposedSamplesDelay | ( | long | autoPurgeDisposedSamplesDelay, |
TimeUnit | unit | ||
) |
Copy this policy and override the value of the property.
autoPurgeDisposedSamplesDelay | Specifies a long autoPurgeDisposedSamplesDelay for which the DataReader will maintain information regarding a data instance for which the instance_state becomes NOT_ALIVE_DISPOSED. By default the duration value is DURATION_INFINITE. When the delay time has expired, the data instance is marked so that it can be purged in the next garbage collection sweep. |
unit | The TimeUnit which the period describes (i.e. TimeUnit.SECONDS or TimeUnit.MILLISECONDS) |
Implemented in org.opensplice.dds.core.policy.ReaderDataLifecycleImpl.
ReaderDataLifecycle org.omg.dds.core.policy.ReaderDataLifecycle.withAutoPurgeNoWriterSamplesDelay | ( | Duration | autoPurgeNoWriterSamplesDelay | ) |
Copy this policy and override the value of the property.
autoPurgeNoWriterSamplesDelay | Specifies the duration for which the DataReader will maintain information regarding a data instance for which the instance_state becomes NOT_ALIVE_NO_WRITERS. By default the duration value is DURATION_INFINITE. When the delay time has expired, the data instance is marked so that it can be purged in the next garbage collection sweep. |
Implemented in org.opensplice.dds.core.policy.ReaderDataLifecycleImpl.
ReaderDataLifecycle org.omg.dds.core.policy.ReaderDataLifecycle.withAutoPurgeNoWriterSamplesDelay | ( | long | autoPurgeNoWriterSamplesDelay, |
TimeUnit | unit | ||
) |
Copy this policy and override the value of the property.
autoPurgeNoWriterSamplesDelay | Specifies a long autoPurgeNoWriterSamplesDelay for which the DataReader will maintain information regarding a data instance for which the instance_state becomes NOT_ALIVE_NO_WRITERS. By default the duration value is DURATION_INFINITE. When the delay time has expired, the data instance is marked so that it can be purged in the next garbage collection sweep. |
unit | The TimeUnit which the period describes (i.e. TimeUnit.SECONDS or TimeUnit.MILLISECONDS) |
Implemented in org.opensplice.dds.core.policy.ReaderDataLifecycleImpl.