-
Notifications
You must be signed in to change notification settings - Fork 206
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
[BUG] Flooded with logs "The limit of 1000 metricsets has been reached, no new metricsets will be created" #1361
Comments
I too have this problem. Is there a way to Disable the BreakdownMetricsProvider? It looks like a new BreakdownMetricsProvider is started if the Agent is enabled and regardless of whether the Metrics are disabled.
Even if you disable the MetricsProvider in configuration It will still allow a call into CaptureTransaction.
The BreakdownMetricsProvider has an IsEnabled property but this is only checked when adding it to the collection of MetricProviders for the purpose of collecting metrics. apm-agent-dotnet/src/Elastic.Apm/Metrics/MetricsProvider/BreakdownMetricsProvider.cs Line 39 in d6f210b
So Its possible to fill the apm-agent-dotnet/src/Elastic.Apm/Metrics/MetricsProvider/BreakdownMetricsProvider.cs Lines 62 to 72 in d6f210b
The MetricsCollector makes the call into GetSamples If the MetricsProvider is added to the list of MetricsProviders. apm-agent-dotnet/src/Elastic.Apm/Metrics/MetricsProvider/BreakdownMetricsProvider.cs Line 98 in d6f210b
I've considered these options in the absence of a code change.
Is it possible to gate the call to CaptureTransaction with a check of the IsEnabled property or similar?
|
Thanks for reporting this @tomap and @marcusjsford. I opened #1367 which will solve this problem. We'll still print a log, but it'll only happen in every metric collection round (once per 30sec by default) if you hit the limit.
Yes, as an immediate workaround you can disable it by setting the DisableMetrics to Sorry about the trouble on this. |
Oh and another workaround that may help people: You could also lower the MetricsInterval. The issue here is that we only collect 1K metrics per collection round and the collection round is 30sec by default. If you have let's say 1K transaction with 100spans each within 30sec, then it'll be 1K*100 = 100K metric per collection, so you hit the limit. But you can lower the interval of the metrics collection, and with that you may come to an interval whee you don't hit the limit. Obviously on the downside the agent will send data mer frequently to the APM Server. |
Fixed in #1367 |
APM Agent version
The version of the
Elastic.Apm
1.11Environment
Operating system and version: both windows & docker linux
.NET Framework/Core name and version : .Net 5.0.8
Application Target Framework(s) (e.g. net461, netcoreapp3.1): ASP.Net.Sdk.Web
Describe the bug
Since the last update, we re flooded with log message "The limit of 1000 metricsets has been reached, no new metricsets will be created"
comming from
apm-agent-dotnet/src/Elastic.Apm/Metrics/MetricsProvider/BreakdownMetricsProvider.cs
Line 90 in 07a4484
I don't understand the issue... how to fix it, ...
Here is our configuration:
The text was updated successfully, but these errors were encountered: