fix(ecu_status): add LocalECUStatusNotReady exception and handle in gRPC service#930
Open
fix(ecu_status): add LocalECUStatusNotReady exception and handle in gRPC service#930
Conversation
Contributor
📊 OTA Update Performance Comparison Report
⏱️ Execution Time
|
…le in OtaClientServiceV2
bfe3729 to
6389fd3
Compare
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Description
This PR fix the existing issues that FMS Console outputs the following errors when OTA is triggered.
This happens when
autowareis listed inavailable_ecu_idsbut Status response(ecu_v2field) doesn't includeautoware.Check list
Bug fix
Current behavior
The gRPC API server starts and begins answering
StatusRPCs before the OTA core finishes its bootstrap and writes its firstOTAClientStatusinto shared memory. Meanwhileavailable_ecu_idsis already populated synchronously fromecu_info.yamlat storage construction.The result is a
StatusResponsewhere:available_ecu_idscontains the local ECU (e.g.autoware)ecu_v2does not contain an entry for the local ECUDownstream agents can misread this as "the ECU is alive but reporting no status," which is semantically ambiguous and not a transient signal the caller knows to retry on. The polling task itself never crashes, so the symptom is silent.
Behavior after fix
Make the Status RPC return
UNAVAILABLEinstead of an asymmetricStatusResponse(where the local ECU appears inavailable_ecu_idsbut is missing fromecu_v2) during the startup window before the OTA core has written its first status into shared memory.Behavior matrix:
export()resultavailable_ecu_ids)LocalECUStatusNotReady→UNAVAILABLEavailable_ecu_ids)StatusResponseavailable_ecu_ids)StatusResponse(steady state, not a startup race)available_ecu_ids)StatusResponseRelated links & ticket