This repository has been archived by the owner on Dec 3, 2023. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 188
[ECS] Remove dependency on symfony/http-kernel #3726
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
TomasVotruba
changed the title
tv ecs kernel lighter
[ECS] Remove dependency on symfony/http-kernel
Oct 31, 2021
TomasVotruba
force-pushed
the
tv-ecs-kernel-lighter
branch
5 times, most recently
from
October 31, 2021 15:56
a10655f
to
d0a973b
Compare
cc @matthiasnoback Hi Matthias, I had a struggle with too heavy Symfony, so I've decided to drop anything we don't need from Symfony to build the container. I think you might like this one. Any feedback appreciated! Also, if this work, it might get to Rector itself :) |
samsonasik
reviewed
Oct 31, 2021
packages/easy-coding-standard/src/HttpKernel/EasyCodingStandardKernel.php
Outdated
Show resolved
Hide resolved
TomasVotruba
force-pushed
the
tv-ecs-kernel-lighter
branch
2 times, most recently
from
October 31, 2021 16:41
afafea1
to
61f651f
Compare
TomasVotruba
force-pushed
the
tv-ecs-kernel-lighter
branch
6 times, most recently
from
October 31, 2021 18:12
c02cec7
to
dad5ebe
Compare
TomasVotruba
force-pushed
the
tv-ecs-kernel-lighter
branch
from
October 31, 2021 18:13
dad5ebe
to
8b8b1f2
Compare
This was referenced Oct 31, 2021
-390 files 🥳It took a while to clean whole symplify dependency tree from |
How much ECS vendor lose weight?
|
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The symfony/http-kernel is a useful package to quickly bootstrap project using Symfony DI.
The disadvantage is that it will many heavy Symfony framework components
etc.
We only need to build Dependency Injection container. But unfortunately, there is no component that would only create container from configs. The Dependency Injection component is just a simple package for handling mostly service value object. The container itself is built unfortunately in http-kernel component.
Ideally the container-builder should be separated from http-kernel, that would be light and only build the container. Due to this heavy Symfony pull, all Symplify CLI packages are almost as heavey as any MVC framework application. Imagine PHPUnit using full symfony/symfony, that's not good.
As negative consequence, the downgrade process is slow, heavy and the download of simple ECS results in download of dozens unused Symfony components, just to make http-kernel happy.
To avoid this, this is an attempt to build the missing container-builder package, that only accepts:
And returns compiled Container in the end. Will it work? :)