Skip to content

Commit 1675a7a

Browse files
Merge pull request #11 from kdambekalns/task/fix-mysql-charset
TASK: Use utf8mb4 for queue table on MySQL/MariaDB
2 parents 4a24f41 + 220a27d commit 1675a7a

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

Classes/Queue/DoctrineQueue.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ public function setUp(): void
111111
$createDatabaseStatement = "CREATE TABLE IF NOT EXISTS {$this->connection->quoteIdentifier($this->tableName)} (id SERIAL PRIMARY KEY, payload TEXT NOT NULL, state VARCHAR(255) NOT NULL, failures INTEGER NOT NULL DEFAULT 0, scheduled TIMESTAMP(0) WITHOUT TIME ZONE DEFAULT NULL)";
112112
break;
113113
default:
114-
$createDatabaseStatement = "CREATE TABLE IF NOT EXISTS {$this->connection->quoteIdentifier($this->tableName)} (id INTEGER PRIMARY KEY AUTO_INCREMENT, payload LONGTEXT NOT NULL, state VARCHAR(255) NOT NULL, failures INTEGER NOT NULL DEFAULT 0, scheduled DATETIME DEFAULT NULL) DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci ENGINE = InnoDB";
114+
$createDatabaseStatement = "CREATE TABLE IF NOT EXISTS {$this->connection->quoteIdentifier($this->tableName)} (id INTEGER PRIMARY KEY AUTO_INCREMENT, payload LONGTEXT NOT NULL, state VARCHAR(255) NOT NULL, failures INTEGER NOT NULL DEFAULT 0, scheduled DATETIME DEFAULT NULL) DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci ENGINE = InnoDB";
115115
}
116116
$this->connection->exec($createDatabaseStatement);
117117
$this->connection->exec("CREATE INDEX state_scheduled ON {$this->connection->quoteIdentifier($this->tableName)} (state, scheduled)");

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"description": "Implements concrete Queue for the doctrine work queue. Requires the packages flowpack/jobqueue-common to be installed.",
55
"license": "MIT",
66
"require": {
7-
"neos/flow": "^4.0 || ^5.0 || ^6.0",
7+
"neos/flow": "^5.0 || ^6.0",
88
"flowpack/jobqueue-common": "^3.0 || dev-master"
99
},
1010
"autoload": {

0 commit comments

Comments
 (0)