Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 40 additions & 20 deletions docs/book/v7/upgrading/UPGRADE-6.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,26 +9,46 @@ This release reorganised shared logic into the Core module, refactored handlers

> You can find a complete list in [Changelog](https://github.com/dotkernel/api/blob/7.0/CHANGELOG.md)

* [https://github.com/dotkernel/api/pull/358](https://github.com/dotkernel/api/pull/358): Move common logic to Core module
* [https://github.com/dotkernel/api/pull/385](https://github.com/dotkernel/api/pull/385): Refactored Handlers
* [https://github.com/dotkernel/api/pull/389](https://github.com/dotkernel/api/pull/389): Inject `InputFilters` in handlers
* [https://github.com/dotkernel/api/pull/391](https://github.com/dotkernel/api/pull/391): Implemented route grouping
* [https://github.com/dotkernel/api/pull/396](https://github.com/dotkernel/api/pull/396): Service refactoring
* [https://github.com/dotkernel/api/pull/398](https://github.com/dotkernel/api/pull/398): Autogenerate `OAuth2` keys when cloning the project
* [https://github.com/dotkernel/api/pull/400](https://github.com/dotkernel/api/pull/400): Refresh Postman documentation
* [https://github.com/dotkernel/api/pull/401](https://github.com/dotkernel/api/pull/401): Merge `Admin.Core` into `API.Core`
* [https://github.com/dotkernel/api/pull/402](https://github.com/dotkernel/api/pull/402): Implemented `mezzio/mezzio-problem-details`
* [https://github.com/dotkernel/api/pull/404](https://github.com/dotkernel/api/pull/404): Update pre-run.sh
* [https://github.com/dotkernel/api/pull/408](https://github.com/dotkernel/api/pull/408): Update `GetIndexResourceHandler.php`
* [https://github.com/dotkernel/api/pull/409](https://github.com/dotkernel/api/pull/409): Update `local.php.dist`
* [https://github.com/dotkernel/api/pull/412](https://github.com/dotkernel/api/pull/412): Fixed error handling
* [https://github.com/dotkernel/api/pull/403](https://github.com/dotkernel/api/pull/403): Implemented `ResourceProviderMiddleware` and added `ResourceGuardInterface`
* [https://github.com/dotkernel/api/pull/413](https://github.com/dotkernel/api/pull/413): Updated logic in `ContentNegotiationMiddleware`
* [https://github.com/dotkernel/api/pull/418](https://github.com/dotkernel/api/pull/418): `AuthenticationMiddleware` no longer extends `AuthenticationMiddleware` from `mezzio/mezzio-authentication`
* [https://github.com/dotkernel/api/pull/416](https://github.com/dotkernel/api/pull/416): Update `qodana_code_quality.yml`
* [https://github.com/dotkernel/api/pull/419](https://github.com/dotkernel/api/pull/419): Replaced `Twig` with custom templating solution
* [https://github.com/dotkernel/api/pull/421](https://github.com/dotkernel/api/pull/421): Increased `PHPStan` level to 8
* [https://github.com/dotkernel/api/pull/423](https://github.com/dotkernel/api/pull/423): Split the `/security/token` endpoint into two separate endpoints
* [https://github.com/dotkernel/api/pull/358](https://github.com/dotkernel/api/pull/358)
* Move common logic to Core module
* [https://github.com/dotkernel/api/pull/385](https://github.com/dotkernel/api/pull/385)
* Refactored Handlers
* [https://github.com/dotkernel/api/pull/389](https://github.com/dotkernel/api/pull/389)
* Inject `InputFilters` in handlers
* [https://github.com/dotkernel/api/pull/391](https://github.com/dotkernel/api/pull/391)
* Implemented route grouping
* [https://github.com/dotkernel/api/pull/396](https://github.com/dotkernel/api/pull/396)
* Service refactoring
* [https://github.com/dotkernel/api/pull/398](https://github.com/dotkernel/api/pull/398)
* Autogenerate `OAuth2` keys when cloning the project
* [https://github.com/dotkernel/api/pull/400](https://github.com/dotkernel/api/pull/400)
* Refresh Postman documentation
* [https://github.com/dotkernel/api/pull/401](https://github.com/dotkernel/api/pull/401)
* Merge `Admin.Core` into `API.Core`
* [https://github.com/dotkernel/api/pull/402](https://github.com/dotkernel/api/pull/402)
* Implemented `mezzio/mezzio-problem-details`
* [https://github.com/dotkernel/api/pull/404](https://github.com/dotkernel/api/pull/404)
* Update pre-run.sh
* [https://github.com/dotkernel/api/pull/408](https://github.com/dotkernel/api/pull/408)
* Update `GetIndexResourceHandler.php`
* [https://github.com/dotkernel/api/pull/409](https://github.com/dotkernel/api/pull/409)
* Update `local.php.dist`
* [https://github.com/dotkernel/api/pull/412](https://github.com/dotkernel/api/pull/412)
* Fixed error handling
* [https://github.com/dotkernel/api/pull/403](https://github.com/dotkernel/api/pull/403)
* Implemented `ResourceProviderMiddleware` and added `ResourceGuardInterface`
* [https://github.com/dotkernel/api/pull/413](https://github.com/dotkernel/api/pull/413)
* Updated logic in `ContentNegotiationMiddleware`
* [https://github.com/dotkernel/api/pull/418](https://github.com/dotkernel/api/pull/418)
* `AuthenticationMiddleware` no longer extends `AuthenticationMiddleware` from `mezzio/mezzio-authentication`
* [https://github.com/dotkernel/api/pull/416](https://github.com/dotkernel/api/pull/416)
* Update `qodana_code_quality.yml`
* [https://github.com/dotkernel/api/pull/419](https://github.com/dotkernel/api/pull/419)
* Replaced `Twig` with custom templating solution
* [https://github.com/dotkernel/api/pull/421](https://github.com/dotkernel/api/pull/421)
* Increased `PHPStan` level to 8
* [https://github.com/dotkernel/api/pull/423](https://github.com/dotkernel/api/pull/423)
* Split the `/security/token` endpoint into two separate endpoints

## FAQ

Expand Down
18 changes: 13 additions & 5 deletions docs/book/v7/upgrading/UPGRADE-7.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,17 +14,25 @@ Version 7.0 does not change the PHP version or any Composer dependency constrain

These changes affect your database schema, configuration, entities or runtime behavior.

* [https://github.com/dotkernel/api/pull/456](https://github.com/dotkernel/api/pull/456): Use native UUIDs in database via `ramsey/uuid`: entities get their identifier from the new `UuidIdentifierTrait` and a `UuidType` that declares the SQL type `UUID`. `getUuid()` becomes `getId()` and the `uuid` key becomes `id` in entities, repositories, services, input filters and OpenAPI. A schema migration is required
* [https://github.com/dotkernel/api/pull/462](https://github.com/dotkernel/api/pull/462): PostgreSQL implementation: in `config/autoload/local.php.dist` the `default` connection is renamed `mariadb`, a `postgresql` connection is added, and `charset` and `collate` are replaced by `collation`. `AbstractEnumType` is reworked, `MigrationsMigratedSubscriber` is added and `config/cli-config.php` is updated
* [https://github.com/dotkernel/api/pull/470](https://github.com/dotkernel/api/pull/470): Remove `MethodDeprecation` implementation: the attribute and its tests are deleted, and `DeprecationMiddleware` and the error-report handler no longer use it
* [https://github.com/dotkernel/api/pull/456](https://github.com/dotkernel/api/pull/456)
* Use native UUIDs in database via `ramsey/uuid`: entities get their identifier from the new `UuidIdentifierTrait` and a `UuidType` that declares the SQL type `UUID`.
* `getUuid()` becomes `getId()` and the `uuid` key becomes `id` in entities, repositories, services, input filters and OpenAPI.
* A schema migration is required.
* [https://github.com/dotkernel/api/pull/462](https://github.com/dotkernel/api/pull/462)
* PostgreSQL implementation: in `config/autoload/local.php.dist` the `default` connection is renamed `mariadb`, a `postgresql` connection is added, and `charset` and `collate` are replaced by `collation`.
* `AbstractEnumType` is reworked, `MigrationsMigratedSubscriber` is added and `config/cli-config.php` is updated.
* [https://github.com/dotkernel/api/pull/470](https://github.com/dotkernel/api/pull/470)
* Remove `MethodDeprecation` implementation: the attribute and its tests are deleted, and `DeprecationMiddleware` and the error-report handler no longer use it

### Optional updates

These changes cover documentation and comments.
Skipping them does not affect how the API runs.

* [https://github.com/dotkernel/api/pull/472](https://github.com/dotkernel/api/pull/472): Clarify instructions regarding multiple connections in `config/autoload/local.php.dist`
* [https://github.com/dotkernel/api/pull/461](https://github.com/dotkernel/api/pull/461): Update readme and security documents
* [https://github.com/dotkernel/api/pull/472](https://github.com/dotkernel/api/pull/472)
* Clarify instructions regarding multiple connections in `config/autoload/local.php.dist`
* [https://github.com/dotkernel/api/pull/461](https://github.com/dotkernel/api/pull/461)
* Update readme and security documents

## FAQ

Expand Down
75 changes: 50 additions & 25 deletions docs/book/v7/upgrading/UPGRADE-7.1.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,37 +13,62 @@ The headline items are the new PHP 8.3 minimum, the upgrade to `mezzio-authentic

These changes affect your PHP version, dependencies, configuration, database schema, entities or runtime behavior.

* [https://github.com/dotkernel/api/pull/511](https://github.com/dotkernel/api/pull/511): Upgrade `mezzio/mezzio-authentication-oauth2` to `^3.0.1`: the OAuth entities and repositories are adapted, `Admin` and `NumericIdentifierTrait` types are tightened, and the post-install script now generates `config/autoload/mail.local.php`
* [https://github.com/dotkernel/api/pull/510](https://github.com/dotkernel/api/pull/510): Bump PHPUnit to `^12.5.23` and drop PHP 8.2 support: `composer.json` now requires PHP `~8.3.0 || ~8.4.0 || ~8.5.0` and tests use stubs instead of mocks
* [https://github.com/dotkernel/api/pull/513](https://github.com/dotkernel/api/pull/513): Implement browscap in `AdminLogin`: the columns `deviceBrand`, `deviceModel`, `osPlatform`, `clientEngine` and `clientVersion` are removed and `isCrawler` is added, so a schema migration is required
* [https://github.com/dotkernel/api/pull/499](https://github.com/dotkernel/api/pull/499): Remove `config/autoload/mail.global.php`: mail settings now live in `mail.local.php`
* [https://github.com/dotkernel/api/pull/506](https://github.com/dotkernel/api/pull/506): OAuth2 token invalidated on Composer install/update: adds `bin/generate-oauth2-keys.php`, which skips existing keys, and points `post-update-cmd` to it
* [https://github.com/dotkernel/api/pull/490](https://github.com/dotkernel/api/pull/490): Add security headers in `config/autoload/response-header.global.php`: `X-Content-Type-Options` and `Referrer-Policy` on all responses, `Cache-Control: no-store` and `Pragma: no-cache` on the token endpoints
* [https://github.com/dotkernel/api/pull/476](https://github.com/dotkernel/api/pull/476): Add `MalformedRequestBodyMiddleware`, piped in `config/pipeline.php`: a malformed request body now results in a `BadRequestException`
* [https://github.com/dotkernel/api/pull/485](https://github.com/dotkernel/api/pull/485): Require `symfony/var-exporter` to keep LazyGhost support
* [https://github.com/dotkernel/api/pull/486](https://github.com/dotkernel/api/pull/486): Core sync: `created` becomes nullable in `TimestampsTrait` and `EntityInterface`, and the Admin, User and role entities are updated
* [https://github.com/dotkernel/api/pull/522](https://github.com/dotkernel/api/pull/522): Bump `zircote/swagger-php` to `^6.0.0`
* [https://github.com/dotkernel/api/pull/511](https://github.com/dotkernel/api/pull/511)
* Upgrade `mezzio/mezzio-authentication-oauth2` to `^3.0.1`: the OAuth entities and repositories are adapted, `Admin` and `NumericIdentifierTrait` types are tightened, and the post-install script now generates `config/autoload/mail.local.php`
* [https://github.com/dotkernel/api/pull/510](https://github.com/dotkernel/api/pull/510)
* Bump PHPUnit to `^12.5.23` and drop PHP 8.2 support: `composer.json` now requires PHP `~8.3.0 || ~8.4.0 || ~8.5.0` and tests use stubs instead of mocks
* [https://github.com/dotkernel/api/pull/513](https://github.com/dotkernel/api/pull/513)
* Implement browscap in `AdminLogin`: the columns `deviceBrand`, `deviceModel`, `osPlatform`, `clientEngine` and `clientVersion` are removed and `isCrawler` is added, so a schema migration is required
* [https://github.com/dotkernel/api/pull/499](https://github.com/dotkernel/api/pull/499)
* Remove `config/autoload/mail.global.php`: mail settings now live in `mail.local.php`
* [https://github.com/dotkernel/api/pull/506](https://github.com/dotkernel/api/pull/506)
* OAuth2 token invalidated on Composer install/update: adds `bin/generate-oauth2-keys.php`, which skips existing keys, and points `post-update-cmd` to it
* [https://github.com/dotkernel/api/pull/490](https://github.com/dotkernel/api/pull/490)
* Add security headers in `config/autoload/response-header.global.php`: `X-Content-Type-Options` and `Referrer-Policy` on all responses, `Cache-Control: no-store` and `Pragma: no-cache` on the token endpoints
* [https://github.com/dotkernel/api/pull/476](https://github.com/dotkernel/api/pull/476)
* Add `MalformedRequestBodyMiddleware`, piped in `config/pipeline.php`: a malformed request body now results in a `BadRequestException`
* [https://github.com/dotkernel/api/pull/485](https://github.com/dotkernel/api/pull/485)
* Require `symfony/var-exporter` to keep LazyGhost support
* [https://github.com/dotkernel/api/pull/486](https://github.com/dotkernel/api/pull/486)
* Core sync: `created` becomes nullable in `TimestampsTrait` and `EntityInterface`, and the Admin, User and role entities are updated
* [https://github.com/dotkernel/api/pull/522](https://github.com/dotkernel/api/pull/522)
* Bump `zircote/swagger-php` to `^6.0.0`

### Optional updates

These changes cover development tooling, CI and documentation.
Skipping them does not affect how the API runs.

* [https://github.com/dotkernel/api/pull/494](https://github.com/dotkernel/api/pull/494): Bump `dotkernel/dot-maker` to `^2.0.0` and add a Composer `conflict` on versions below `2.0`
* [https://github.com/dotkernel/api/pull/465](https://github.com/dotkernel/api/pull/465): Update PostgreSQL host configuration in `config/autoload/local.php.dist` to `127.0.0.1`
* [https://github.com/dotkernel/api/pull/516](https://github.com/dotkernel/api/pull/516): Add Bruno collection, update readme
* [https://github.com/dotkernel/api/pull/473](https://github.com/dotkernel/api/pull/473): Update API version in README example
* [https://github.com/dotkernel/api/pull/515](https://github.com/dotkernel/api/pull/515): Configure Renovate
* [https://github.com/dotkernel/api/pull/491](https://github.com/dotkernel/api/pull/491): Update branch for Qodana workflow to 7.0
* [https://github.com/dotkernel/api/pull/500](https://github.com/dotkernel/api/pull/500): Update Qodana action version to v2025.3
* [https://github.com/dotkernel/api/pull/523](https://github.com/dotkernel/api/pull/523): Update `JetBrains/qodana-action` to v2026
* [https://github.com/dotkernel/api/pull/527](https://github.com/dotkernel/api/pull/527): Update `JetBrains/qodana-action` to v2026.1.3
* [https://github.com/dotkernel/api/pull/518](https://github.com/dotkernel/api/pull/518): Update `actions/checkout` to v6
* [https://github.com/dotkernel/api/pull/528](https://github.com/dotkernel/api/pull/528): Update `actions/checkout` to v7
* [https://github.com/dotkernel/api/pull/517](https://github.com/dotkernel/api/pull/517): Update `actions/cache` to v5
* [https://github.com/dotkernel/api/pull/530](https://github.com/dotkernel/api/pull/530): Update `actions/cache` to v6
* [https://github.com/dotkernel/api/pull/520](https://github.com/dotkernel/api/pull/520): Update `codecov/codecov-action` to v6
* [https://github.com/dotkernel/api/pull/526](https://github.com/dotkernel/api/pull/526): Update `codecov/codecov-action` to v7
* [https://github.com/dotkernel/api/pull/494](https://github.com/dotkernel/api/pull/494)
* Bump `dotkernel/dot-maker` to `^2.0.0` and add a Composer `conflict` on versions below `2.0`
* [https://github.com/dotkernel/api/pull/465](https://github.com/dotkernel/api/pull/465)
* Update PostgreSQL host configuration in `config/autoload/local.php.dist` to `127.0.0.1`
* [https://github.com/dotkernel/api/pull/516](https://github.com/dotkernel/api/pull/516)
* Add Bruno collection, update readme
* [https://github.com/dotkernel/api/pull/473](https://github.com/dotkernel/api/pull/473)
* Update API version in README example
* [https://github.com/dotkernel/api/pull/515](https://github.com/dotkernel/api/pull/515)
* Configure Renovate
* [https://github.com/dotkernel/api/pull/491](https://github.com/dotkernel/api/pull/491)
* Update branch for Qodana workflow to 7.0
* [https://github.com/dotkernel/api/pull/500](https://github.com/dotkernel/api/pull/500)
* Update Qodana action version to v2025.3
* [https://github.com/dotkernel/api/pull/523](https://github.com/dotkernel/api/pull/523)
* Update `JetBrains/qodana-action` to v2026
* [https://github.com/dotkernel/api/pull/527](https://github.com/dotkernel/api/pull/527)
* Update `JetBrains/qodana-action` to v2026.1.3
* [https://github.com/dotkernel/api/pull/518](https://github.com/dotkernel/api/pull/518)
* Update `actions/checkout` to v6
* [https://github.com/dotkernel/api/pull/528](https://github.com/dotkernel/api/pull/528)
* Update `actions/checkout` to v7
* [https://github.com/dotkernel/api/pull/517](https://github.com/dotkernel/api/pull/517)
* Update `actions/cache` to v5
* [https://github.com/dotkernel/api/pull/530](https://github.com/dotkernel/api/pull/530)
* Update `actions/cache` to v6
* [https://github.com/dotkernel/api/pull/520](https://github.com/dotkernel/api/pull/520)
* Update `codecov/codecov-action` to v6
* [https://github.com/dotkernel/api/pull/526](https://github.com/dotkernel/api/pull/526)
* Update `codecov/codecov-action` to v7

## FAQ

Expand Down
Loading
Loading