Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add declaration for function to check QoS profile compatibility (#299)
* Add declaration for function to check QoS profile compatibility Currently, users who are creating a publisher or subscription can receive 'QoS incompatibility' events from the RMW if an incompatible endpoint is discovered. While this is useful, we currently don't have a nice way for application to generally check if two QoS profiles are compatible. For example, it would be nice if tooling could query the communication graph and report any detected QoS incompatibilities. In order to reduce code duplication, I think an API for checking QoS compatibilty should live in a common place. I've opted for `rmw` (over a place like `rcl`) since it's possible QoS compatiblity rules may vary per RMW vendor. Since rules for all DDS implementations should be the same, we could put that common logic in `rmw_dds_common`. Signed-off-by: Jacob Perron <[email protected]> * Refactor API Use enum for output; if one or more policies is set to 'system default', then it's better to warn the caller that we aren't sure if QoS profiles are compatible. Add optional 'reason', and 'reason_size', parameters for outputing a description of what is (or might be) the incompatiblity. Update API docs. Signed-off-by: Jacob Perron <[email protected]> * Do not set output parameters if there is an error This behaves more like other RMW functions. Signed-off-by: Jacob Perron <[email protected]> * Account for possible RMW_RET_ERROR return value Signed-off-by: Jacob Perron <[email protected]> * Warn on 'unknown' value Since it's possible for rmw's to return an unknown value if the policy is set to an unsupported value by ROS 2. Signed-off-by: Jacob Perron <[email protected]>
- Loading branch information