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

feat(autoware_node): add AutowareNode base class #57

Closed
wants to merge 9 commits into from

Conversation

xmfcx
Copy link
Contributor

@xmfcx xmfcx commented Sep 23, 2022

Signed-off-by: M. Fatih Cırıt mfc@leodrive.ai

Description

Related Discussion: https://github.com/orgs/autowarefoundation/discussions/3194

This PR is for creating the base class for all the future Autoware Core nodes to inherit from.

This node will be inheriting from the rclcpp_lifecycle::LifecycleNode with (LifeCycle Readme).

I'll be taking ros2 nav2 stack as reference too while combining Lifecycle and Composable node concepts.

While developing this PR, I am going to explore ideas mentioned in previous conversations in the Autoware community.

Related links

Related links

Communication architecture

Communication architecture

Registration Service

Service server: ACC

Service client: AutowareNode

Roles:

  • Register the AutowareNode in ACC
  • Receive the UUID for the AutowareNode
  • If already registered, return error
sequenceDiagram
    participant acc as Autoware Control Center
    participant node as node_a

    Note right of node: cli_reg
    node ->>+ acc: name: node_a
    Note left of acc: srv_reg

    acc ->> acc: generate a UUID for the node_a
    acc ->> acc: create a bond between acc and node_a


    Note left of acc: srv_reg
    acc -->>- node: UUID and registration success bool
    Note right of node: cli_reg

Heart beat bond

https://github.com/ros/bond_core/blob/ros2/ros2_migration_readme.md Slow

https://github.com/ros-safety/software_watchdogs

https://design.ros2.org/articles/qos_deadline_liveliness_lifespan.html

https://docs.ros.org/en/rolling/Concepts/About-Quality-of-Service-Settings.html#qos-events

Roles:

  • As long as the AutowareNode is alive, it reports with this bond
  • If the AutowareNode dies, it triggers the on_broken callback

Reporting service

Service server: ACC

Service client: AutowareNode

Roles:

  • Reporting state of the AutowareNode to the ACC
    • Warning
    • Error

Control service

Service server: AutowareNode

Service client: ACC

Roles:

  • Shutting down the AutowareNode
  • Toggle AutowareNode between active-inactive?

Tasks

  • Implement registration service
    • Define the interface
    • Create the client
    • Create the service
    • Make them communicate
    • Generate UUID
    • Send UUID
  • Implement control service
  • Implement reporting service
  • Implement watchdog - heartbeat

Tests performed

PR Review Items

Notes for reviewers

Pre-review checklist for the PR author

The PR author must check the checkboxes below when creating the PR.

In-review checklist for the PR reviewers

The PR reviewers must check the checkboxes below before approval.

  • The PR follows the pull request guidelines.
  • The PR has been properly tested.
  • The PR has been reviewed by the code owners.

Post-review checklist for the PR author

The PR author must check the checkboxes below before merging.

  • There are no open discussions or they are tracked via tickets.
  • The PR is ready for merge.

After all checkboxes are checked, anyone who has write access can merge the PR.

@xmfcx xmfcx self-assigned this Sep 23, 2022
@mergify
Copy link

mergify bot commented Sep 23, 2022

⚠️ The sha of the head commit of this PR conflicts with #56. Mergify cannot evaluate rules on this PR. ⚠️

@xmfcx xmfcx added the enhancement New feature or request label Sep 23, 2022
@xmfcx xmfcx force-pushed the add_autoware_node branch 3 times, most recently from 114e9d0 to fde4177 Compare September 26, 2022 16:13
@stale
Copy link

stale bot commented Dec 10, 2022

This pull request has been automatically marked as stale because it has not had recent activity.

@stale stale bot added the stale label Dec 10, 2022
@stale stale bot removed the stale label Jan 12, 2023
Signed-off-by: M. Fatih Cırıt <mfc@leodrive.ai>
pre-commit-ci bot and others added 8 commits January 12, 2023 19:18
Signed-off-by: M. Fatih Cırıt <mfc@leodrive.ai>
Signed-off-by: M. Fatih Cırıt <mfc@leodrive.ai>
Signed-off-by: M. Fatih Cırıt <mfc@leodrive.ai>
Signed-off-by: M. Fatih Cırıt <mfc@leodrive.ai>
Signed-off-by: M. Fatih Cırıt <mfc@leodrive.ai>
Signed-off-by: M. Fatih Cırıt <mfc@leodrive.ai>
@codecov
Copy link

codecov bot commented Feb 3, 2023

Codecov Report

❗ No coverage uploaded for pull request base (main@6bafedf). Click here to learn what that means.
Patch has no changes to coverable lines.

Additional details and impacted files
@@          Coverage Diff           @@
##             main     #57   +/-   ##
======================================
  Coverage        ?   0.00%           
======================================
  Files           ?       4           
  Lines           ?      23           
  Branches        ?       0           
======================================
  Hits            ?       0           
  Misses          ?      23           
  Partials        ?       0           
Flag Coverage Δ
differential 0.00% <0.00%> (?)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@xmfcx
Copy link
Contributor Author

xmfcx commented Feb 3, 2023

Because of the #57 (comment) mergify error, moved to #73

@xmfcx xmfcx closed this Feb 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant