More logging

This commit is contained in:
Mike Phares 2024-07-30 14:06:02 -07:00
parent e6442fff9f
commit 38340090be
3 changed files with 6 additions and 52 deletions

4
.gitignore vendored
View File

@ -331,4 +331,6 @@ ASALocalRun/
*.all
*.pcl
*.pdf
*.raw
*.raw
.vscode/.UserSecrets/secrets.json

View File

@ -1,51 +0,0 @@
{
"_Application": "File-Watcher",
"_UserSecretsId": "6062c774-99a9-4f4a-b42d-a9cb7fcbd8be",
"BuildNumber": "1234",
"ConfigurationDirectoryNames": [
"Microsoft",
"UserSecrets",
"6062c774-99a9-4f4a-b42d-a9cb7fcbd8be"
],
"ConfigurationSpecialFolder": 26,
"ConfigurationFileName": "file-watcher.json",
"Company": "Infineon Technologies Americas Corp.",
"GitCommitSeven": "asdf",
"HelperX": "HelperTCP",
"HelperXX": "HelperNuget",
"HelperXXX": "HelperEAFLog",
"HelperXXXX": "HelperSerial",
"HelperXXXXX": "HelperCompass",
"Helper": "HelperStratus",
"HelperXXXXXXX": "HelperEventLog",
"HelperXXXXXXXX": "HelperInfinityQS",
"HelperXXXXXXXXX": "HelperWaferCounter",
"HelperXXXXXXXXXX": "HelperEAFProgramData",
"HelperXXXXXXXXXXX": "HelperMetrologyFiles",
"Logging:Console:FormatterName": "simple",
"Logging:Console:FormatterOptions:IncludeScopes": "True",
"Logging:Console:FormatterOptions:SingleLine": "True",
"Logging:Console:FormatterOptions:TimestampFormat": "HH:mm:ss ",
"Logging:Console:FormatterOptions:UseUtcTimestamp": "True",
"Logging:Console:LogLevel:Default": "Information",
"Logging:Console:LogLevel:Microsoft": "Warning",
"Logging:Console:LogLevel:Microsoft.Hosting.Lifetime": "Information",
"Logging:Debug:FormatterName": "simple",
"Logging:Debug:FormatterOptions:IncludeScopes": "True",
"Logging:Debug:FormatterOptions:SingleLine": "True",
"Logging:Debug:FormatterOptions:TimestampFormat": "HH:mm:ss ",
"Logging:Debug:FormatterOptions:UseUtcTimestamp": "True",
"Logging:Debug:LogLevel:Default": "Warning",
"Logging:Debug:LogLevel:Microsoft": "Information",
"Logging:Debug:LogLevel:Microsoft.Hosting.Lifetime": "Debug",
"Logging:EventLog:LogLevel:Default": "Warning",
"Logging:EventSource:LogLevel:Default": "Warning",
"Logging:LogLevel:Default": "Debug",
"Logging:LogLevel:Microsoft": "Information",
"Logging:LogLevel:Microsoft.Hosting.Lifetime": "Debug",
"MillisecondsDelay": 54000,
"URLs": "http://localhost:5003;",
"WatchDirectory": "D:/Tmp/Phares/Event-Log",
"WatchDirectoryXX": "D:/EAF/EAF Instances",
"WatchDirectoryXXX": "C:/software/WaferCounter/V203"
}

View File

@ -52,7 +52,10 @@ public partial class Worker : BackgroundService
private async Task Body(CancellationToken cancellationToken)
{
if (!_IsWindowsService)
{
_Logger.LogInformation("Set break point and skip to run {_AppSettings.Helper}!", _AppSettings.Helper);
throw new EvaluateException($"Set break point and skip to run {_AppSettings.Helper}!");
}
if (!_IsWindowsService)
{
for (int i = 0; i < int.MaxValue; i++)