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

[Draft] ContentFilteredTopic Support #241

Closed
fujitatomoya opened this issue Jun 19, 2020 · 4 comments
Closed

[Draft] ContentFilteredTopic Support #241

fujitatomoya opened this issue Jun 19, 2020 · 4 comments
Assignees

Comments

@fujitatomoya
Copy link
Collaborator

fujitatomoya commented Jun 19, 2020

Feature request

Feature description

Draft overview and background is ros2/design#282,

Introduce dds contentfiltertopic to ROS, dds specification is DDS v1.4 2.2.2.3.3 ContentFilteredTopic Class. ContentFilteredTopic can be created on parent topic and DataReader only receives the messages that matches with filtering expression and expression parameters. If implementation does not support this feature, it returns not support.

  • rmw implementation support.
Implementation Supported Comment
RTI Connext Yes https://community.rti.com/examples/content-filtered-topic, Not sure if filtering is done on writer or reader side.
eProsima Fast-DDS No
ADLINK cyclonedds No
ADLINK OpenSplice Yes E.O.L foxy or newer
  • expected user for this feature.

    • action feedback / status topics.
    • parameter_events topic.
    • user defined topics.

Implementation considerations

  • rmw and rcl implementation
    • ContentFilteredTopic requires parent topic, returning capability for ContentFilteredTopic with rmw_create_subscriotion rmw_subscription_t. So that rclcpp/rcl can tell if the implementation supports it or not.
    • Based on parent topic and subscription, it can create ContentFilteredTopic with subtopic name, filtering expression and expression parameters. Then implementation creates ContentFilteredTopic and replace the DataReader.
    • Expression parameter can be changed via setter dynamically, also getter should be provided. but filtering expression cannot be changed unless re-creating ContentFilteringTopic.
    • Test must be added to make sure ContentFIlteredTopic supported and functions.
  • rcl and rclcpp
    • Action feedback and status to use ContentFilteredTopic.
    • Introduce new class for parameter_events filtering which calls ContentFilteredTopic.
    • Filtering in rcl based when rmw does not support ContentFilteredTopic.
@Barry-Xu-2018
Copy link
Contributor

About implementation estimation.

  1. Implement -- 18 ~ 23 MD

    Module Estimation (man day)
    rmw & rmw_implementation 2
    rmw_connext 5~10
    rcl 4
    rclcpp 3
    rclpy TBD
    rmw_fastrtps, rmw_cyclonedds 4
  2. Integrate and test -- 5 MD

  3. Review and modification -- 5~10 MD

@fujitatomoya
Copy link
Collaborator Author

@Barry-Xu-2018

I think that it would be really nice to break down into some steps, since huge single PR is really heavy work and hard to do review. the following is just idea.

  1. rmw ContentFilteredTopic support
  • is_cft_supported to ask rmw implementation if ContentFilteredTopic is supported or not.
  • rmw_create_subscription with optional fields const char * filter_expression and const rcutils_string_array_t * expression_parameters
  • test_rmw_content_filter to verify ContentFilteredTopic in rmw only.
  1. rcl ContentFilteredTopic support
  • basically bind rmw related interfaces to rcl, and verify ContentFilteredTopic in rcl.
  • support internal filtering function on reader side if rmw does not support ContentFilteredTopic.
  1. Action Topics with ContentFilteredTopic. (rcl action client mostly)
  • issue ContentFilteredTopic based on current goal ids in action client.
  • additional tests required.
  1. Parameter Events with ContentFilteredTopic.
  • user interface support to set filtering expression and expression parameters. (node name and parameter name)
  • additional tests required.

let's discuss the details offline.

@Barry-Xu-2018
Copy link
Contributor

@fujitatomoya

Completely agree.
Let's discuss it in more detail.

@fujitatomoya
Copy link
Collaborator Author

ros2/design#282 takes care of all activities content filtered topic. close this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants