‪TYPO3CMS  10.4
TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\MySql Class Reference
Inheritance diagram for TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\MySql:
TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\AbstractPlatform TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\PlatformCheckInterface TYPO3\CMS\Install\SystemEnvironment\CheckInterface

Public Member Functions

FlashMessageQueue getStatus ()
 
 checkDefaultDatabaseCharset (Connection $connection)
 
 checkDefaultDatabaseServerCharset (Connection $connection)
 
- ‪Public Member Functions inherited from ‪TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\AbstractPlatform
 __construct ()
 
 getMessageQueue ()
 

Static Public Member Functions

static bool isValidDatabaseName (string $databaseName)
 

Protected Member Functions

 checkInvalidSqlModes (Connection $connection)
 
 checkMysqlVersion (Connection $connection)
 
array getIncompatibleSqlModes (Connection $connection)
 
 checkDatabaseName (Connection $connection)
 

Protected Attributes

string $minimumMySQLVersion = '5.5.0'
 
array $incompatibleSqlModes
 
array $databaseCharsetToCheck
 
array $databaseServerCharsetToCheck
 
- ‪Protected Attributes inherited from ‪TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\AbstractPlatform
FlashMessageQueue $messageQueue
 
const SCHEMA_NAME_MAX_LENGTH = 64
 

Detailed Description

Check database configuration status for MySQL server

This class is a hardcoded requirement check for the database server.

The status messages and title must not include HTML, use plain text only. The return values of this class are not bound to HTML and can be used in different scopes (eg. as json array).

This class is only meant to be used within EXT:install and is not part of the TYPO3 Core API.

Definition at line 37 of file MySql.php.

Member Function Documentation

◆ checkDatabaseName()

TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\MySql::checkDatabaseName ( Connection  $connection)
protected

◆ checkDefaultDatabaseCharset()

TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\MySql::checkDefaultDatabaseCharset ( Connection  $connection)

◆ checkDefaultDatabaseServerCharset()

TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\MySql::checkDefaultDatabaseServerCharset ( Connection  $connection)

Checks the character set of the database server and reports an info if it is not utf-8.

Parameters
Connection$connection‪to the database to be checked

Implements TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\PlatformCheckInterface.

Definition at line 197 of file MySql.php.

References TYPO3\CMS\Core\Messaging\AbstractMessage\INFO.

Referenced by TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\MySql\getStatus().

◆ checkInvalidSqlModes()

TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\MySql::checkInvalidSqlModes ( Connection  $connection)
protected

Check if any SQL mode is set which is not compatible with TYPO3

Parameters
Connection$connection‪to the database to be checked

Definition at line 96 of file MySql.php.

References TYPO3\CMS\Core\Messaging\AbstractMessage\ERROR, and TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\MySql\getIncompatibleSqlModes().

Referenced by TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\MySql\getStatus().

◆ checkMysqlVersion()

TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\MySql::checkMysqlVersion ( Connection  $connection)
protected

Check minimum MySQL version

Parameters
Connection$connection‪to the database to be checked

Definition at line 122 of file MySql.php.

References TYPO3\CMS\Core\Messaging\AbstractMessage\ERROR, and TYPO3\CMS\Core\Database\Connection\getServerVersion().

Referenced by TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\MySql\getStatus().

◆ getIncompatibleSqlModes()

array TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\MySql::getIncompatibleSqlModes ( Connection  $connection)
protected

Returns an array with the current sql mode settings

Parameters
Connection$connection‪to the database to be checked
Returns
‪array Contains all configured SQL modes that are incompatible

Definition at line 185 of file MySql.php.

Referenced by TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\MySql\checkInvalidSqlModes().

◆ getStatus()

◆ isValidDatabaseName()

static bool TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\MySql::isValidDatabaseName ( string  $databaseName)
static

Validate the database name

Parameters
string$databaseName
Returns
‪bool

Reimplemented from TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\AbstractPlatform.

Definition at line 225 of file MySql.php.

Member Data Documentation

◆ $databaseCharsetToCheck

array TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\MySql::$databaseCharsetToCheck
protected
Initial value:
= array(
'utf8',
'utf8mb4',
)

Charset of the database that should be fulfilled

Definition at line 56 of file MySql.php.

◆ $databaseServerCharsetToCheck

array TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\MySql::$databaseServerCharsetToCheck
protected
Initial value:
= array(
'utf8',
'utf8mb4',
)

Charset of the database server that should be fulfilled

Definition at line 64 of file MySql.php.

◆ $incompatibleSqlModes

array TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\MySql::$incompatibleSqlModes
protected
Initial value:
= array(
'NO_BACKSLASH_ESCAPES'
)

List of MySQL modes that are incompatible with TYPO3 CMS

Definition at line 49 of file MySql.php.

◆ $minimumMySQLVersion

string TYPO3\CMS\Install\SystemEnvironment\DatabaseCheck\Platform\MySql::$minimumMySQLVersion = '5.5.0'
protected

Minimum supported MySQL version

Definition at line 43 of file MySql.php.