From: Tim Düsterhus Date: Fri, 27 Aug 2021 09:41:15 +0000 (+0200) Subject: Remove InnoDB check for search engine from SystemCheckPage X-Git-Tag: 5.5.0_Alpha_1~464^2~1 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=b7091119c3f5f11073224c44f7199d31e729671e;p=GitHub%2FWoltLab%2FWCF.git Remove InnoDB check for search engine from SystemCheckPage Using MyISAM for the search engine does not actually break anything (in contrast to using InnoDB before 5.4), thus this check is not essential and single check will be run immediately before the upgrade to 5.5 in update_com.woltlab.wcf_5.5_ensureInnoDbSearch.php --- diff --git a/wcfsetup/install/files/acp/templates/systemCheck.tpl b/wcfsetup/install/files/acp/templates/systemCheck.tpl index 5885be1563..bb431cce21 100644 --- a/wcfsetup/install/files/acp/templates/systemCheck.tpl +++ b/wcfsetup/install/files/acp/templates/systemCheck.tpl @@ -163,18 +163,6 @@ {lang}wcf.acp.systemCheck.mysql.foreignKeys.description{/lang} - - -
{lang}wcf.acp.systemCheck.mysql.searchEngine{/lang}
-
- {if $results[mysql][searchEngine][result]} - {@$statusOk} {lang}wcf.acp.systemCheck.pass{/lang} - {else} - {@$statusInsufficient} {lang}wcf.acp.systemCheck.mysql.searchEngine.incorrect{/lang} - {/if} - {lang}wcf.acp.systemCheck.mysql.searchEngine.description{/lang} -
-
diff --git a/wcfsetup/install/files/lib/acp/page/SystemCheckPage.class.php b/wcfsetup/install/files/lib/acp/page/SystemCheckPage.class.php index f56f93b2bf..fc1ecdcbeb 100644 --- a/wcfsetup/install/files/lib/acp/page/SystemCheckPage.class.php +++ b/wcfsetup/install/files/lib/acp/page/SystemCheckPage.class.php @@ -3,11 +3,9 @@ namespace wcf\acp\page; use wcf\data\application\Application; -use wcf\data\object\type\ObjectTypeCache; use wcf\page\AbstractPage; use wcf\system\database\util\PreparedStatementConditionBuilder; use wcf\system\exception\SystemException; -use wcf\system\search\SearchIndexManager; use wcf\system\WCF; use wcf\util\FileUtil; @@ -127,10 +125,6 @@ class SystemCheckPage extends AbstractPage 'result' => false, 'version' => '0.0.0', 'foreignKeys' => false, - 'searchEngine' => [ - 'result' => false, - 'incorrectTables' => [], - ], ], 'php' => [ 'gd' => [ @@ -271,31 +265,7 @@ class SystemCheckPage extends AbstractPage $this->results['mysql']['foreignKeys'] = $statement->fetchSingleColumn() == $expectedForeignKeyCount; - // check search engine tables - $objectTypes = ObjectTypeCache::getInstance()->getObjectTypes('com.woltlab.wcf.searchableObjectType'); - $tableNames = []; - foreach ($objectTypes as $objectType) { - $tableNames[] = SearchIndexManager::getTableName($objectType->objectType); - } - $conditionBuilder = new PreparedStatementConditionBuilder(true); - $conditionBuilder->add('TABLE_NAME IN (?)', [$tableNames]); - $conditionBuilder->add('TABLE_SCHEMA = ?', [WCF::getDB()->getDatabaseName()]); - - $sql = "SELECT TABLE_NAME, ENGINE - FROM INFORMATION_SCHEMA.TABLES - " . $conditionBuilder; - $statement = WCF::getDB()->prepareStatement($sql); - $statement->execute($conditionBuilder->getParameters()); - - while ($row = $statement->fetchArray()) { - if ($row['ENGINE'] !== 'InnoDB') { - $this->results['mysql']['searchEngine']['incorrectTables'][$row['TABLE_NAME']] = $row['ENGINE']; - } - } - - $this->results['mysql']['searchEngine']['result'] = empty($this->results['mysql']['searchEngine']['incorrectTables']); - - if ($this->results['mysql']['result'] && $this->results['mysql']['innodb'] && $this->results['mysql']['foreignKeys'] && $this->results['mysql']['searchEngine']['result']) { + if ($this->results['mysql']['result'] && $this->results['mysql']['innodb'] && $this->results['mysql']['foreignKeys']) { $this->results['status']['mysql'] = true; } } diff --git a/wcfsetup/install/lang/de.xml b/wcfsetup/install/lang/de.xml index fcb25b502d..481b360d6d 100644 --- a/wcfsetup/install/lang/de.xml +++ b/wcfsetup/install/lang/de.xml @@ -2791,9 +2791,6 @@ Kein Abschnitt darf leer sein und alle Abschnitten dürfen nur folgende Zeichen - - - InnoDB): {implode from=$results[mysql][searchEngine][incorrectTables] key=tableName item=engine glue=", "}{$tableName} ({$engine}){/implode}. {if LANGUAGE_USE_INFORMAL_VARIANT}Aktualisiere{else}Aktualisieren Sie{/if} die Anzeigen, um die Storage-Engine umzustellen.]]> @@ -5566,5 +5563,8 @@ Benachrichtigungen auf {PAGE_TITLE|lang + + + diff --git a/wcfsetup/install/lang/en.xml b/wcfsetup/install/lang/en.xml index 290ceaf709..d13d0b268f 100644 --- a/wcfsetup/install/lang/en.xml +++ b/wcfsetup/install/lang/en.xml @@ -2721,9 +2721,6 @@ If you have already bought the licenses for the listed apps, th - - - InnoDB): {implode from=$results[mysql][searchEngine][incorrectTables] key=tableName item=engine glue=", "}{$tableName} ({$engine}){/implode}. Use the Rebuild Data Page to migrate to the correct storage engine.]]> @@ -5567,5 +5564,8 @@ your notifications on {PAGE_TITLE|langu + + +