Skip to content

Commit

Permalink
Disable data sharing in LatencyTest by default
Browse files Browse the repository at this point in the history
Signed-off-by: Jakub Sosnovec <jakub.sosnovec@nxp.com>
  • Loading branch information
JakubSosnovec committed Apr 14, 2021
1 parent 0bbfe53 commit e3d0b93
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 8 deletions.
12 changes: 8 additions & 4 deletions test/performance/latency/LatencyTestPublisher.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -264,14 +264,18 @@ bool LatencyTestPublisher::init(
dr_qos_.endpoint().history_memory_policy = MemoryManagementPolicy::PREALLOCATED_WITH_REALLOC_MEMORY_MODE;
}

// Set data sharing according with cli. Is disabled by default in all xml profiles
// Set data sharing according with cli.
DataSharingQosPolicy dsp;
if (data_sharing_)
{
DataSharingQosPolicy dsp;
dsp.on("");
dw_qos_.data_sharing(dsp);
dr_qos_.data_sharing(dsp);
}
else
{
dsp.off();
}
dw_qos_.data_sharing(dsp);
dr_qos_.data_sharing(dsp);

// Increase payload pool size to prevent loan failures due to outages
if (data_loans_)
Expand Down
12 changes: 8 additions & 4 deletions test/performance/latency/LatencyTestSubscriber.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -216,14 +216,18 @@ bool LatencyTestSubscriber::init(
dr_qos_.endpoint().history_memory_policy = MemoryManagementPolicy::PREALLOCATED_WITH_REALLOC_MEMORY_MODE;
}

// Set data sharing according with cli. Is disabled by default in all xml profiles
// Set data sharing according with cli.
DataSharingQosPolicy dsp;
if (data_sharing_)
{
DataSharingQosPolicy dsp;
dsp.on("");
dw_qos_.data_sharing(dsp);
dr_qos_.data_sharing(dsp);
}
else
{
dsp.off();
}
dw_qos_.data_sharing(dsp);
dr_qos_.data_sharing(dsp);

// Increase payload pool size to prevent loan failures due to outages
if (data_loans_)
Expand Down

0 comments on commit e3d0b93

Please sign in to comment.