Repository navigation
Expand file tree
/
Copy pathappsettings.json
More file actions
44 lines (44 loc) · 3.04 KB
/
Copy pathappsettings.json
File metadata and controls
44 lines (44 loc) · 3.04 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
{
"Logging": {
"LogLevel": {
"Default": "Information",
"Microsoft.AspNetCore": "Warning"
}
},
"AllowedHosts": "*",
"QuantumSolver": {
"BaseURL": "http://localhost:27100"
},
// TimeLimitSeconds: the time limit, in seconds, of every compute request but visualize: solve, verify, reduce,
// mapSolution, gadgets and visualizeReduction (#935), and in a worker process mapSolutionBack too (#991). A job that
// runs past it is stopped and answers HTTP 422 with error "time_limit". Zero or less turns the limit off. It is a
// backstop: the size and Big-O precheck below (step 3 of #915, #843) refuses a job too big to finish.
// Visualize stops at this limit or 10 seconds, whichever is shorter, because the frontends show "Loading..." until
// the picture arrives; a visualize that reaches its limit still answers, with the picture of the run so far. Setting
// "Visualization:SolveTimeLimitSeconds" (#885) decides the visualize limit on its own instead.
// MaxConcurrentJobs: how many of those jobs may run at once (#936). When all are in use, a new one is turned away at
// once with HTTP 429 and error "server_busy". Unset means the number of processors (at least 2); zero or less turns
// the cap off.
// IsolateSolves: run each compute job (solve since #936; verify, reduce, mapSolution, mapSolutionBack, gadgets,
// visualize and visualizeReduction since #991) in a worker process of its own, so a job that does not stop at the time
// limit is killed (the computation is really cancelled) and a job can have a memory limit. The server keeps one warm
// worker per job slot (MaxConcurrentJobs) started ahead of time. False runs every job inside the server, as before,
// where the time limit only stops the server waiting. The name is from when only solves moved.
// SolveMemoryMB: the memory limit, in megabytes, of a compute job (of any endpoint) in a worker. A job that needs more
// answers HTTP 422 with error "memory_limit". Zero or less turns the limit off.
// PrecheckStepsPerSecond and PrecheckMargin: the size and Big-O precheck (#843). Before a solve starts (visualize: #1025),
// the server evaluates the solver's declared timeComplexity on the instance's size (|N|, |E|, K, ... as the problem
// reports them) and refuses the job at once, with HTTP 422 and error "too_large", when the estimate is more than
// PrecheckMargin times the steps that fit in the time limit at PrecheckStepsPerSecond. Big-O has no constant
// factors, so the rate is measured on brute-force solvers (1e9 is the fastest seen, rounded up; the measurements are
// in Interfaces/ComputePrecheck.cs) and the margin leaves borderline jobs to the timer. Solvers whose problem reports
// no size measures, solvers that prune their search, and quantum solvers are never refused. Zero or less for either turns the
// precheck off.
"ComputeLimits": {
"TimeLimitSeconds": 30,
"IsolateSolves": true,
"SolveMemoryMB": 512,
"PrecheckStepsPerSecond": 1000000000,
"PrecheckMargin": 100
}
}