Skip to content

Commit

Permalink
Merge pull request #1989 from FooQoo/feature/add-99percentile-for-web-ui
Browse files Browse the repository at this point in the history
Add 99%ile for Web UI
  • Loading branch information
cyberw authored Jan 28, 2022
2 parents c33359c + f1f81e2 commit b56fd99
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
4 changes: 4 additions & 0 deletions locust/templates/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,9 @@ <h2>Edit running load test</h2>
<th class="stats_label numeric nowrap" href="#" data-sortkey="num_failures" title="Number of failures"># Fails</th>
<th class="stats_label numeric" href="#" data-sortkey="median_response_time" title="Median response time">Median (ms)</th>
<th class="stats_label numeric" href="#" data-sortkey="ninetieth_response_time" title="Ninetieth percentile response time, because the response time greater than 100ms is rounded, you may see it greater than the max response time">90%ile (ms)</th>
<th class="stats_label numeric" href="#" data-sortkey="ninety_ninth_response_time"
title="Ninety-ninth percentile response time, because the response time greater than 100ms is rounded, you may see it greater than the max response time">
99%ile (ms)</th>
<th class="stats_label numeric" href="#" data-sortkey="avg_response_time" title="Average response time">Average (ms)</th>
<th class="stats_label numeric" href="#" data-sortkey="min_response_time" title="Min response time">Min (ms)</th>
<th class="stats_label numeric" href="#" data-sortkey="max_response_time" title="Max response time">Max (ms)</th>
Expand Down Expand Up @@ -284,6 +287,7 @@ <h2>Version <a href="https://github.com/locustio/locust/releases/tag/{{version}}
<td class="numeric"><%= this.num_failures %></td>
<td class="numeric"><%= Math.round(this.median_response_time) %></td>
<td class="numeric"><%= Math.round(this.ninetieth_response_time) %></td>
<td class="numeric"><%= Math.round(this.ninety_ninth_response_time) %></td>
<td class="numeric"><%= Math.round(this.avg_response_time) %></td>
<td class="numeric"><%= this.min_response_time %></td>
<td class="numeric"><%= this.max_response_time %></td>
Expand Down
1 change: 1 addition & 0 deletions locust/web.py
Original file line number Diff line number Diff line change
Expand Up @@ -272,6 +272,7 @@ def request_stats():
"current_fail_per_sec": s.current_fail_per_sec,
"median_response_time": s.median_response_time,
"ninetieth_response_time": s.get_response_time_percentile(0.9),
"ninety_ninth_response_time": s.get_response_time_percentile(0.99),
"avg_content_length": s.avg_content_length,
}
)
Expand Down

0 comments on commit b56fd99

Please sign in to comment.