diff --git a/osu.Server.Queues.ScoreStatisticsProcessor/Commands/Queue/WatchQueueCommand.cs b/osu.Server.Queues.ScoreStatisticsProcessor/Commands/Queue/WatchQueueCommand.cs index 75023af9..64bd6bb1 100644 --- a/osu.Server.Queues.ScoreStatisticsProcessor/Commands/Queue/WatchQueueCommand.cs +++ b/osu.Server.Queues.ScoreStatisticsProcessor/Commands/Queue/WatchQueueCommand.cs @@ -19,6 +19,16 @@ public class WatchQueueCommand public Task OnExecuteAsync(CancellationToken cancellationToken) { + string? disabledProcessorsEnv = Environment.GetEnvironmentVariable("DISABLED_PROCESSORS"); + + if (!string.IsNullOrEmpty(disabledProcessorsEnv)) + { + if (!string.IsNullOrEmpty(DisabledProcessors)) + throw new ArgumentException("Attempted to specify disabled processors via parameter and environment at the same time"); + + DisabledProcessors = disabledProcessorsEnv; + } + ScoreStatisticsQueueProcessor queue = new ScoreStatisticsQueueProcessor(DisabledProcessors.Split(',', StringSplitOptions.TrimEntries | StringSplitOptions.RemoveEmptyEntries)); queue.Run(cancellationToken);