-
Notifications
You must be signed in to change notification settings - Fork 55
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
fix(#2370): use bridge topic id in service_monitor #2837
base: main
Are you sure you want to change the base?
Conversation
d32f40b
to
4d83766
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files
|
4d83766
to
ce6e55e
Compare
Robot Results
|
Signed-off-by: Marcel Guzik <[email protected]>
ce6e55e
to
98ccfe7
Compare
if entity.topic_id.is_bridge_health_topic() { | ||
// the bridge itself is not registered as a service, only the mapper | ||
if entity.topic_id == crate::C8Y_BRIDGE_TOPIC_ID { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
With this change, the az
bridge is not reported as a service on c8y
. This could make sense, but is this what we expect?
@@ -14,6 +14,8 @@ pub mod service_monitor; | |||
#[cfg(test)] | |||
mod tests; | |||
|
|||
pub(crate) const C8Y_BRIDGE_TOPIC_ID: &str = "device/main/service/mosquitto-c8y-bridge"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can't assume this hardcoded device/main
topic id even for the main device since we support overriding device_topic_id
via the config. That being said, I'm not fully sure if all tedge components properly respect that config setting yet either. I'm fairly sure that it is still hardcoded in many places.
Proposed changes
Use the correct bridge topic id when converting health status message.
Types of changes
Paste Link to the issue
bridge
#2370Checklist
cargo fmt
as mentioned in CODING_GUIDELINEScargo clippy
as mentioned in CODING_GUIDELINESFurther comments