From 1ad83601f8273c576dd8738ff8d8509a5ef029da Mon Sep 17 00:00:00 2001 From: "daniele.corsini@corisnvest.it" Date: Thu, 19 Dec 2024 18:22:31 +0100 Subject: [PATCH] Improve size memory and storage --- src/Corsinvest.ProxmoxVE.Diagnostic.Api/Application.cs | 6 +++--- .../Corsinvest.ProxmoxVE.Diagnostic.Api.csproj | 5 +++-- .../Corsinvest.ProxmoxVE.Diagnostic.csproj | 4 ++-- 3 files changed, 8 insertions(+), 7 deletions(-) diff --git a/src/Corsinvest.ProxmoxVE.Diagnostic.Api/Application.cs b/src/Corsinvest.ProxmoxVE.Diagnostic.Api/Application.cs index aabf72c..e828ec8 100644 --- a/src/Corsinvest.ProxmoxVE.Diagnostic.Api/Application.cs +++ b/src/Corsinvest.ProxmoxVE.Diagnostic.Api/Application.cs @@ -987,8 +987,8 @@ private static void CheckThresholdHost(List result, "WV0002", context, "Usage", - [(rrdData.Average(a => a.Memory.MemoryUsage), - rrdData.Average(a => a.Memory.MemorySize), + [(rrdData.Average(a => (double)a.Memory.MemoryUsage), + rrdData.Average(a => (double)a.Memory.MemorySize), id, $"Memory (rrd {thresholdHost.TimeSeries} AVERAGE)") ], false, @@ -1060,7 +1060,7 @@ private static void CheckNodeRrd(List result, DiagnosticResultContext.Node, "Usage", [(rrdData.Average(a => a.SwapUsage), - rrdData.Average(a => a.SwapSize) , + rrdData.Average(a => (double)a.SwapSize) , id, $"SWAP (rrd {settings.Node.TimeSeries} AVERAGE)") ], false, diff --git a/src/Corsinvest.ProxmoxVE.Diagnostic.Api/Corsinvest.ProxmoxVE.Diagnostic.Api.csproj b/src/Corsinvest.ProxmoxVE.Diagnostic.Api/Corsinvest.ProxmoxVE.Diagnostic.Api.csproj index 5d444e8..794e4fb 100644 --- a/src/Corsinvest.ProxmoxVE.Diagnostic.Api/Corsinvest.ProxmoxVE.Diagnostic.Api.csproj +++ b/src/Corsinvest.ProxmoxVE.Diagnostic.Api/Corsinvest.ProxmoxVE.Diagnostic.Api.csproj @@ -3,7 +3,7 @@ net8.0 Library - 1.6.2 + 1.7.0 Corsinvest Srl Corsinvest Srl Corsinvest @@ -24,6 +24,7 @@ true true + True $(AllowedOutputExtensionsInPackageBuildOutputFolder);.pdb @@ -39,7 +40,7 @@ - + diff --git a/src/Corsinvest.ProxmoxVE.Diagnostic/Corsinvest.ProxmoxVE.Diagnostic.csproj b/src/Corsinvest.ProxmoxVE.Diagnostic/Corsinvest.ProxmoxVE.Diagnostic.csproj index 9e595db..37e353d 100644 --- a/src/Corsinvest.ProxmoxVE.Diagnostic/Corsinvest.ProxmoxVE.Diagnostic.csproj +++ b/src/Corsinvest.ProxmoxVE.Diagnostic/Corsinvest.ProxmoxVE.Diagnostic.csproj @@ -1,7 +1,7 @@  Exe - 1.5.3 + 1.6.0 net8.0 cv4pve-diag Corsinvest Srl @@ -18,7 +18,7 @@ - +