Skip to content

Commit d50939a

Browse files
author
rhamlett_microsoft
committed
Another fix for request timeouts
1 parent 5f6363f commit d50939a

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/PerfProblemSimulator/wwwroot/js/dashboard.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -527,6 +527,9 @@ function handleSlowRequestLatency(data) {
527527
// If negative (processing was faster than expected?), clamp to 0
528528
const queueTimeMs = Math.max(0, latencyMs - expectedMs);
529529

530+
// Flag as timeout if total time exceeds threshold (30s)
531+
const isTimeout = latencyMs >= CONFIG.latencyTimeoutMs;
532+
530533
// Add to slow request history
531534
const history = state.slowRequestHistory;
532535
history.timestamps.push(timestamp);
@@ -541,8 +544,8 @@ function handleSlowRequestLatency(data) {
541544
}
542545

543546
// Add as a special latency point on the chart (it will show as a large spike)
544-
addLatencyToHistory(timestamp, latencyMs, false, isError);
545-
updateLatencyDisplay(latencyMs, false, isError);
547+
addLatencyToHistory(timestamp, latencyMs, isTimeout, isError);
548+
updateLatencyDisplay(latencyMs, isTimeout, isError);
546549
updateLatencyChart();
547550

548551
// Log the slow request completion with Queue Time breakdown

0 commit comments

Comments
 (0)