Modifica log x ogni batch da 499
This commit is contained in:
@@ -280,15 +280,22 @@ namespace Eqn.Sender.Controllers
|
||||
// se durata > 5sec --> loggo!
|
||||
if (sw.Elapsed.TotalSeconds > 5)
|
||||
{
|
||||
string logVal = $"Superamento soglia: effettuate {numCall} chiamate in {sw.Elapsed.TotalSeconds:N3} sec";
|
||||
_logger.LogWarning(logVal);
|
||||
// calcolo numero esecuzioni
|
||||
int numSend = elapsedList.Count;
|
||||
double minTime = elapsedList.OrderBy(x => x).FirstOrDefault();
|
||||
double avgTime = numSend > 0 ? elapsedList.Sum(x => x) / numSend : 0;
|
||||
double maxTime = elapsedList.OrderByDescending(x => x).FirstOrDefault();
|
||||
string stats = $"Batch processati: {numSend} | minTime: {minTime:N3} | avgTime: {avgTime:N3} | maxTime: {maxTime:N3}";
|
||||
_logger.LogWarning(stats);
|
||||
string logVal = $"Warnng soglia, durata: {sw.Elapsed.TotalSeconds:N3} sec | chiamate: {numCall} | batch: {numSend}";
|
||||
_logger.LogWarning(logVal);
|
||||
// scrivo tutte le righe
|
||||
int idx = 0;
|
||||
foreach (var item in elapsedList)
|
||||
{
|
||||
_logger.LogWarning($"{idx:00}| {item:N3} sec");
|
||||
}
|
||||
|
||||
//// calcolo numero esecuzioni
|
||||
//double minTime = elapsedList.OrderBy(x => x).FirstOrDefault();
|
||||
//double avgTime = numSend > 0 ? elapsedList.Sum(x => x) / numSend : 0;
|
||||
//double maxTime = elapsedList.OrderByDescending(x => x).FirstOrDefault();
|
||||
//string stats = $"Batch processati: {numSend} | minTime: {minTime:N3} | avgTime: {avgTime:N3} | maxTime: {maxTime:N3}";
|
||||
//_logger.LogWarning(stats);
|
||||
}
|
||||
return answ;
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk.Web">
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
<Version>1.0.2405.1613</Version>
|
||||
<Version>1.0.2405.1614</Version>
|
||||
<Nullable>enable</Nullable>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<UserSecretsId>352f62a7-3b7d-40cd-ab21-b55a5fefae44</UserSecretsId>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<body>
|
||||
<i>EqnSender - Gestione invio messaggi piattaforma EQN</i>
|
||||
<h4>Versione: 1.0.2405.1613</h4>
|
||||
<h4>Versione: 1.0.2405.1614</h4>
|
||||
<br /> Note di rilascio:
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
@@ -1 +1 @@
|
||||
1.0.2405.1613
|
||||
1.0.2405.1614
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<item>
|
||||
<version>1.0.2405.1613</version>
|
||||
<version>1.0.2405.1614</version>
|
||||
<url>http://nexus.steamware.net/repository/SWS/EqnSender/stable/0/EqnSender.zip</url>
|
||||
<changelog>http://nexus.steamware.net/repository/SWS/EqnSender/stable/0/ChangeLog.html</changelog>
|
||||
<mandatory>false</mandatory>
|
||||
|
||||
Reference in New Issue
Block a user