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

Add EventsExecutor release notes (backport #3662) #3667

Merged
merged 1 commit into from
May 23, 2023
Merged
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
26 changes: 26 additions & 0 deletions source/Releases/Release-Iron-Irwini.rst
Original file line number Diff line number Diff line change
Expand Up @@ -232,6 +232,32 @@ To make this a bit better, there is now a new ``NodeInterfaces`` class that can

There are examples on how to use this in https://github.com/ros2/rclcpp/pull/2041.

Introduction of a new executor type: the Events Executor
""""""""""""""""""""""""""""""""""""""""""""""""""""""""

The ``EventsExecutor`` from iRobot has been merged into the main ``rclcpp`` codebase.
This alternative executor implementation uses event-driven callbacks from the middleware implementations to fire callbacks at the ``rclcpp`` layer.
In addition to the push-based model, the ``EventsExecutor`` also moves timer management into a separate thread, which can allow for more accurate results and lower overhead, especially with many timers.

The ``EventsExecutor`` has a substantial set of documentation and use-in-practice that make it a strong candidate for inclusion in the ``rclcpp`` codebase.
For information about the initial implementation proposal as well as performance benchmarks, see https://discourse.ros.org/t/ros2-middleware-change-proposal/15863.
For more information about the design, see the design PR: https://github.com/ros2/design/pull/305.

Since the API is the same, trying the ``EventsExecutor`` is as straightforward as replacing your current Executor implementation (eg. ``SingleThreadedExecutor``):

.. code-block:: C++

#include <rclcpp/experimental/executors/events_executor/events_executor.hpp>
using rclcpp::experimental::executors::EventsExecutor;

EventsExecutor executor;
executor.add_node(node);
executor.spin();

**Note** The ``EventsExecutor`` and ``TimersManager`` are currently in the ``experimental`` namespace.
While it has been used as a standalone implementation for some time https://github.com/irobot-ros/events-executor, it was decided to use the ``experimental`` namespace for at least one release to give latitude in changing the API within the release.
Use caution as it will not be subject to the same API/ABI guarantees that the non-experimental code has.

``rclpy``
^^^^^^^^^

Expand Down