Skip to content

Commit

Permalink
Only storing received changes in WriterProxy [6159] (#646)
Browse files Browse the repository at this point in the history
* Refs #6114. Only storing sequence numbers of received changes.

* Refs #6114. Using history attributes to configure pool allocator.

* Refs #6114. Temporally disabling WriterProxyTests

* Refs #6114. Fixing failing tests.

* Refs #6114. Fixing failing tests.

* Refs #6159. Addressing review comments.

* Refs #6159. Addressing assertions by making load_from_storage private.

* Refs #6159 Adding writer proxy tests + fix for writer proxy

* Refs #6159. Update test that fail.

* Refs #6159. Fixed failing tests.

* Updated comparisson for SequenceNumberSet_t and comments on standard's faithfulness
  • Loading branch information
MiguelCompany authored and raquelalvarezbanos committed Aug 6, 2019
1 parent 67fd2e8 commit b0c375e
Show file tree
Hide file tree
Showing 5 changed files with 755 additions and 520 deletions.
18 changes: 4 additions & 14 deletions src/cpp/rtps/reader/StatefulReader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -88,17 +88,6 @@ StatefulReader::StatefulReader(
#endif
)
{
// Update resource limits on proxy changes set adding 256 possibly missing changes
proxy_changes_config_.initial += 256u;
if (proxy_changes_config_.increment == 0)
{
proxy_changes_config_.maximum += 256u;
}
else
{
proxy_changes_config_.maximum = std::max(proxy_changes_config_.maximum, proxy_changes_config_.initial);
}

const RTPSParticipantAttributes& part_att = pimpl->getRTPSParticipantAttributes();
for (size_t n = 0; n < att.matched_writers_allocation.initial; ++n)
{
Expand Down Expand Up @@ -156,19 +145,20 @@ bool StatefulReader::matched_writer_add(
matched_writers_pool_.pop_back();
}

wp->start(wdata);

for (const Locator_t& locator : wp->remote_locators_shrinked())
{
getRTPSParticipant()->createSenderResources(locator);
}

SequenceNumber_t initial_sequence;
if (persist)
{
add_persistence_guid(wdata.guid(), wdata.persistence_guid());
wp->loaded_from_storage(get_last_notified(wdata.guid()));
initial_sequence = get_last_notified(wdata.guid());
}

wp->start(wdata, initial_sequence);

matched_writers_.push_back(wp);

if (liveliness_lease_duration_ < c_TimeInfinite)
Expand Down
Loading

0 comments on commit b0c375e

Please sign in to comment.