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

Observe mode events #1

Closed
norro opened this issue Nov 16, 2020 · 5 comments
Closed

Observe mode events #1

norro opened this issue Nov 16, 2020 · 5 comments
Assignees
Labels
enhancement New feature or request

Comments

@norro
Copy link

norro commented Nov 16, 2020

Currently, the mode observer observes all /{node}/transition_event topics to observe state transition, e.g., going to active, inactive or error-processing. This way it is observing all state transitions, however, it is missing all mode changes.

The observer should additionally observe /{node}/mode_event topics to observe mode changes, e.g., a node going from normal mode to degraded mode. Messages sent on this topic are of type ModeEvent and very close to the TransitionEvent messages.

@norro norro added the enhancement New feature or request label Nov 16, 2020
@marioney marioney self-assigned this Nov 16, 2020
@marioney
Copy link
Collaborator

The observer should additionally observe /{node}/mode_event topics to observe mode changes, e.g., a node going from normal mode to degraded mode. Messages sent on this topic are of type ModeEvent and very close to the TransitionEvent messages.

This should not be too complicated, but I have a couple questions:

  • Should we read the /{node}/mode_event for the same nodes/systems as the /{node}/transition_event or should we have a separated list on the components.yaml file?
  • What transitions should we look for when sending a diagnostics error? (i.e. For the /{node}/transition_event we're only checking the lifecycle_msgs::msg::State::TRANSITION_STATE_ERRORPROCESSING to lifecycle_msgs::msg::State::PRIMARY_STATE_UNCONFIGURED)

@norro
Copy link
Author

norro commented Nov 17, 2020

If you currently only rely on error and inactive, this is fine I guess.
Metacontrol might want to react on nodes/systems going into a certain (degraded?) mode. In the Bosch Pilot, we planed for this up to now.

@chcorbato what do you think?

@chcorbato
Copy link
Member

chcorbato commented Nov 17, 2020

I think de answer depends on how we decide to use metacontrol and system modes:

  1. If it is a design decision to have the system transition to certain "degraded" modes when necessary, independently of the metacontrol, then I think we need to also observe these events for the metacontrol to have an appropriate response to it.

  2. But if we decide that any system adaptation, including all mode transitions, can only be initiated by the metacontrol, then I guess there would be no need to observe it, apart from maybe observe it to confirm the success of a requested mode transition.

What would be your preferred design @norro ?

@norro
Copy link
Author

norro commented Nov 18, 2020

I think you're right, Carlos, this is indeed a design decision. And when you put it like that I would suggest we go for the 2. option to have it more consistent.
So this issue is then more of a enhancement, which is probably not required in the near future - not even for the Bosch pilot.

@norro
Copy link
Author

norro commented Nov 24, 2020

Superseeded by #2

@norro norro closed this as completed Nov 24, 2020
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

No branches or pull requests

3 participants