diff --git a/src/Symfony/Bundle/FrameworkBundle/CHANGELOG.md b/src/Symfony/Bundle/FrameworkBundle/CHANGELOG.md index 9d3b3eae45fc5..5ffc9f85f0c34 100644 --- a/src/Symfony/Bundle/FrameworkBundle/CHANGELOG.md +++ b/src/Symfony/Bundle/FrameworkBundle/CHANGELOG.md @@ -15,6 +15,7 @@ CHANGELOG * Deprecate the `framework.validation.cache` option * Add `--method` option to the `debug:router` command * Auto-exclude DI extensions, test cases, entities and messenger messages + * Add DI alias from `ServicesResetterInterface` to `services_resetter` 7.2 --- diff --git a/src/Symfony/Bundle/FrameworkBundle/Resources/config/services.php b/src/Symfony/Bundle/FrameworkBundle/Resources/config/services.php index e5a86d8f411f5..558c2b6d52334 100644 --- a/src/Symfony/Bundle/FrameworkBundle/Resources/config/services.php +++ b/src/Symfony/Bundle/FrameworkBundle/Resources/config/services.php @@ -42,6 +42,7 @@ use Symfony\Component\HttpKernel\CacheWarmer\CacheWarmerAggregate; use Symfony\Component\HttpKernel\Config\FileLocator; use Symfony\Component\HttpKernel\DependencyInjection\ServicesResetter; +use Symfony\Component\HttpKernel\DependencyInjection\ServicesResetterInterface; use Symfony\Component\HttpKernel\EventListener\LocaleAwareListener; use Symfony\Component\HttpKernel\HttpCache\Store; use Symfony\Component\HttpKernel\HttpCache\StoreInterface; @@ -177,6 +178,7 @@ class_exists(WorkflowEvents::class) ? WorkflowEvents::ALIASES : [] ->set('services_resetter', ServicesResetter::class) ->public() + ->alias(ServicesResetterInterface::class, 'services_resetter') ->set('reverse_container', ReverseContainer::class) ->args([ diff --git a/src/Symfony/Component/HttpKernel/CHANGELOG.md b/src/Symfony/Component/HttpKernel/CHANGELOG.md index cc9da8a2a98af..1d533c29f51c8 100644 --- a/src/Symfony/Component/HttpKernel/CHANGELOG.md +++ b/src/Symfony/Component/HttpKernel/CHANGELOG.md @@ -6,6 +6,7 @@ CHANGELOG * Add `$key` argument to `#[MapQueryString]` that allows using a specific key for argument resolving * Support `Uid` in `#[MapQueryParameter]` + * Add `ServicesResetterInterface`, implemented by `ServicesResetter` 7.2 --- diff --git a/src/Symfony/Component/HttpKernel/DependencyInjection/ServicesResetter.php b/src/Symfony/Component/HttpKernel/DependencyInjection/ServicesResetter.php index c2a19d992f08a..57e394fcc5d69 100644 --- a/src/Symfony/Component/HttpKernel/DependencyInjection/ServicesResetter.php +++ b/src/Symfony/Component/HttpKernel/DependencyInjection/ServicesResetter.php @@ -13,7 +13,6 @@ use ProxyManager\Proxy\LazyLoadingInterface; use Symfony\Component\VarExporter\LazyObjectInterface; -use Symfony\Contracts\Service\ResetInterface; /** * Resets provided services. @@ -23,7 +22,7 @@ * * @final since Symfony 7.2 */ -class ServicesResetter implements ResetInterface +class ServicesResetter implements ServicesResetterInterface { /** * @param \Traversable $resettableServices diff --git a/src/Symfony/Component/HttpKernel/DependencyInjection/ServicesResetterInterface.php b/src/Symfony/Component/HttpKernel/DependencyInjection/ServicesResetterInterface.php new file mode 100644 index 0000000000000..88fba821db43c --- /dev/null +++ b/src/Symfony/Component/HttpKernel/DependencyInjection/ServicesResetterInterface.php @@ -0,0 +1,21 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +namespace Symfony\Component\HttpKernel\DependencyInjection; + +use Symfony\Contracts\Service\ResetInterface; + +/** + * Resets provided services. + */ +interface ServicesResetterInterface extends ResetInterface +{ +}