Skip to content

Commit

Permalink
Attempt to lower excessive logging
Browse files Browse the repository at this point in the history
  • Loading branch information
mikejobson committed May 14, 2024
1 parent e8f87d8 commit 9bd6156
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 13 deletions.
4 changes: 2 additions & 2 deletions UXAV.AVnet.Core/DeviceSupport/CipDevices.cs
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,7 @@ internal static void RegisterDevices()
var result = device.Register();
if (result == eDeviceRegistrationUnRegistrationResponse.Success)
{
Logger.Log($"Registered device: {device}");
Logger.Debug($"Registered device: {device}");
continue;
}

Expand All @@ -251,7 +251,7 @@ internal static void RegisterFusionRooms()
var result = device.Register();
if (result == eDeviceRegistrationUnRegistrationResponse.Success)
{
Logger.Success($"Registered device: {device}");
Logger.Debug($"Registered device: {device}");
continue;
}

Expand Down
4 changes: 2 additions & 2 deletions UXAV.AVnet.Core/DeviceSupport/DeviceBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ protected DeviceBase(SystemBase system, string name, uint roomIdAllocated = 0)
{
if (type == eProgramStatusEventType.Stopping) OnProgramStopping();
};
Logger.Log($"Created device {GetType().Name} \"{Name}\" with device ID {Id}");
Logger.Debug($"Created device {GetType().Name} \"{Name}\" with device ID {Id}");
}

protected DeviceBase(string name, uint roomIdAllocated = 0)
Expand All @@ -42,7 +42,7 @@ protected DeviceBase(string name, uint roomIdAllocated = 0)
{
if (type == eProgramStatusEventType.Stopping) OnProgramStopping();
};
Logger.Log($"Created device {GetType().Name} \"{Name}\" with device ID {Id}");
Logger.Debug($"Created device {GetType().Name} \"{Name}\" with device ID {Id}");
}

[Obsolete("Method is no longer used. Please use ctor(name, room).")]
Expand Down
18 changes: 9 additions & 9 deletions UXAV.AVnet.Core/Models/SystemBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -707,7 +707,7 @@ protected void UpdateBootStatus(EBootStatus status, string description, uint pro
BootStatus = status;
BootStatusDescription = description;
BootProgress = progress;
Logger.Log("Boot status set to {0}, {1} ({2}%)", status, description, progress);
Logger.Debug("Boot status set to {0}, {1} ({2}%)", status, description, progress);
EventService.Notify(EventMessageType.BootStatus, new
{
status,
Expand Down Expand Up @@ -877,7 +877,7 @@ private void InitializeTask()
UpdateBootStatus(EBootStatus.Initializing, "Registering CIP devices not already registered", 10);
CipDevices.RegisterDevices();

Logger.Highlight("WebScriptingHandlersShouldRegister()");
Logger.Debug("WebScriptingHandlersShouldRegister()");
try
{
WebScriptingHandlersShouldRegister();
Expand Down Expand Up @@ -905,7 +905,7 @@ private void InitializeTask()
itemCount++;
UpdateBootStatus(EBootStatus.Initializing, "Initializing " + item.Name,
(uint)Tools.ScaleRange(itemCount, 0, itemMaxCount, startPercentage, targetPercentage));
Logger.Highlight("Initializing {0}", item.ToString());
Logger.Debug("Initializing {0}", item.ToString());
item.Initialize();
Thread.Sleep(50);
}
Expand All @@ -925,7 +925,7 @@ private void InitializeTask()
itemCount++;
UpdateBootStatus(EBootStatus.Initializing, "Initializing " + room,
(uint)Tools.ScaleRange(itemCount, 0, itemMaxCount, startPercentage, targetPercentage));
Logger.Highlight("Initializing room: {0}", room);
Logger.Debug("Initializing room: {0}", room);
room.InternalInitialize();
}

Expand All @@ -942,7 +942,7 @@ private void InitializeTask()
itemCount++;
UpdateBootStatus(EBootStatus.Initializing, "Initializing " + source,
(uint)Tools.ScaleRange(itemCount, 0, itemMaxCount, startPercentage, targetPercentage));
Logger.Highlight("Initializing source: {0}", source);
Logger.Debug("Initializing source: {0}", source);
source.InternalInitialize();
}

Expand All @@ -964,11 +964,11 @@ private void InitializeTask()

Thread.Sleep(200);
UpdateBootStatus(EBootStatus.Initializing, "Generating RVI file info for Fusion", 70);
Logger.Highlight("Generating Fusion RVI File");
Logger.Debug("Generating Fusion RVI File");
try
{
FusionRVI.GenerateFileForAllFusionDevices();
Logger.Success("Generated Fusion RVI file");
Logger.Debug("Generated Fusion RVI file");
try
{
var dir = new DirectoryInfo(ProgramApplicationDirectory);
Expand Down Expand Up @@ -1013,7 +1013,7 @@ private void InitializeTask()
Thread.Sleep(500);
if (Ch5WebSocketServer.InitCalled)
{
Logger.Highlight("Starting CH5 websocket services");
Logger.Log("Starting CH5 websocket services");
Thread.Sleep(1000);
Ch5WebSocketServer.Start();
Thread.Sleep(2000);
Expand All @@ -1022,7 +1022,7 @@ private void InitializeTask()
if (Core3Controllers.Count > 0)
{
UpdateBootStatus(EBootStatus.Initializing, "Initializing Core 3 UI Controllers", 95);
Logger.Highlight("Initializing Core 3 UI Controllers");
Logger.Log("Initializing Core 3 UI Controllers");
InitializeCore3Controllers();
}

Expand Down

0 comments on commit 9bd6156

Please sign in to comment.