Modifiche in prod
- cambio livello logging x tracciare meglio funzionamento eventi - modifica modalità serializzazione TSData (nuovo costruttore) x ridurre dimensione cache redis (circa -40%)
This commit is contained in:
@@ -100,8 +100,8 @@ namespace GWMS.Data.Controllers
|
||||
localDbCtx
|
||||
.DbSetAlarmLog
|
||||
.Add(newItem);
|
||||
await localDbCtx.SaveChangesAsync();
|
||||
fatto = true;
|
||||
await localDbCtx.SaveChangesAsync();
|
||||
fatto = true;
|
||||
}
|
||||
catch (Exception exc)
|
||||
{
|
||||
@@ -318,7 +318,8 @@ namespace GWMS.Data.Controllers
|
||||
// recupero i dati della gioranta indicata
|
||||
var currLevelTS = dbLevels
|
||||
.Where(x => x.DtEvent > dataCurr && x.DtEvent <= dataCurr.AddDays(1))
|
||||
.Select(x => new TSData() { DtEvent = x.DtEvent, ValDouble = x.ValNumber })
|
||||
.Select(x => new TSData(x.DtEvent, x.ValNumber, true))
|
||||
//.Select(x => new TSData() { DtEvent = x.DtEvent, ValDouble = x.ValNumber })
|
||||
.ToList();
|
||||
// SOLO SE ho almeno 1 record livello
|
||||
if (currLevelTS.Count > 0)
|
||||
@@ -356,11 +357,13 @@ namespace GWMS.Data.Controllers
|
||||
{
|
||||
newRec.ExecutionTS = dbOrders
|
||||
.Where(x => x.DtExecStart >= dataCurr && x.DtExecStart < dataCurr.AddDays(1))
|
||||
.Select(x => new TSData() { DtEvent = x.DtOrder, ValDouble = x.ExecutionQty }).ToList();
|
||||
.Select(x => new TSData(x.DtOrder, x.ExecutionQty, true)).ToList();
|
||||
//.Select(x => new TSData() { DtEvent = x.DtOrder, ValDouble = x.ExecutionQty }).ToList();
|
||||
|
||||
newRec.OrderTS = dbOrders
|
||||
.Where(x => x.DtExecStart >= dataCurr && x.DtExecStart < dataCurr.AddDays(1))
|
||||
.Select(x => new TSData() { DtEvent = x.DtOrder, ValDouble = x.OrderQty }).ToList();
|
||||
.Select(x => new TSData(x.DtOrder, x.OrderQty, true)).ToList();
|
||||
//.Select(x => new TSData() { DtEvent = x.DtOrder, ValDouble = x.OrderQty }).ToList();
|
||||
|
||||
newRec.OrdersIds = dbOrders
|
||||
.Where(x => x.DtExecStart >= dataCurr && x.DtExecStart < dataCurr.AddDays(1))
|
||||
@@ -839,14 +842,14 @@ namespace GWMS.Data.Controllers
|
||||
|
||||
using (GWMSContext localDbCtx = new GWMSContext(_configuration))
|
||||
{
|
||||
// per prima cosa recupero dati RAW ultime 2 settimane...
|
||||
// per prima cosa recupero dati RAW ultimo mese...
|
||||
var rawData = localDbCtx
|
||||
.DbSetPlantLog
|
||||
.Where(x => x.DtEvent > DateTime.Today.AddMonths(-1) && x.PlantId == PlantId)
|
||||
.AsNoTracking()
|
||||
.ToList();
|
||||
|
||||
// ora recupero i distinct dell'ultima settimana x capire COSA posso poi ricavare...
|
||||
// ora recupero i distinct x capire COSA posso poi ricavare...
|
||||
var countData = rawData
|
||||
.Select(e => e.FluxType)
|
||||
.Distinct()
|
||||
@@ -855,8 +858,6 @@ namespace GWMS.Data.Controllers
|
||||
// recupero dal DB i dati PRESENTI...
|
||||
if (countData.Contains("Level"))
|
||||
{
|
||||
//rawLevelData = localDbCtx
|
||||
// .DbSetPlantLog
|
||||
rawLevelData = rawData
|
||||
.Where(x => x.FluxType == "Level" && x.PlantId == PlantId)
|
||||
//.AsNoTracking()
|
||||
@@ -947,19 +948,24 @@ namespace GWMS.Data.Controllers
|
||||
}
|
||||
|
||||
LevelTS = rawLevelData
|
||||
.Select(x => new TSData() { DtEvent = x.DtEvent, ValDouble = x.ValNumber }).ToList();
|
||||
.Select(x => new TSData(x.DtEvent, x.ValNumber, true)).ToList();
|
||||
//.Select(x => new TSData() { DtEvent = x.DtEvent, ValDouble = x.ValNumber }).ToList();
|
||||
|
||||
OrderTS = rawOpenOrderData
|
||||
.Select(x => new TSData() { DtEvent = x.DtOrder, ValDouble = x.OrderQty }).ToList();
|
||||
.Select(x => new TSData(x.DtOrder, x.OrderQty, true)).ToList();
|
||||
//.Select(x => new TSData() { DtEvent = x.DtOrder, ValDouble = x.OrderQty }).ToList();
|
||||
|
||||
PressMainTS = rawMainPressData
|
||||
.Select(x => new TSData() { DtEvent = x.DtEvent, ValDouble = x.ValNumber }).ToList();
|
||||
.Select(x => new TSData(x.DtEvent, x.ValNumber, true)).ToList();
|
||||
//.Select(x => new TSData() { DtEvent = x.DtEvent, ValDouble = x.ValNumber }).ToList();
|
||||
|
||||
PressBHTS = rawBHPressData
|
||||
.Select(x => new TSData() { DtEvent = x.DtEvent, ValDouble = x.ValNumber }).ToList();
|
||||
.Select(x => new TSData(x.DtEvent, x.ValNumber, true)).ToList();
|
||||
//.Select(x => new TSData() { DtEvent = x.DtEvent, ValDouble = x.ValNumber }).ToList();
|
||||
|
||||
PressBLTS = rawBLPressData
|
||||
.Select(x => new TSData() { DtEvent = x.DtEvent, ValDouble = x.ValNumber }).ToList();
|
||||
.Select(x => new TSData(x.DtEvent, x.ValNumber, true)).ToList();
|
||||
//.Select(x => new TSData() { DtEvent = x.DtEvent, ValDouble = x.ValNumber }).ToList();
|
||||
|
||||
PressTS.Add("Main", PressMainTS);
|
||||
PressTS.Add("BH", PressBHTS);
|
||||
|
||||
+36
-1
@@ -1,5 +1,7 @@
|
||||
using System;
|
||||
using Newtonsoft.Json;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Data.SqlTypes;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
@@ -8,10 +10,43 @@ namespace GWMS.Data
|
||||
{
|
||||
public class TSData
|
||||
{
|
||||
#region Public Constructors
|
||||
|
||||
///// <summary>
|
||||
///// Init generico per retrocompatibilità e deserializzazione
|
||||
///// </summary>
|
||||
public TSData() { }
|
||||
|
||||
/// <summary>
|
||||
/// Costruttore "Smart" per la creazione rapida e ottimizzata
|
||||
/// </summary>
|
||||
/// <param name="dt"></param>
|
||||
/// <param name="val"></param>
|
||||
/// <param name="doRound"></param>
|
||||
public TSData(DateTime dt, double val, bool doRound = true)
|
||||
{
|
||||
if (doRound)
|
||||
{
|
||||
// Arrotonda al secondo: crea una nuova data ignorando i Tick (millisecondi)
|
||||
DtEvent = new DateTime(dt.Year, dt.Month, dt.Day, dt.Hour, dt.Minute, dt.Second);
|
||||
// Arrotonda a 2 decimali
|
||||
ValDouble = Math.Round(val, 2);
|
||||
}
|
||||
else
|
||||
{
|
||||
DtEvent = dt;
|
||||
ValDouble = val;
|
||||
}
|
||||
}
|
||||
|
||||
#endregion Public Constructors
|
||||
|
||||
#region Public Properties
|
||||
|
||||
[JsonProperty("d")]
|
||||
public DateTime DtEvent { get; set; } = DateTime.Now;
|
||||
|
||||
[JsonProperty("v")]
|
||||
public double ValDouble { get; set; } = 0;
|
||||
|
||||
#endregion Public Properties
|
||||
|
||||
@@ -42,7 +42,7 @@ namespace GWMS.UI.Controllers
|
||||
public IOBController(GWMSDataService DataService)
|
||||
{
|
||||
_DataService = DataService;
|
||||
//Log.Debug("Avviata classe IOBController");
|
||||
Log.Debug("Avvio classe IOBController");
|
||||
}
|
||||
|
||||
#endregion Public Constructors
|
||||
@@ -87,6 +87,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("addTask2Exe/{id}")]
|
||||
public async Task<string> addTask2Exe(string id, string taskName, string taskVal)
|
||||
{
|
||||
Log.Info($"addTask2Exe | {id} | {taskName} | {taskVal}");
|
||||
string answ = "";
|
||||
// converto stringa in tipo task...
|
||||
taskType tName = taskType.nihil;
|
||||
@@ -133,6 +134,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("checkLevels/{id}")]
|
||||
public async Task<string> checkLevels(string id)
|
||||
{
|
||||
Log.Info($"checkLevels | {id}");
|
||||
//Log.Debug($"Chiamata checkLevels | {id}");
|
||||
bool fatto = false;
|
||||
// ...verifica per ricalcolo ordini...
|
||||
@@ -164,7 +166,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("enabled/{id}")]
|
||||
public async Task<string> enabled(string id)
|
||||
{
|
||||
//Log.Debug($"Chiamata enabled | {id}");
|
||||
Log.Debug($"Enabled | {id}");
|
||||
string answ = "ND";
|
||||
// se id nullo --> KO!
|
||||
if (id == null)
|
||||
@@ -241,7 +243,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("flog/{id}")]
|
||||
public async Task<string> flog(string id, string flux, string valore, string dtEve, string dtCurr, string cnt)
|
||||
{
|
||||
//Log.Debug($"Chiamata flog | {id} | {flux} | {valore} | {dtEve} | {dtCurr} | {cnt}");
|
||||
Log.Debug($"flog | {id} | {flux} | {valore} | {dtEve} | {dtCurr} | {cnt}");
|
||||
bool fatto = false;
|
||||
// formato yyyymmddHHMMSSnnn ovvero da anno a millisecondi
|
||||
if (cnt == null)
|
||||
@@ -255,7 +257,7 @@ namespace GWMS.UI.Controllers
|
||||
dtCurr = dtCurr.Length > 17 ? dtCurr.Substring(0, 17) : dtCurr;
|
||||
DateTime dataOraEvento = DateTime.Now;
|
||||
DateTime dtEvento, dtCorrente;
|
||||
// controllo: se ho valori dt x evento e orario DIVERSI per acquisitore IOB calcolo dataOraEvento corretto
|
||||
// controllo: se ho valori DtEvent x evento e orario DIVERSI per acquisitore IOB calcolo dataOraEvento corretto
|
||||
if (dtEve != dtCurr)
|
||||
{
|
||||
Int64 delta = 0;
|
||||
@@ -337,7 +339,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpPost("flogJson/{id}")]
|
||||
public async Task<string> flogJson(string id, [FromBody] flogJsonPayload rawData)
|
||||
{
|
||||
//Log.Debug($"Chiamata flogJson | {id}");
|
||||
Log.Debug($"flogJson | {id} | {rawData.fluxData.Count} logs");
|
||||
bool fatto = false;
|
||||
// verifico ci sia valore
|
||||
if (rawData != null && !string.IsNullOrEmpty(id))
|
||||
@@ -429,7 +431,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpPost("forceSplitOdl/{id}")]
|
||||
public string forceSplitOdl(string id)
|
||||
{
|
||||
//Log.Debug($"Chiamata forceSplitOdl | {id}");
|
||||
Log.Debug($"Chiamata forceSplitOdl | {id}");
|
||||
return "OK";
|
||||
}
|
||||
|
||||
@@ -448,7 +450,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpPost("forceSplitOdlFull/{id}")]
|
||||
public string forceSplitOdlFull(string id, bool doConfirm, bool qtyFromLast, int? roundStep, string keyRichiesta = "")
|
||||
{
|
||||
//Log.Debug($"Chiamata forceSplitOdlFull | {id}");
|
||||
Log.Debug($"Chiamata forceSplitOdlFull | {id}");
|
||||
return "OK";
|
||||
}
|
||||
|
||||
@@ -461,7 +463,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet]
|
||||
public string Get()
|
||||
{
|
||||
//Log.Debug("Chiamata Get");
|
||||
Log.Debug("Chiamata Get");
|
||||
return "OK";
|
||||
}
|
||||
|
||||
@@ -475,7 +477,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("{id}")]
|
||||
public string Get(int id)
|
||||
{
|
||||
//Log.Debug($"Chiamata Get | {id}");
|
||||
Log.Debug($"Chiamata Get | {id}");
|
||||
return "OK";
|
||||
}
|
||||
|
||||
@@ -490,7 +492,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("getCounter/{id}")]
|
||||
public string getCounter(string id)
|
||||
{
|
||||
//Log.Debug($"Chiamata getCounter | {id}");
|
||||
Log.Debug($"Chiamata getCounter | {id}");
|
||||
return "0";
|
||||
}
|
||||
|
||||
@@ -505,7 +507,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("getCounterTCRec/{id}")]
|
||||
public string getCounterTCRec(string id)
|
||||
{
|
||||
//Log.Debug($"Chiamata getCounterTCRec | {id}");
|
||||
Log.Debug($"Chiamata getCounterTCRec | {id}");
|
||||
return "0";
|
||||
}
|
||||
|
||||
@@ -520,7 +522,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("getCurrData/{id}")]
|
||||
public string getCurrData(string id)
|
||||
{
|
||||
//Log.Debug($"Chiamata getCurrData | {id}");
|
||||
Log.Debug($"Chiamata getCurrData | {id}");
|
||||
return $"{id}";
|
||||
}
|
||||
|
||||
@@ -535,7 +537,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("getCurrODL/{id}")]
|
||||
public string getCurrODL(string id)
|
||||
{
|
||||
//Log.Debug($"Chiamata getCurrODL | {id}");
|
||||
Log.Debug($"Chiamata getCurrODL | {id}");
|
||||
return "1";
|
||||
}
|
||||
|
||||
@@ -548,7 +550,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("getCurrOdlRow/{id}")]
|
||||
public string getCurrOdlRow(string id)
|
||||
{
|
||||
//Log.Debug($"Chiamata getCurrOdlRow | {id}");
|
||||
Log.Debug($"Chiamata getCurrOdlRow | {id}");
|
||||
return "";
|
||||
}
|
||||
|
||||
@@ -561,7 +563,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("getCurrOdlStart/{id}")]
|
||||
public string getCurrOdlStart(string id)
|
||||
{
|
||||
//Log.Debug($"Chiamata getCurrOdlStart | {id}");
|
||||
Log.Debug($"Chiamata getCurrOdlStart | {id}");
|
||||
return $"{DateTime.Now}";
|
||||
}
|
||||
|
||||
@@ -574,7 +576,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("getCurrStatoRow/{id}")]
|
||||
public string getCurrStatoRow(string id)
|
||||
{
|
||||
//Log.Debug($"Chiamata getCurrStatoRow | {id}");
|
||||
Log.Debug($"Chiamata getCurrStatoRow | {id}");
|
||||
return "";
|
||||
}
|
||||
|
||||
@@ -587,7 +589,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("getFiles/{id}")]
|
||||
public string getFiles(string id)
|
||||
{
|
||||
//Log.Debug($"Chiamata getFiles | {id}");
|
||||
Log.Debug($"Chiamata getFiles | {id}");
|
||||
return "";
|
||||
}
|
||||
|
||||
@@ -600,7 +602,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("getIdlePeriod/{id}")]
|
||||
public int getIdlePeriod(string id)
|
||||
{
|
||||
//Log.Debug($"Chiamata getIdlePeriod | {id}");
|
||||
Log.Debug($"Chiamata getIdlePeriod | {id}");
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -612,7 +614,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("getIob2call/{id}")]
|
||||
public string getIob2call(string id)
|
||||
{
|
||||
//Log.Debug($"Chiamata getIob2call | {id}");
|
||||
Log.Debug($"Chiamata getIob2call | {id}");
|
||||
return "";
|
||||
}
|
||||
|
||||
@@ -624,7 +626,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("getM2IOB/{id}")]
|
||||
public string getM2IOB(string id)
|
||||
{
|
||||
//Log.Debug($"Chiamata getM2IOB | {id}");
|
||||
Log.Debug($"Chiamata getM2IOB | {id}");
|
||||
return "";
|
||||
}
|
||||
|
||||
@@ -637,6 +639,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("getObjItems/{id}")]
|
||||
public async Task<string> getObjItems(string id)
|
||||
{
|
||||
Log.Info($"getObjItems | {id}");
|
||||
string answ = "";
|
||||
if (string.IsNullOrWhiteSpace(id))
|
||||
{
|
||||
@@ -674,6 +677,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("getObjItems2Write/{id}")]
|
||||
public async Task<string> getObjItems2Write(string id)
|
||||
{
|
||||
Log.Info($"getObjItems2Write | {id}");
|
||||
string answ = "";
|
||||
if (string.IsNullOrWhiteSpace(id))
|
||||
{
|
||||
@@ -713,6 +717,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("getTask2Exe/{id}")]
|
||||
public async Task<string> getTask2Exe(string id)
|
||||
{
|
||||
Log.Info($"getTask2Exe | {id}");
|
||||
string answ = "";
|
||||
try
|
||||
{
|
||||
@@ -738,7 +743,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("input/{id}")]
|
||||
public string input(string id, string valore, string dtEve, string dtCurr, string cnt)
|
||||
{
|
||||
//Log.Debug($"Chiamata input | {id} | {valore} | {dtEve} | {dtCurr} | {cnt}");
|
||||
Log.Debug($"Chiamata input | {id} | {valore} | {dtEve} | {dtCurr} | {cnt}");
|
||||
string answ = "OK";
|
||||
#if false
|
||||
// formato yyyymmddHHMMSSnnn ovvero da anno a millisecondi
|
||||
@@ -770,14 +775,14 @@ namespace GWMS.UI.Controllers
|
||||
[HttpPost]
|
||||
public void Post([FromBody] string value)
|
||||
{
|
||||
//Log.Debug("Chiamata Post");
|
||||
Log.Debug("Chiamata Post");
|
||||
}
|
||||
|
||||
// PUT api/IOB/5
|
||||
[HttpPut("{id}")]
|
||||
public void Put(int id, [FromBody] string value)
|
||||
{
|
||||
//Log.Debug($"Chiamata Put | {id}");
|
||||
Log.Debug($"Chiamata Put | {id}");
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -791,6 +796,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("remTask2Exe/{id}")]
|
||||
public async Task<string> remTask2Exe(string id, string taskName)
|
||||
{
|
||||
Log.Info($"remTask2Exe | {id} | {taskName}");
|
||||
string answ = "";
|
||||
try
|
||||
{
|
||||
@@ -826,6 +832,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpPost("saveConf/{id}")]
|
||||
public async Task<string> saveConf(string id, [FromBody] System.Text.Json.JsonElement rawQuery)
|
||||
{
|
||||
Log.Info($"saveConf | {id}");
|
||||
// problema deserializzaizone ENUM con classe nuova dotnet 5:
|
||||
// https://github.com/graphql-dotnet/graphql-dotnet/issues/1439
|
||||
|
||||
@@ -863,6 +870,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpPost("sendAlarmBankUpdate/{id}")]
|
||||
public async Task<string> sendAlarmBankUpdate(string id, string memAddr, int index, uint currStatus, [FromBody] List<string> ActiveAlarms)
|
||||
{
|
||||
Log.Info($"sendAlarmBankUpdate | {id}");
|
||||
string answ = "ND";
|
||||
// se id nullo --> KO!
|
||||
if (id == null)
|
||||
@@ -901,7 +909,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpGet("sendReboot")]
|
||||
public string sendReboot(string idxMacchina, string mac)
|
||||
{
|
||||
//Log.Debug($"Chiamata sendReboot | {idxMacchina} | {mac}");
|
||||
Log.Warn($"sendReboot | {idxMacchina} | {mac}");
|
||||
string answ = "";
|
||||
try
|
||||
{
|
||||
@@ -929,6 +937,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpPost("setObjItems/{id}")]
|
||||
public async Task<string> setObjItems(string id, [FromBody] List<objItem> currParams)
|
||||
{
|
||||
Log.Info($"setObjItems | {id}");
|
||||
string answ = "";
|
||||
if (string.IsNullOrWhiteSpace(id))
|
||||
{
|
||||
@@ -955,7 +964,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpPost("uploadFile/{id}")]
|
||||
public string uploadFile(string id)
|
||||
{
|
||||
//Log.Debug($"Chiamata uploadFile | {id}");
|
||||
Log.Debug($"Chiamata uploadFile | {id}");
|
||||
string answ = "";
|
||||
#if false
|
||||
// questa classe è derivata da Controller.Response... x cui recupero lo stream in altro modo...
|
||||
@@ -1002,6 +1011,7 @@ namespace GWMS.UI.Controllers
|
||||
[HttpPost("upsertObjItems/{id}")]
|
||||
public async Task<string> upsertObjItems(string id, [FromBody] List<objItem> innovazioni)
|
||||
{
|
||||
Log.Info($"upsertObjItems | {id}");
|
||||
string answ = "";
|
||||
if (string.IsNullOrWhiteSpace(id))
|
||||
{
|
||||
|
||||
@@ -69,6 +69,7 @@ namespace GWMS.UI.Data
|
||||
{
|
||||
dbController = new GWMS.Data.Controllers.GWMSController(configuration);
|
||||
}
|
||||
_logger.LogInformation("GWMSDataService Started!");
|
||||
}
|
||||
|
||||
#endregion Public Constructors
|
||||
@@ -333,7 +334,7 @@ namespace GWMS.UI.Data
|
||||
|
||||
public PlantLogModel convertFluxToPL(int plantId, flogData origData)
|
||||
{
|
||||
// cerco di ottenere un val in cifre
|
||||
// cerco di ottenere un ValDouble in cifre
|
||||
TimeSpan delta = origData.dtCurr.Subtract(origData.dtEve);
|
||||
PlantLogModel answ = new PlantLogModel()
|
||||
{
|
||||
@@ -982,7 +983,6 @@ namespace GWMS.UI.Data
|
||||
}
|
||||
else
|
||||
{
|
||||
// metto semaforo lettura x 30 sec...
|
||||
int maxRec = 100;
|
||||
int.TryParse(_configuration["MaxLogRecord"], out maxRec);
|
||||
dbResult = dbController.GetPlantsDTO(maxRec);
|
||||
@@ -990,7 +990,7 @@ namespace GWMS.UI.Data
|
||||
await redisDb.StringSetAsync(cacheKey, rawData, LongCache);
|
||||
}
|
||||
sw.Stop();
|
||||
Log.Debug($"PlantDtoGetAll | {readSource} | {sw.ElapsedMilliseconds} ms");
|
||||
Log.Info($"PlantDtoGetAll | {readSource} | {sw.ElapsedMilliseconds} ms");
|
||||
// elimino veto!
|
||||
await ExecFlushRedisPattern(cacheVetoKey);
|
||||
return dbResult;
|
||||
@@ -1488,7 +1488,7 @@ namespace GWMS.UI.Data
|
||||
// se trovato procedo
|
||||
if (trovato != null)
|
||||
{
|
||||
// aggiorno valore richiesto + dt richiesta
|
||||
// aggiorno valore richiesto + DtEvent richiesta
|
||||
trovato.reqValue = reqValue;
|
||||
trovato.lastRequest = DateTime.Now;
|
||||
list2Update.Add(trovato);
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
<Version>1.0.2510.1714</Version>
|
||||
<Version>1.0.2602.2011</Version>
|
||||
<UserSecretsId>95c9f021-52d1-4390-a670-5810b7b777b0</UserSecretsId>
|
||||
<EnableNETAnalyzers>true</EnableNETAnalyzers>
|
||||
<RunAnalyzersDuringBuild>true</RunAnalyzersDuringBuild>
|
||||
|
||||
+5
-3
@@ -24,10 +24,12 @@ namespace GWMS.UI
|
||||
{
|
||||
logging.ClearProviders();
|
||||
#if DEBUG
|
||||
//logging.SetMinimumLevel(Microsoft.Extensions.Logging.LogLevel.Debug);
|
||||
logging.SetMinimumLevel(Microsoft.Extensions.Logging.LogLevel.Information);
|
||||
logging.SetMinimumLevel(Microsoft.Extensions.Logging.LogLevel.Debug);
|
||||
//logging.SetMinimumLevel(Microsoft.Extensions.Logging.LogLevel.Information);
|
||||
#else
|
||||
logging.SetMinimumLevel(Microsoft.Extensions.Logging.LogLevel.Warning);
|
||||
|
||||
logging.SetMinimumLevel(Microsoft.Extensions.Logging.LogLevel.Information);
|
||||
//logging.SetMinimumLevel(Microsoft.Extensions.Logging.LogLevel.Warning);
|
||||
#endif
|
||||
});
|
||||
|
||||
|
||||
@@ -17,6 +17,7 @@
|
||||
"DbConfig": {
|
||||
//"Server": "localhost",
|
||||
"Server": "mdb.ufficio",
|
||||
//"Server": "mdb.ovh",
|
||||
"nKey": "PZZFRR",
|
||||
"sKey": "M3T@n0"
|
||||
},
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<body>
|
||||
<i>GWMS - Gas Warehouse Management System</i>
|
||||
<h4>Versione: 1.0.2510.1714</h4>
|
||||
<h4>Versione: 1.0.2602.2011</h4>
|
||||
<br /> Note di rilascio:
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
@@ -1 +1 @@
|
||||
1.0.2510.1714
|
||||
1.0.2602.2011
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<item>
|
||||
<version>1.0.2510.1714</version>
|
||||
<version>1.0.2602.2011</version>
|
||||
<url>http://nexus.steamware.net/repository/SWS/GWMS/stable/0/GWMS.UI.zip</url>
|
||||
<changelog>http://nexus.steamware.net/repository/SWS/GWMS/stable/0/ChangeLog.html</changelog>
|
||||
<mandatory>false</mandatory>
|
||||
|
||||
Reference in New Issue
Block a user