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

components-actual diagnostic skips content of component/unit errors #2940

Closed
Tracked by #3640
faec opened this issue Jun 23, 2023 · 1 comment · Fixed by #3835
Closed
Tracked by #3640

components-actual diagnostic skips content of component/unit errors #2940

faec opened this issue Jun 23, 2023 · 1 comment · Fixed by #3835
Assignees
Labels
bug Something isn't working Team:Elastic-Agent Label for the Agent team

Comments

@faec
Copy link
Contributor

faec commented Jun 23, 2023

The components-actual diagnostic reports the observed component state stored in (*Coordinator).State().Components. One part of this structure is Err fields on each component and unit. However, these are bare error objects, and the diagnostic relies on them to properly serialize themselves during YAML encoding, which many error types do not do. For example setting a component's error to Err: errors.New("extremely important error") will just be encoded to yaml as err: {}.

We should make changes to the internal error structures and/or the diagnostic's processing of Components to make sure we get the text content of these errors.

@faec faec added bug Something isn't working Team:Elastic-Agent Label for the Agent team labels Jun 23, 2023
@elasticmachine
Copy link
Contributor

Pinging @elastic/elastic-agent (Team:Elastic-Agent)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Team:Elastic-Agent Label for the Agent team
Projects
None yet
4 participants