-
Notifications
You must be signed in to change notification settings - Fork 791
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bugfix/intraprocess datasharing [10845] #1817
Conversation
4630dc7
to
3df6020
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Apart from my comments below:
- Fix uncrustify
- There are some tests failing that I think should be related with the changes on this PR.
- Message
[RTPS_READER_HISTORY Error] The Writer GUID_t must be defined -> Function eprosima::fastrtps::rtps::ReaderHistory::add_change
on Windowsthroughput.performance.throughput.interprocess_best_effort_shm.data_loans_and_sharing
is at least suspicious. It is also givingThroughputTest: ../../../../src/fastrtps/src/cpp/rtps/history/TopicPayloadPool.cpp:97: virtual bool eprosima::fastrtps::rtps::TopicPayloadPool::get_payload(eprosima::fastrtps::rtps::SerializedPayload_t&, eprosima::fastrtps::rtps::IPayloadPool*&, eprosima::fastrtps::rtps::CacheChange_t&): Assertion
cache_change.writerGUID != GUID_t::unknown()' failed.` on other platforms. PubSubHistory.PubSubAsReliableMultithreadKeepLast1.Datasharing
is sending 300 samples, perhaps we need more buffer in the case of DataSharingPersistenceLargeData.PubSubAsReliablePubPersistentWithFrag.Datasharing
seems to have returned samples in the wrong order.
- Message
3df6020
to
49407c0
Compare
The traces on the failing I run the test locally 1000 times without fails. Let's wait for the CI run again. |
714470e
to
b1cf2d2
Compare
4743664
to
562e58a
Compare
…hed writer Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
…veries Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
…veries Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
…able Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
This corrects the regression on DataReaderTests.resource_limits Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
- Make the sequence number atomic, as it signals the validity or invalidation of the payload - Clear the sequence number first when invalidating, set it last when publishing - Reset the pointer fields on the CacheChange when the pool returns no valid data to the listener. Since the listener provides a stack-allocated CacheChange for the pool to fill, if the return is garbage, the destructor of the CacheChange will do unexpected things Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
ed06a0b
to
cce8358
Compare
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
cce8358
to
4fa23f0
Compare
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Please fix uncrustify.
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please fix warnings
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
This is a port of #1817 from <main> to <2.2.x> * Refs 10731. DataSharingListener provides access to the pool of a matched writer Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. The writer prioritizes intraprocess over datasharing deliveries Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. The reader prioritizes intraprocess over datasharing deliveries Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Payloads not in the history of writer are considered reusable Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Move override check on the reader to ReadTakeCommand Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Remove override check on best effort Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Check deserialization errors on reader Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Avoid lock on writer when getting payload Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Test deserialization errors Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Adapt DataSharing tests to new implementation Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Remove reusability notifications to writer Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Improve check of data validity on reader Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Modify test to new behavior Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. fixup remove override check on RTPS Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. fix mocks Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. uncrustify Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Suggested changes Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Keep datasharing compatibility on the writer info Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. No error when requested loan size is zero This corrects the regression on DataReaderTests.resource_limits Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Apply suggestions Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Atomic sequence number on datasharing node - Make the sequence number atomic, as it signals the validity or invalidation of the payload - Clear the sequence number first when invalidating, set it last when publishing - Reset the pointer fields on the CacheChange when the pool returns no valid data to the listener. Since the listener provides a stack-allocated CacheChange for the pool to fill, if the return is garbage, the destructor of the CacheChange will do unexpected things Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Protect the notification with the mutex Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Catch deserialization exceptions Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Make sure linters do not complain of void returns Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Uncrustify Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Remove unused argument Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
This is a port of #1817 from <main> to <2.2.x> * Refs 10731. DataSharingListener provides access to the pool of a matched writer Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. The writer prioritizes intraprocess over datasharing deliveries Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. The reader prioritizes intraprocess over datasharing deliveries Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Payloads not in the history of writer are considered reusable Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Move override check on the reader to ReadTakeCommand Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Remove override check on best effort Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Check deserialization errors on reader Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Avoid lock on writer when getting payload Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Test deserialization errors Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Adapt DataSharing tests to new implementation Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Remove reusability notifications to writer Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Improve check of data validity on reader Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Modify test to new behavior Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. fixup remove override check on RTPS Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. fix mocks Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. uncrustify Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Suggested changes Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Keep datasharing compatibility on the writer info Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. No error when requested loan size is zero This corrects the regression on DataReaderTests.resource_limits Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Apply suggestions Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Atomic sequence number on datasharing node - Make the sequence number atomic, as it signals the validity or invalidation of the payload - Clear the sequence number first when invalidating, set it last when publishing - Reset the pointer fields on the CacheChange when the pool returns no valid data to the listener. Since the listener provides a stack-allocated CacheChange for the pool to fill, if the return is garbage, the destructor of the CacheChange will do unexpected things Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Protect the notification with the mutex Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Catch deserialization exceptions Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Make sure linters do not complain of void returns Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Uncrustify Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Remove unused argument Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
This is a port of #1817 from <main> to <2.2.x> * Refs 10731. DataSharingListener provides access to the pool of a matched writer Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. The writer prioritizes intraprocess over datasharing deliveries Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. The reader prioritizes intraprocess over datasharing deliveries Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Payloads not in the history of writer are considered reusable Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Move override check on the reader to ReadTakeCommand Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Remove override check on best effort Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Check deserialization errors on reader Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Avoid lock on writer when getting payload Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Test deserialization errors Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Adapt DataSharing tests to new implementation Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Remove reusability notifications to writer Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Improve check of data validity on reader Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Modify test to new behavior Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. fixup remove override check on RTPS Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. fix mocks Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. uncrustify Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Suggested changes Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Keep datasharing compatibility on the writer info Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. No error when requested loan size is zero This corrects the regression on DataReaderTests.resource_limits Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Apply suggestions Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Atomic sequence number on datasharing node - Make the sequence number atomic, as it signals the validity or invalidation of the payload - Clear the sequence number first when invalidating, set it last when publishing - Reset the pointer fields on the CacheChange when the pool returns no valid data to the listener. Since the listener provides a stack-allocated CacheChange for the pool to fill, if the return is garbage, the destructor of the CacheChange will do unexpected things Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Protect the notification with the mutex Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Catch deserialization exceptions Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Make sure linters do not complain of void returns Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Uncrustify Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 10731. Remove unused argument Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
This pull request solves the issues found when intraprocess and datasharing are mixed.