5.2.5. Reliability Protocol and Wire Representation

5.2.5.1. [Critical] Unexpected data loss when using batching and finite reader resource limits

Consider the following scenario:

  • A DataWriter enables batching.

  • A reliable, keep-all history DataReader sets its resource_limits.max_samples to a finite value. For example, max_samples = 4.

  • The DataWriter writes enough batches to exceed the resource_limits.max_samples, but the DataReader initially fails to receive one of them. For example, the reader receives batch sequence numbers 1, 3, 4, 5, and then batch sequence number 2 gets repaired.

  • The application using the DataReader does not call take() to remove any of the received samples from the reader queue.

For the simplicity of this example, let’s also assume that there is only one sample per batch.

The problem was that the DataReader would never deliver batches 2 through 4 to the user application. After fixing the problem, the DataReader now delivers batches 1 through 4 to the user application.

[RTI Issue ID CORE-16005]