This commit is contained in:
Łukasz Domeradzki 2024-07-14 21:19:08 +02:00
parent 7d6b4b7a23
commit 7b1b3d4d8e
No known key found for this signature in database
GPG key ID: 6B138B4C64555AEA

View file

@ -139,10 +139,10 @@ internal sealed class MonitoringPlugin : OfficialPlugin, IDisposable, IOfficialG
return;
}
PluginMeasurements = new[] {
new Measurement<int>(PluginsCore.ActivePlugins.Count),
new Measurement<int>(PluginsCore.ActivePlugins.Count(static plugin => plugin is OfficialPlugin), new KeyValuePair<string, object?>(TagNames.PluginType, "official")),
new Measurement<int>(PluginsCore.ActivePlugins.Count(static plugin => plugin is not OfficialPlugin), new KeyValuePair<string, object?>(TagNames.PluginType, "custom"))
PluginMeasurements = new HashSet<Measurement<int>>(3) {
new(PluginsCore.ActivePlugins.Count),
new(PluginsCore.ActivePlugins.Count(static plugin => plugin is OfficialPlugin), new KeyValuePair<string, object?>(TagNames.PluginType, "official")),
new(PluginsCore.ActivePlugins.Count(static plugin => plugin is not OfficialPlugin), new KeyValuePair<string, object?>(TagNames.PluginType, "custom"))
}.ToFrozenSet();
Meter = new Meter(MeterName, Version.ToString());