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
143461: sql: fix flake in EXPLAIN ANALYZE contention time stats r=yuzefovich a=DrewKimball
We recently added latch wait time to the cumulative contention time reported for plan nodes that perform KV operations (#113649). This is causing a few `EXPLAIN ANALYZE` tests to flake because mutation operators in particular only report the contention time metric if it is nonzero. Latch wait time is more likely to be nonzero than lock wait time in response to load on the node, so sensitive tests are now occasionally failing.
This commit fixes the flake by always reporting the contention time metrics for mutation operators just like the read-only operators that report similar metrics (e.g. Scan, LookupJoin etc.). The reporting is also restricted to `planNodeToRowSource` instances that wrap a mutation to avoid polluting the explain output for other `planNode` types.
Fixes#143406Fixes#143453Fixes#143468
Release note: None
Co-authored-by: Drew Kimball <[email protected]>
0 commit comments