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

[APM] agent config applied indicator does not work with Fleet integration #123109

Closed
axw opened this issue Jan 17, 2022 · 14 comments · Fixed by #131820
Closed

[APM] agent config applied indicator does not work with Fleet integration #123109

axw opened this issue Jan 17, 2022 · 14 comments · Fixed by #131820
Assignees
Labels
apm:test-plan-done Pull request that was successfully tested during the test plan bug Fixes for quality problems that affect the customer experience Team:APM All issues that need APM UI Team support v8.3.0

Comments

@axw
Copy link
Member

axw commented Jan 17, 2022

Kibana version

8.0.0

APM Server version (if applicable)

8.0.0

Elasticsearch version (if applicable)

No response

Steps to Reproduce

  1. Install APM Fleet integration
  2. Run an instrumented service
  3. Define agent config for that service
  4. Wait until agent config has been received (tail agent logs)

Expected Behavior

UI indicates agent config has been applied.

Actual Behavior

UI indicates agent config is not yet applied.

@axw axw added the Team:APM All issues that need APM UI Team support label Jan 17, 2022
@elasticmachine
Copy link
Contributor

Pinging @elastic/apm-ui (Team:apm)

@axw
Copy link
Member Author

axw commented Jan 17, 2022

When running as a Fleet integration, agent config is delivered to APM Server rather than APM Server actively querying Kibana for the config. Thus, we cannot actively mark agent config as having been applied, as we did in the past. Instead, APM Server produces agent_config metric documents which the UI should search for.

The docs have the following fields that may be used:

  • metricset.name: agent_config
  • labels.etag: <agent_config_etag>

The value of labels.etag corresponds to the etag value that is passed by the APM UI down through the Fleet policy.

@axw axw added the bug Fixes for quality problems that affect the customer experience label Jan 18, 2022
@nicpenning
Copy link

Thanks for posting this issue. This single bug has halted our POV with APM and has caused much frustration with testing.

Even though the icon doesn't change, does this mean the config changes are still not applying? From our experience, the changes made in Kibana do not get sent to the agent in the application to enable, for example, request body data.

@axw
Copy link
Member Author

axw commented May 4, 2022

@nicpenning sorry about the understandable frustration.

Even though the icon doesn't change, does this mean the config changes are still not applying?

Yes. We have tests that show agent config works when using Fleet - it's just that this doesn't reflect in the indicator.

From our experience, the changes made in Kibana do not get sent to the agent in the application to enable, for example, request body data.

Would you mind opening a post at https://discuss.elastic.co/c/observability/apm/58 with the steps you took? Maybe there is some other bug that we're not aware of.

@nicpenning
Copy link

Yes, I can do that. Thanks!

@gbamparop gbamparop self-assigned this May 9, 2022
@gbamparop
Copy link
Contributor

@axw how the configs applied by Jaeger agent will be handled? (see elastic/apm-server#3579).

Also, do you think we should add a timerange filter as mentioned here?

@gbamparop
Copy link
Contributor

@axw how the configs applied by Jaeger agent will be handled? (see elastic/apm-server#3579).

Also, do you think we should add a timerange filter as mentioned here?

cc @elastic/apm-server

@axw
Copy link
Member Author

axw commented May 16, 2022

@gbamparop

how the configs applied by Jaeger agent will be handled? (see elastic/apm-server#3579).

We immediately mark config as applied when it is queried by a Jaeger client. This is slightly different to what we do for Elastic APM agents, where we mark the config as applied when the agent queries the config a second time (as identified by its Etag), at which point we know it has already been successfully applied by the agent.

Either way though, there should be no difference to the UI: once there's an agent_config metricset, it's applied.

Also, do you think we should add a timerange filter as mentioned here?

We'll definitely want a time range filter, as this is an append-only data stream which will be updated every 30 seconds. So filter on the last minute? If there's no active APM Server(s), then there would be no agent_config metrics. In that case I think we can either just show the config as not applied, or have some ? indicator.

@dgieselaar
Copy link
Member

@axw is the etag value available in agent_config metrics for Jaeger agents? We use that value to join agent_config metrics w/ the agent configuration documents on the Kibana side.

@axw
Copy link
Member Author

axw commented May 16, 2022

@dgieselaar yes, see #123109 (comment)

EDIT: sorry just saw you specifically asked "for Jaeger agents". Yes, it'll be available for them as well.

@dgieselaar
Copy link
Member

@axw great, we should be set then, correct @gbamparop?

@gbamparop
Copy link
Contributor

@axw great, we should be set then, correct @gbamparop?

Yes that's correct as long as it's being set.

@gbamparop
Copy link
Contributor

We'll definitely want a time range filter, as this is an append-only data stream which will be updated every 30 seconds. So filter on the last minute? If there's no active APM Server(s), then there would be no agent_config metrics.

Thanks, I'll update the time range to the last minute then.

@nicpenning
Copy link

Yes, I can do that. Thanks!

Since upgrading to 8.2.0 everything with APM broke so we are working on fixing this before we can talk about the agent configuration issues.

@gbamparop gbamparop added the apm:test-plan-done Pull request that was successfully tested during the test plan label May 31, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
apm:test-plan-done Pull request that was successfully tested during the test plan bug Fixes for quality problems that affect the customer experience Team:APM All issues that need APM UI Team support v8.3.0
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants