log disk cache in session stats

This commit is contained in:
Arvid Norberg 2011-03-14 03:35:18 +00:00
parent d012985595
commit ff7bbc6cd0
2 changed files with 9 additions and 2 deletions

View File

@ -60,7 +60,8 @@ gen_report('piece_picker_end_game', ['end game piece picker blocks', 'strict end
gen_report('piece_picker', ['piece picks', 'reject piece picks', 'unchoked piece picks', 'incoming redundant piece picks', 'incoming piece picks', 'end game piece picks', 'snubbed piece picks'])
gen_report('bandwidth', ['% failed payload bytes', '% wasted payload bytes', '% protocol bytes'])
gen_report('disk_time', ['disk read time', 'disk write time', 'disk queue time'])
gen_report('disk_cache', ['disk block read', 'read cache hits', 'disk block written'])
gen_report('disk_cache_hits', ['disk block read', 'read cache hits', 'disk block written'])
gen_report('disk_cache', ['read disk cache size', 'disk cache size', 'disk buffer allocations'])
gen_report('disk_queue', ['disk queue size', 'disk queued bytes'])
gen_report('waste', ['failed bytes', 'redundant bytes', 'download rate'])

View File

@ -936,6 +936,9 @@ namespace aux {
":failed bytes"
":redundant bytes"
":error torrents"
":read disk cache size"
":disk cache size"
":disk buffer allocations"
"\n\n", m_stats_logger);
}
#endif
@ -2702,7 +2705,7 @@ namespace aux {
"%d\t%d\t%d\t%d\t%d\t%d\t%d\t%d\t%d\t%d\t"
"%d\t%d\t%d\t%d\t%d\t%d\t%d\t%d\t%d\t%d\t"
"%f\t%f\t%f\t%d\t%d\t%d\t%d\t%d\t%d\t%d\t"
"%d\t%d\t%d\t%d\n"
"%d\t%d\t%d\t%d\t%d\t%d\t%d\n"
, total_milliseconds(now - m_last_log_rotation) / 1000.f
, int(m_stat.total_upload() - m_last_uploaded)
, int(m_stat.total_download() - m_last_downloaded)
@ -2777,6 +2780,9 @@ namespace aux {
, int(m_total_failed_bytes - m_last_failed)
, int(m_total_redundant_bytes - m_last_redundant)
, error_torrents
, cs.read_cache_size
, cs.cache_size
, cs.total_used_buffers
);
m_last_cache_status = cs;
m_last_failed = m_total_failed_bytes;