规范并补充日志内容
This commit is contained in:
@@ -1,4 +1,7 @@
|
||||
namespace SHH.CameraSdk;
|
||||
using Ayay.SerilogLogs;
|
||||
using Serilog;
|
||||
|
||||
namespace SHH.CameraSdk;
|
||||
|
||||
/// <summary>
|
||||
/// 帧处理管道(后台处理核心)
|
||||
@@ -12,6 +15,8 @@ public class ProcessingPipeline
|
||||
{
|
||||
#region --- 私有资源与状态 (Private Resources & States) ---
|
||||
|
||||
private static ILogger _sysLog = Log.ForContext("SourceContext", LogModules.Core);
|
||||
|
||||
/// <summary> 任务队列(有界通道):存储待处理的帧任务 </summary>
|
||||
private readonly Channel<ProcessingTask> _queue;
|
||||
|
||||
@@ -135,7 +140,7 @@ public class ProcessingPipeline
|
||||
catch (Exception ex)
|
||||
{
|
||||
// 捕获处理过程中的异常,避免影响后续任务执行
|
||||
Console.WriteLine($"[PipelineError] 帧处理失败 (DeviceId: {task.DeviceId}, Seq: {task.Decision.Sequence}): {ex.Message}");
|
||||
_sysLog.Error($"[Pipeline] 帧处理失败 (DeviceId: {task.DeviceId}, Seq: {task.Decision.Sequence}): {ex.Message}");
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user