From 072d0c956effc8dc1971ff1ca947037fdb4f0b8d Mon Sep 17 00:00:00 2001 From: windpacer Date: Sun, 26 Apr 2026 11:26:13 +0900 Subject: [PATCH] =?UTF-8?q?fix(#6):=20Dispose=20null=20=EC=98=88=EC=99=B8?= =?UTF-8?q?=20=EB=A1=9C=EA=B9=85=20=EC=B6=94=EA=B0=80=20(=EB=A6=AC?= =?UTF-8?q?=EC=86=8C=EC=8A=A4=20=EC=A0=95=EB=A6=AC=20=EC=8B=A4=ED=8C=A8=20?= =?UTF-8?q?=EB=AA=A8=EB=8B=88=ED=84=B0=EB=A7=81)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/Infrastructure/OpcUa/ExperionOpcServerService.cs | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/Infrastructure/OpcUa/ExperionOpcServerService.cs b/src/Infrastructure/OpcUa/ExperionOpcServerService.cs index f51e7da..adfe5a0 100644 --- a/src/Infrastructure/OpcUa/ExperionOpcServerService.cs +++ b/src/Infrastructure/OpcUa/ExperionOpcServerService.cs @@ -283,7 +283,13 @@ public class ExperionOpcServerService : IExperionOpcServerService, IHostedServic _server?.Stop(); #pragma warning restore CS0618 // 'Stop()' is obsolete } - catch { /* ignore */ } - _server = null; + catch (Exception ex) + { + _logger.LogWarning(ex, "[OpcServer] Dispose 중 예외 발생 - 리소스 모니터링 필요"); + } + finally + { + _server = null; + } } }