OpenSplice ISO C++ 2 DCPS  v6.x
ISO C++ 2 OpenSplice Data Distribution Service Data-Centric Publish-Subscribe API
org::opensplice::core::policy::InvalidSampleVisibility Struct Reference

#include "ProprietaryApi.hpp"

Public Types

enum  Type { NO_INVALID_SAMPLES, MINIMUM_INVALID_SAMPLES, ALL_INVALID_SAMPLES }
 

Detailed Description

A normal dispose results in an event. There is no sample accompinying the event.

Although on the receiver side the event is processed correctly and the instance state is modified accordingly, there is still a problem representing the event since there is no valid sample accompanying it. That is why an event will always try to piggyback on valid samples that still happen to be around in the reader.

This InvalidSampleVisibility policy (proprietary part of the dds::core::policy::ReaderDataLifecycle) is used to decide what to do when the instance in question has no valid sample to piggyback the event.

Definition at line 632 of file ProprietaryApi.hpp.

Member Enumeration Documentation

◆ Type

Enumerator
NO_INVALID_SAMPLES 

In this case the event is lost, since there is no valid sample to piggyback on, and no invalid samples may be created to accompany the event.

MINIMUM_INVALID_SAMPLES 

This is the default setting. In this case one (and only one) invalid sample is created to piggyback all pending events on. The sample is only displayed once, and is then discarded. So even when you perform a read operation, the invalid sample will be consumed as soon as it is accessed.

ALL_INVALID_SAMPLES 

This is a new setting that we have envisaged, but not yet implemented. Currently it will throw an UnsupportedError. The idea is that when implemented, every event is represented by its own invalid sample. Keep in mind that invalid samples have no real content, and therefore do not consume resource limits. That means a KEEP_LAST reader with depth 1 can contain 1 valid sample and any number of pending events. This allows you to see each event separately and removes the need to maintain administration for the last known dispose_count. Also since every event will have its own accompanying sample (even in case there are still valid samples around), each event will have a NOT_READ sample state which makes it easy to intercept with a single ReadCondition for NOT_READ data.

Definition at line 634 of file ProprietaryApi.hpp.


The documentation for this struct was generated from the following file: