diff --git a/src/HotChocolate/Core/src/Execution/Options/RequestExecutorOptions.cs b/src/HotChocolate/Core/src/Execution/Options/RequestExecutorOptions.cs index 2fcf4dda649..be82ccdb016 100644 --- a/src/HotChocolate/Core/src/Execution/Options/RequestExecutorOptions.cs +++ b/src/HotChocolate/Core/src/Execution/Options/RequestExecutorOptions.cs @@ -11,13 +11,27 @@ public class RequestExecutorOptions : IRequestExecutorOptionsAccessor { private const int _minQueryCacheSize = 10; private static readonly TimeSpan _minExecutionTimeout = TimeSpan.FromMilliseconds(100); - private TimeSpan _executionTimeout = TimeSpan.FromSeconds(30); + private TimeSpan _executionTimeout; private int _queryCacheSize = 100; /// - /// Gets or sets maximum allowed execution time of a query. The default - /// value is 30 seconds. The minimum allowed value is 100 - /// milliseconds. + /// Initializes a new instance of . + /// + /// If the debugger is attached () new instances will be + /// initialized with a default of 30 minutes; otherwise, the + /// default will be 30 seconds. + /// + /// + public RequestExecutorOptions() + { + _executionTimeout = Debugger.IsAttached + ? TimeSpan.FromMinutes(30) + : TimeSpan.FromSeconds(30); + } + + /// + /// Gets or sets maximum allowed execution time of a query. + /// The minimum allowed value is 100 milliseconds. /// public TimeSpan ExecutionTimeout {