aboutsummaryrefslogtreecommitdiffstats
path: root/Software
diff options
context:
space:
mode:
authorRoy Ben Shabat <roy.mail.net@gmail.com>2025-09-01 02:33:22 +0300
committerRoy Ben Shabat <roy.mail.net@gmail.com>2025-09-01 02:33:22 +0300
commit1d8115b0221779497d2cf33378b970b04a833d03 (patch)
treed9e9dbf640aa3b9304534fafe0fbde4fb0c57592 /Software
parentd9e07aff4a8160de7ce19ea536e69ed8f9a7a6d5 (diff)
downloadTango-1d8115b0221779497d2cf33378b970b04a833d03.tar.gz
Tango-1d8115b0221779497d2cf33378b970b04a833d03.zip
Fixed telemetry logs cyclic loop
Diffstat (limited to 'Software')
-rw-r--r--Software/Visual_Studio/PPC/Tango.PPC.UI/App.config5
-rw-r--r--Software/Visual_Studio/PPC/Tango.PPC.UI/Telemetry/DefaultTelemetryProvider.cs1
-rw-r--r--Software/Visual_Studio/Tango.Telemetry/ITelemetryStorageManager.cs2
-rw-r--r--Software/Visual_Studio/Tango.Telemetry/Sources/TelemetryLogsStreamingSource.cs2
-rw-r--r--Software/Visual_Studio/Tango.Telemetry/TelemetryLiteDBStorageManager.cs1
-rw-r--r--Software/Visual_Studio/Tango.Telemetry/TelemetryPublisher.cs1
6 files changed, 11 insertions, 1 deletions
diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/App.config b/Software/Visual_Studio/PPC/Tango.PPC.UI/App.config
index 53a599bee..8539cda46 100644
--- a/Software/Visual_Studio/PPC/Tango.PPC.UI/App.config
+++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/App.config
@@ -135,6 +135,11 @@
<bindingRedirect oldVersion="0.0.0.0-4.2.0.0" newVersion="4.2.0.0" />
</dependentAssembly>
+
+ <dependentAssembly>
+ <assemblyIdentity name="Microsoft.Extensions.Logging.Abstractions" publicKeyToken="adb9793829ddae60" culture="neutral" />
+ <bindingRedirect oldVersion="0.0.0.0-99.9.9.9" newVersion="1.1.1.0" />
+ </dependentAssembly>
</assemblyBinding>
</runtime>
diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Telemetry/DefaultTelemetryProvider.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/Telemetry/DefaultTelemetryProvider.cs
index 31646c709..6d72e618c 100644
--- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Telemetry/DefaultTelemetryProvider.cs
+++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Telemetry/DefaultTelemetryProvider.cs
@@ -231,6 +231,7 @@ namespace Tango.PPC.UI.Telemetry
public void Dispose()
{
TelemetryPublisher?.Dispose();
+ TelemetryPublisher?.StorageManager.Dispose();
}
}
}
diff --git a/Software/Visual_Studio/Tango.Telemetry/ITelemetryStorageManager.cs b/Software/Visual_Studio/Tango.Telemetry/ITelemetryStorageManager.cs
index 882cc0411..9376f6adf 100644
--- a/Software/Visual_Studio/Tango.Telemetry/ITelemetryStorageManager.cs
+++ b/Software/Visual_Studio/Tango.Telemetry/ITelemetryStorageManager.cs
@@ -9,7 +9,7 @@ namespace Tango.Telemetry
/// <summary>
/// Defines the contract for managing telemetry storage, including pending telemetries and history source checkpoints.
/// </summary>
- public interface ITelemetryStorageManager
+ public interface ITelemetryStorageManager : IDisposable
{
/// <summary>
/// Initializes the storage manager with the specified checkpoints recovery client.
diff --git a/Software/Visual_Studio/Tango.Telemetry/Sources/TelemetryLogsStreamingSource.cs b/Software/Visual_Studio/Tango.Telemetry/Sources/TelemetryLogsStreamingSource.cs
index 2c8020f7c..2f592f22a 100644
--- a/Software/Visual_Studio/Tango.Telemetry/Sources/TelemetryLogsStreamingSource.cs
+++ b/Software/Visual_Studio/Tango.Telemetry/Sources/TelemetryLogsStreamingSource.cs
@@ -64,6 +64,8 @@ namespace Tango.Telemetry.Sources
if (IsStarted)
{
if (!Config.Categories.Contains(log.Category)) return;
+ if (log.ClassName != null && log.ClassName.StartsWith("Telemetry")) return;
+
TelemetryLog tLog = LogMapper.MapLog(log);
TelemetryAvailable?.Invoke(this, new TelemetryAvailableEventArgs() { TelemetryObject = tLog });
diff --git a/Software/Visual_Studio/Tango.Telemetry/TelemetryLiteDBStorageManager.cs b/Software/Visual_Studio/Tango.Telemetry/TelemetryLiteDBStorageManager.cs
index ab0ff2b58..13781d6dc 100644
--- a/Software/Visual_Studio/Tango.Telemetry/TelemetryLiteDBStorageManager.cs
+++ b/Software/Visual_Studio/Tango.Telemetry/TelemetryLiteDBStorageManager.cs
@@ -251,6 +251,7 @@ namespace Tango.Telemetry
try
{
_disposed = true;
+ _database.Checkpoint();
_database.Dispose();
_database = null;
}
diff --git a/Software/Visual_Studio/Tango.Telemetry/TelemetryPublisher.cs b/Software/Visual_Studio/Tango.Telemetry/TelemetryPublisher.cs
index 07b421406..8c05524ed 100644
--- a/Software/Visual_Studio/Tango.Telemetry/TelemetryPublisher.cs
+++ b/Software/Visual_Studio/Tango.Telemetry/TelemetryPublisher.cs
@@ -1008,6 +1008,7 @@ namespace Tango.Telemetry
{
try
{
+ Debug.WriteLine($"[TELEMETRY] Package Publish Result Available: {result}");
PublishResultAvailable?.Invoke(this, new TelemetryPublishResultAvailableEventArgs() { Package = package, PublishResult = result });
}
catch { }