1 Commits
Author SHA1 Message Date
haylanandClaude Bot 4abd77103e feat!: require Shopware 6.7, release as 0.1.0
- shopware/core ~6.7.0; 6.6 stays on the 0.0.x line
- drop the sw-settings navigation entry; the settingsItem card in
  Settings > System is the only entry, like core settings modules
- dev container on dockware/shopware:6.7.14.2

BREAKING CHANGE: Shopware 6.6 is no longer supported.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 22:49:56 +01:00
10 changed files with 15 additions and 77 deletions

No files matched your search

+2 -8
View File
@@ -110,7 +110,6 @@ jobs:
test -n "$VERSION" || { echo "::error::could not resolve a Shopware version for ${CONSTRAINT}"; exit 1; } test -n "$VERSION" || { echo "::error::could not resolve a Shopware version for ${CONSTRAINT}"; exit 1; }
echo "Shopware ${VERSION} (constraint ${CONSTRAINT})" echo "Shopware ${VERSION} (constraint ${CONSTRAINT})"
echo "version=${VERSION}" >> "$GITHUB_OUTPUT" echo "version=${VERSION}" >> "$GITHUB_OUTPUT"
echo "constraint=${CONSTRAINT}" >> "$GITHUB_OUTPUT"
# Project (vendor/, phpunit, config) and the installed database as a SQL dump. Neither depends on the plugin. # Project (vendor/, phpunit, config) and the installed database as a SQL dump. Neither depends on the plugin.
- name: Restore Shopware project and database - name: Restore Shopware project and database
id: shopware id: shopware
@@ -126,13 +125,8 @@ jobs:
if: steps.shopware.outputs.cache-hit != 'true' if: steps.shopware.outputs.cache-hit != 'true'
run: | run: |
set -e set -e
# shopware/production pins one exact core version and is not tagged for every core patch composer create-project "shopware/production:${{ steps.sw.outputs.version }}" shopware --no-interaction --no-scripts
# (e.g. core 6.6.10.31, template only up to 6.6.10.30): take the newest template inside the composer require --dev phpunit/phpunit:^10 --no-interaction --no-scripts -d shopware
# constraint, then require the resolved core version on top of it.
composer create-project "shopware/production:${{ steps.sw.outputs.constraint }}" shopware --no-interaction --no-scripts --no-install
composer require "shopware/core:${{ steps.sw.outputs.version }}" --no-update -d shopware
composer require --dev phpunit/phpunit:^10 --no-update -d shopware
composer update -W --no-interaction --no-scripts -d shopware
- name: Ensure the MariaDB client - name: Ensure the MariaDB client
run: | run: |
command -v mariadb-dump >/dev/null || command -v mysqldump >/dev/null && exit 0 command -v mariadb-dump >/dev/null || command -v mysqldump >/dev/null && exit 0
+7 -3
View File
@@ -7,11 +7,15 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [Unreleased] ## [Unreleased]
## [0.0.7] - 2026-11-02 ## [0.1.0] - 2026-11-02
### Fixed ### Changed
- Creating a dump failed on MariaDB when only MySQL 8's `mysqldump` was installed (`Unknown table 'COLUMN_STATISTICS'`); it now passes `--column-statistics=0` in that case. - Requires Shopware 6.7 (`shopware/core ~6.7.0`); 6.6 stays on the 0.0.x line.
### Removed
- The Settings sidebar navigation entry; the plugin is reached through its card in Settings → System, like core settings modules.
## [0.0.6] - 2026-10-04 ## [0.0.6] - 2026-10-04
+1 -1
View File
@@ -67,7 +67,7 @@ vendor/bin/phpunit tests/SomeTest.php # single file
## Dependencies ## Dependencies
- PHP `^8.2`, `shopware/core` `~6.6.0` (from `composer.json`); `phpunit/phpunit` `^10.0` as the only - PHP `^8.2`, `shopware/core` `~6.7.0` (from `composer.json`); `phpunit/phpunit` `^10.0` as the only
dev dependency. dev dependency.
- PSR-4 autoload: `AeonDumpManager\` → `src/`, `AeonDumpManager\Tests\` → `tests/`. - PSR-4 autoload: `AeonDumpManager\` → `src/`, `AeonDumpManager\Tests\` → `tests/`.
+2 -2
View File
@@ -3,7 +3,7 @@
"description": "Export database dumps for Shopware 6 environments.", "description": "Export database dumps for Shopware 6 environments.",
"type": "shopware-platform-plugin", "type": "shopware-platform-plugin",
"license": "MIT", "license": "MIT",
"version": "0.0.7", "version": "0.1.0",
"keywords": [ "keywords": [
"shopware", "shopware",
"shopware6", "shopware6",
@@ -26,7 +26,7 @@
}, },
"require": { "require": {
"php": "^8.2", "php": "^8.2",
"shopware/core": "~6.6.0" "shopware/core": "~6.7.0"
}, },
"require-dev": { "require-dev": {
"phpunit/phpunit": "^10.0" "phpunit/phpunit": "^10.0"
+1 -1
View File
@@ -1,6 +1,6 @@
services: services:
shopware: shopware:
image: dockware/shopware:6.6.10.12 image: dockware/shopware:6.7.14.2
container_name: shopware container_name: shopware
ports: ports:
- "80:80" # Shop / Admin / Adminer / Mailcatcher (all served via path on this port) - "80:80" # Shop / Admin / Adminer / Mailcatcher (all served via path on this port)
@@ -27,23 +27,8 @@ Shopware.Module.register('aeon-dump-manager', {
}, },
}, },
// Per https://developer.shopware.com/docs/v6.6/guides/plugins/plugins/administration/routing-navigation/add-menu-entry.html — // Card on the Settings overview page's "System" group, next to Plugins/Cache.
// plugins can't register a first-level main-menu entry, so this nests // Same mechanism every core settings module uses in 6.6 and 6.7 (no sidebar entry).
// under the core 'sw-settings' navigation node. Clicking Settings in the
// main sidebar shows this as a sub-item, landing at #/sw/settings/.
navigation: [{
id: 'aeon-dump-manager-list',
label: 'aeon-dump-manager.general.mainMenuItemGeneral',
color: '#ff3d58',
path: 'aeon.dump.manager.list',
icon: 'regular-database',
parent: 'sw-settings',
position: 100,
privilege: 'aeon_dump_manager.viewer',
}],
// Also shown as a card on the Settings overview page's "System" group,
// next to Plugins/Cache — complements the navigation entry above.
settingsItem: { settingsItem: {
group: 'system', group: 'system',
to: 'aeon.dump.manager.list', to: 'aeon.dump.manager.list',
-14
View File
@@ -6,7 +6,6 @@ use AeonDumpManager\Service\Exception\DumpBinaryNotFoundException;
use Doctrine\DBAL\Connection; use Doctrine\DBAL\Connection;
use Shopware\Core\System\SystemConfig\SystemConfigService; use Shopware\Core\System\SystemConfig\SystemConfigService;
use Symfony\Component\Process\ExecutableFinder; use Symfony\Component\Process\ExecutableFinder;
use Symfony\Component\Process\Process;
/** /**
* Picks mariadb-dump/mysqldump depending on what the configured DB connection * Picks mariadb-dump/mysqldump depending on what the configured DB connection
@@ -39,19 +38,6 @@ class DumpBinaryLocator
throw DumpBinaryNotFoundException::create($binaryNames); throw DumpBinaryNotFoundException::create($binaryNames);
} }
/**
* @return list<string> client-specific flags for the located binary
*/
public function extraArguments(string $binary): array
{
$version = new Process([$binary, '--version']);
$version->run();
return MySqlVariant::needsColumnStatisticsOff($version->getOutput(), $this->isMariaDb())
? ['--column-statistics=0']
: [];
}
private function isMariaDb(): bool private function isMariaDb(): bool
{ {
// Connection::getServerVersion() is private in the DBAL version this // Connection::getServerVersion() is private in the DBAL version this
-1
View File
@@ -173,7 +173,6 @@ class DumpService
$binary, $binary,
'--single-transaction', '--single-transaction',
'--quick', '--quick',
...$this->dumpBinaryLocator->extraArguments($binary),
'-h', (string) ($params['host'] ?? '127.0.0.1'), '-h', (string) ($params['host'] ?? '127.0.0.1'),
'-P', (string) ($params['port'] ?? 3306), '-P', (string) ($params['port'] ?? 3306),
'-u', (string) ($params['user'] ?? 'root'), '-u', (string) ($params['user'] ?? 'root'),
-14
View File
@@ -14,18 +14,4 @@ class MySqlVariant
{ {
return stripos($serverVersion, 'mariadb') !== false; return stripos($serverVersion, 'mariadb') !== false;
} }
/**
* MySQL 8+ mysqldump queries information_schema.COLUMN_STATISTICS, which
* MariaDB lacks (error 1109); --column-statistics=0 skips it. MariaDB's own
* client (version string contains "MariaDB") and MySQL < 8 don't know the flag.
*/
public static function needsColumnStatisticsOff(string $clientVersion, bool $serverIsMariaDb): bool
{
return $serverIsMariaDb
&& !self::isMariaDb($clientVersion)
// MySQL < 8 prints "Ver 10.13 Distrib 5.7.x": the Distrib number is the real version.
&& (preg_match('/Distrib (\d+)\./', $clientVersion, $m) === 1 || preg_match('/\bVer (\d+)\./', $clientVersion, $m) === 1)
&& (int) $m[1] >= 8;
}
} }
-16
View File
@@ -21,20 +21,4 @@ class MySqlVariantTest extends TestCase
yield 'mariadb without legacy prefix' => ['10.11.2-MariaDB', true]; yield 'mariadb without legacy prefix' => ['10.11.2-MariaDB', true];
yield 'mariadb lowercase' => ['10.11.2-mariadb', true]; yield 'mariadb lowercase' => ['10.11.2-mariadb', true];
} }
#[DataProvider('columnStatisticsProvider')]
public function testNeedsColumnStatisticsOff(string $clientVersion, bool $serverIsMariaDb, bool $expected): void
{
self::assertSame($expected, MySqlVariant::needsColumnStatisticsOff($clientVersion, $serverIsMariaDb));
}
public static function columnStatisticsProvider(): iterable
{
$mysql8 = 'mysqldump Ver 8.0.46-0ubuntu0.24.04.4 for Linux on x86_64 ((Ubuntu))';
yield 'mysql 8 client, mariadb server' => [$mysql8, true, true];
yield 'mysql 8 client, mysql server' => [$mysql8, false, false];
yield 'mysql 5.7 client, mariadb server' => ['mysqldump Ver 10.13 Distrib 5.7.44, for Linux (x86_64)', true, false];
yield 'mariadb client, mariadb server' => ['mariadb-dump from 11.4.2-MariaDB, client 10.19 for debian-linux-gnu (x86_64)', true, false];
yield 'mariadb legacy mysqldump name' => ['mysqldump Ver 10.19 Distrib 10.11.6-MariaDB, for debian-linux-gnu (x86_64)', true, false];
}
} }