From 7248a4645210007b01df077bbde4f6e3b96a6028 Mon Sep 17 00:00:00 2001 From: Mike Phares Date: Tue, 6 Dec 2022 10:01:14 -0700 Subject: [PATCH] v2.47.1 - ISQ query in OI file name when PSN and Reactor is present --- Adaptation/FileHandlers/OpenInsight/FileRead.cs | 8 ++++++-- Adaptation/FileHandlers/OpenInsight/FromIQS.cs | 5 +++-- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/Adaptation/FileHandlers/OpenInsight/FileRead.cs b/Adaptation/FileHandlers/OpenInsight/FileRead.cs index 91240b6..a8ab718 100644 --- a/Adaptation/FileHandlers/OpenInsight/FileRead.cs +++ b/Adaptation/FileHandlers/OpenInsight/FileRead.cs @@ -247,13 +247,17 @@ public class FileRead : Shared.FileRead, IFileRead string lines = GetLines(_Logistics, descriptions); if (!string.IsNullOrEmpty(lines)) { + long? subGroupId; long breakAfter = dateTime.AddSeconds(_BreakAfterSeconds).Ticks; long preWait = _FileConnectorConfiguration?.FileHandleWaitTime is null ? dateTime.AddMilliseconds(1234).Ticks : dateTime.AddMilliseconds(_FileConnectorConfiguration.FileHandleWaitTime.Value).Ticks; - (long? subGroupId, string _) = FromIQS.GetCommandText(_BreakAfterSeconds, _IqsConnectionString, _Logistics, descriptions[0], breakAfter, preWait); + if (string.IsNullOrEmpty(descriptions[0].Reactor) || string.IsNullOrEmpty(descriptions[0].PSN) || string.IsNullOrEmpty(descriptions[0].RDS)) + subGroupId = null; + else + (subGroupId, string _) = FromIQS.GetCommandText(_IqsConnectionString, _Logistics, descriptions[0], breakAfter, preWait); if (subGroupId is null) collection.Add(new(new ScopeInfo(tests[0], _OpenInsightFilePattern), lines)); else - collection.Add(new(new ScopeInfo(tests[0], $"{subGroupId.Value}_{_OpenInsightFilePattern}"), lines)); + collection.Add(new(new ScopeInfo(tests[0], $"{subGroupId.Value} {_OpenInsightFilePattern}"), lines)); } } if (_IsEAFHosted && _FileConnectorConfiguration.FileScanningIntervalInSeconds > 0) diff --git a/Adaptation/FileHandlers/OpenInsight/FromIQS.cs b/Adaptation/FileHandlers/OpenInsight/FromIQS.cs index ace488f..c316cfd 100644 --- a/Adaptation/FileHandlers/OpenInsight/FromIQS.cs +++ b/Adaptation/FileHandlers/OpenInsight/FromIQS.cs @@ -67,7 +67,7 @@ public class FromIQS return stringBuilder; } - internal static (long?, string) GetCommandText(long breakAfterSeconds, string connectionString, Logistics logistics, pcl.Description description, long breakAfter, long preWait) + internal static (long?, string) GetCommandText(string connectionString, Logistics logistics, pcl.Description description, long breakAfter, long preWait) { string dateTime; string commandText; @@ -93,7 +93,8 @@ public class FromIQS if (stringBuilder.Length > 0) break; if (DateTime.Now.Ticks > breakAfter) - throw new Exception($"After {breakAfterSeconds} seconds, didn't find sub group id!"); + // throw new Exception($"After {breakAfterSeconds} seconds, didn't find sub group id!"); + break; Thread.Sleep(250); } if (stringBuilder.Length == 0)