We remove the default mapping paths which are used to read PHP 8 attributes to build routes.
To configure this default value, please edit your config/packages/sylius_resource.yaml
file to add your mapping paths manually:
# config/packages/sylius_resource.yaml
sylius_resource:
mapping:
paths:
- '%kernel.project_dir%/src/Entity'
These following services are now Doctrine listeners instead of Doctrine subscribers (@see symfony/symfony#49586)
- Sylius\Bundle\ResourceBundle\EventListener\ORMTranslatableListener
- Sylius\Bundle\ResourceBundle\EventListener\ORMRepositoryClassSubscriber
- Sylius\Bundle\ResourceBundle\EventListener\ORMMappedSuperClassSubscriber
Applied the UniqueEntity
constraint for locale
and translatable
fields, and added NotBlank
& Locale
constraints for the locale
property in classes extending Sylius\Resource\Model\AbstractTranslation
.
Applied the Valid
constraint for the getTranslations
method for objects implementing Sylius\Resource\Model\TranslatableInterface
.
-
failed form response status code returned from the
ResourceController::createAction
andResourceController::updateAction
changed from200
to422
see: Sylius#488. This is technically a bug fix, but could break the application if your logic is based on this bugged previous status code
-
jms/serializer
andjms/serializer-bundle
from2.x
to3.x
:follow their upgrade process for the component and the bundle; if you're getting errors about serializing the entity manager, consider changing the serialized type from
array
toiterable
for Doctrine collections in your models -
friendsofsymfony/rest-bundle
from2.x
to3.x
:follow their upgrade process; if you're using this bundle to render HTML templates as well, replace it with direct calls to Twig and handle only the REST logic via this bundle (see this PR for more)
-
willdurand/hateoas
from2.x
to3.x
:follow their upgrade process
-
from
white-october/pagerfanta-bundle
^1.0
tobabdev/pagerfanta-bundle
^2.5
:follow their upgrade process
-
doctrine/persistence
from1.x
to2.x
(if applicable):replace
Doctrine\Common\Persistence
withDoctrine\Persistence
in your codebase
You can find an exemplary upgrade to this version of ResourceBundle on Sylius repository in this PR.
If you're using an "Accept" HTTP header to set the serialization groups, you need to define allowed groups
either by passing them as default in serialization_groups
setting or marking them as allowed in
allowed_serialization_groups
setting, both settings are set in the route definition (under _sylius
key).