Your ROOT_URL in app.ini is https://git.cloudchain.link/ but you are visiting https://dash.bss.nz/open-source-mirrors/Prowlarr/blame/commit/b07bc713bb8574f8d7672c797360c66ff1f68817/NzbDrone.Host/PriorityMonitor.cs You should set ROOT_URL correctly, otherwise the web may not work correctly.
Prowlarr/NzbDrone.Host/PriorityMonitor.cs

44 lines
1.2 KiB

using System;
using System.Diagnostics;
using System.Threading;
using NLog;
using NzbDrone.Common;
namespace NzbDrone.Host
{
12 years ago
public class PriorityMonitor
{
private readonly IProcessProvider _processProvider;
12 years ago
private readonly Logger _logger;
private Timer _processPriorityCheckTimer;
public PriorityMonitor(IProcessProvider processProvider, Logger logger)
{
_processProvider = processProvider;
12 years ago
_logger = logger;
}
public void Start()
{
_processPriorityCheckTimer = new Timer(EnsurePriority);
_processPriorityCheckTimer.Change(TimeSpan.FromSeconds(15), TimeSpan.FromMinutes(30));
}
public virtual void EnsurePriority(object sender)
{
try
{
if (_processProvider.GetCurrentProcessPriority() != ProcessPriorityClass.Normal)
{
_processProvider.SetPriority(_processProvider.GetCurrentProcess().Id, ProcessPriorityClass.Normal);
}
}
catch (Exception e)
{
12 years ago
_logger.WarnException("Unable to verify priority", e);
}
}
}
}