Skip to content
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

Set pub cache queryable as complete #114

Merged
merged 1 commit into from
Feb 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 3 additions & 5 deletions rmw_zenoh_cpp/src/rmw_zenoh.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -561,6 +561,7 @@ rmw_create_publisher(
if (publisher_data->adapted_qos_profile.durability == RMW_QOS_POLICY_DURABILITY_TRANSIENT_LOCAL) {
ze_publication_cache_options_t pub_cache_opts = ze_publication_cache_options_default();
pub_cache_opts.history = publisher_data->adapted_qos_profile.depth;
pub_cache_opts.queryable_complete = true;
publisher_data->pub_cache = ze_declare_publication_cache(
z_loan(context_impl->session),
z_loan(keyexpr),
Expand Down Expand Up @@ -1289,11 +1290,8 @@ rmw_create_subscription(

if (sub_data->adapted_qos_profile.durability == RMW_QOS_POLICY_DURABILITY_TRANSIENT_LOCAL) {
ze_querying_subscriber_options_t sub_options = ze_querying_subscriber_options_default();
// TODO(Yadunund): We need the query_target to be ALL_COMPLETE but the PubCache created
// does not setup a queryable that is complete. Once zettascale exposes that API,
// uncomment below.
// sub_options.query_target = Z_QUERY_TARGET_ALL_COMPLETE;
sub_options.query_target = Z_QUERY_TARGET_ALL;
// Target all complete publication caches which are queryables.
sub_options.query_target = Z_QUERY_TARGET_ALL_COMPLETE;
// We set consolidation to none as we need to receive transient local messages
// from a number of publishers. Eg: To receive TF data published over /tf_static
// by various publishers.
Expand Down
3 changes: 2 additions & 1 deletion zenoh_c_vendor/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,10 @@ find_package(ament_cmake_vendor_package REQUIRED)
# when expanded.
set(ZENOHC_CARGO_FLAGS "--no-default-features$<SEMICOLON>--features=zenoh/transport_tcp zenoh/shared-memory")

# Set VCS_VERSION to include changes from https://github.com/eclipse-zenoh/zenoh-c/pull/243.
ament_vendor(zenoh_c_vendor
VCS_URL https://github.com/eclipse-zenoh/zenoh-c.git
VCS_VERSION 0.10.1-rc
VCS_VERSION de57b3fed5b1c3f4a83a2c0c0cb6a642c09a6210
CMAKE_ARGS
"-DZENOHC_CARGO_FLAGS=${ZENOHC_CARGO_FLAGS}"
)
Expand Down
Loading