Update monitor and Tmux.php,

This commit is contained in:
DariusIII
2015-08-31 01:17:31 +02:00
parent 9a87f9da4f
commit 78b543f9a3
2 changed files with 3 additions and 12 deletions
@@ -49,7 +49,7 @@ $runVar['timers']['query']['tpg1_time'] = 0;
// Analyze release table if not using innoDB (innoDB uses online analysis)
$engine = $pdo->queryOneRow(sprintf("SELECT ENGINE FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_SCHEMA = %s AND TABLE_NAME = 'releases'", $pdo->escapeString($db_name)));
if ($engine['engine'] != 'InnoDB') {
if (!in_array($engine['engine'], ['InnoDB', 'TokuDB'])) {
printf($pdo->log->info("\nAnalyzing your tables to refresh your indexes."));
$pdo->optimise(false, 'analyze', false, ['releases']);
Utility::clearScreen();
@@ -183,8 +183,6 @@ while ($runVar['counts']['iterations'] > 0) {
$runVar['timers']['query']['proc21_time'] = (time() - $timer01);
$timer06 = time();
$proc3qry = $tRun->proc_query(3, $runVar['settings']['book_reqids'], $runVar['settings']['request_hours'], $db_name);
$proc3res = $pdo->queryOneRow(($proc3qry !== false ? $proc3qry : ''), $tRun->rand_bool($runVar['counts']['iterations']));
$runVar['timers']['query']['proc3_time'] = (time() - $timer06);
$runVar['timers']['query']['proc31_time'] = (time() - $timer01);
@@ -267,16 +265,9 @@ while ($runVar['counts']['iterations'] > 0) {
} else {
errorOnSQL($pdo);
}
if (is_array($proc3res)) {
foreach ($proc3res AS $proc3key => $proc3) {
$runVar['counts']['now'][$proc3key] = $proc3;
}
} else {
errorOnSQL($pdo);
}
// now that we have merged our query data we can unset these to free up memory
unset($proc1res, $proc2res, $proc3res, $splitres);
unset($proc1res, $proc2res, $splitres);
// Zero out any post proc counts when that type of pp has been turned off
foreach ($runVar['settings'] as $settingkey => $setting) {
+1 -1
View File
@@ -397,7 +397,7 @@ class Tmux
SUM(IF(prehashid > 0 AND nzbstatus = 1 AND isrequestid = 1 AND reqidstatus = 1,1,0)) AS requestid_matched,
SUM(IF(prehashid > 0 AND searchname IS NOT NULL,1,0)) AS prehash_matched,
SUM(IF(preid > 0 AND searchname IS NOT NULL,1,0)) AS predb_matched,
COUNT(DISTINCT(preid)) AS distinct_predb_matched
COUNT(DISTINCT(preid)) AS distinct_predb_matched,
COUNT(DISTINCT(prehashid)) AS distinct_prehash_matched
FROM releases r", $bookreqids, Info::NfoQueryString($this->pdo), $request_hours);
case 2: