You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Charge MaxInstance for a viewer that has to be started (#855)
The viewer was exempt from the cap on the grounds that it queues rather
than opening a window per pair. That is true of the second pair and every
one after it, and false of the first: with nothing owning the queue,
AddDiff starts a process. So MaxInstancesToLaunch(0) - "no window opens" -
opened one, and a run with no tray put a viewer on screen per staged
snapshot with nothing available to stop it.
The check goes in ViewerLaunchGate, which is the only place that knows
which of the two is happening, and after the ownership probe. A caller
that asked would charge all twenty of a parallel run's callers for the one
window between them, and the nineteen that find the owner would be capped
out of forwarding their pairs to it.
Capped is its own outcome so AddDiff can report TooManyRunningDiffTools
rather than folding it in with a tool that could not be found.
Copy file name to clipboardExpand all lines: docs/diff-tool.md
+3-1Lines changed: 3 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -48,7 +48,9 @@ This allows, in most cases, for no manual closing of the tool to be required.<!-
48
48
49
49
By default a maximum of 5 tool instances will be launched. This prevents a change that breaks many tests from causing too much load on a machine.
50
50
51
-
This value can be changed using an environment variable or by explicitly specifying the value by code. When both are used, the environment variable value will be used.
51
+
This value can be changed using an environment variable or by explicitly specifying the value by code. When both are used, the value set in code wins; the environment variable is the ambient default for a run that sets nothing.
52
+
53
+
The count includes [DiffEngineViewer](/docs/viewer.md), but only when a viewer has to be started. Handing a pair to one already on screen opens no window and so spends nothing.
Copy file name to clipboardExpand all lines: docs/mdsource/diff-tool.source.md
+3-1Lines changed: 3 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -41,7 +41,9 @@ include: diffToolCleanup
41
41
42
42
By default a maximum of 5 tool instances will be launched. This prevents a change that breaks many tests from causing too much load on a machine.
43
43
44
-
This value can be changed using an environment variable or by explicitly specifying the value by code. When both are used, the environment variable value will be used.
44
+
This value can be changed using an environment variable or by explicitly specifying the value by code. When both are used, the value set in code wins; the environment variable is the ambient default for a run that sets nothing.
45
+
46
+
The count includes [DiffEngineViewer](/docs/viewer.md), but only when a viewer has to be started. Handing a pair to one already on screen opens no window and so spends nothing.
0 commit comments