mirror of
https://git.tt-rss.org/git/tt-rss.git
synced 2025-12-13 09:15:55 +00:00
daemon: show feeds/minute stats
This commit is contained in:
@@ -246,10 +246,12 @@
|
||||
// Call to the feed batch update function
|
||||
// or regenerate feedbrowser cache
|
||||
|
||||
$nf = 0;
|
||||
|
||||
if (rand(0,100) > 30) {
|
||||
_debug("Waiting before update..");
|
||||
sleep(rand(5,15));
|
||||
update_daemon_common($link);
|
||||
$nf = update_daemon_common($link);
|
||||
} else {
|
||||
$count = update_feedbrowser_cache($link);
|
||||
_debug("Feedbrowser updated, $count feeds processed.");
|
||||
@@ -266,6 +268,10 @@
|
||||
|
||||
_debug("Elapsed time: " . (time() - $start_timestamp) . " second(s)");
|
||||
|
||||
if ($nf > 0) {
|
||||
_debug("Feeds processed: $nf; feeds/minute: " . sprintf("%.2d", $nf/((time()-$start_timestamp)/60)));
|
||||
}
|
||||
|
||||
db_close($link);
|
||||
|
||||
// We are in a fork.
|
||||
|
||||
Reference in New Issue
Block a user