~sysbench-developers/sysbench/0.4

Viewing all changes in revision 90.

  • Committer: Alexey Kopytov
  • Date: 2012-10-31 18:30:24 UTC
  • Revision ID: akopytov@gmail.com-20121031183024-7ykrxv7mto76uxvy
Bug #1073672: --forced-shutdown does not reflect stuck transactions in
              stats

When --forced-shutdown is used, it prints the currently collected
statistics and terminates without waiting for worker threads to
complete. This was implemented to be able to complete benchmark even
if we have some long running or stuck transactions.

The problem is that unfinished transactions are not reflected in
statistics. So, for example, if we do have stuck transactions that
have been stuck for the entire test duration, their timers will still
be running on forced shutdown and thus, statistics will only show
transactions performed by other threads, if any.

The fix is stop all timers on forced shutdown, so even stuck
transactions are accounted with (forced_shutdown_time -
trx_start_time) duration. Also printing the number of currently
running transactions at the time of forced shutdown would also make
sense.

expand all expand all

Show diffs side-by-side

added added

removed removed

Lines of Context: