Problem/Motivation
The Symfony Runtime component provides a standardised way to perform application bootstrapping and environment set-up in a way that is decoupled from the specific application being implemented.
Originally proposed as part of #3313404: Use symfony/runtime for less bespoke bootstrap/compatibility with varied runtime environments, using the Symfony Runtime component to provide a place for bootstrap work that should not be the responsibility of the DrupalKernel.
Later in time adopted by #3453474: CLI entry point in Drupal Core (Dex) to provide the runtime set-up for the new Drupal CLI.
This issue includes the steps needed to add the dependency to the core composer files so that development using the library can begin.
Steps to reproduce
Proposed resolution
For the full reasoning of why the symfony/runtime component was chosen see #3313404: Use symfony/runtime for less bespoke bootstrap/compatibility with varied runtime environments. The module evaluation has been provided below.
Dependency Evaluation
Maintainership of the package
The package is maintained by Symfony.
Security policies of the package
Follows the Symfony security policy followed for our other Symfony dependencies.
Expected release and support cycles
Follows the regular Symfony release cycle.
Code quality
Written according to Symfony standards.
Other dependencies it would add, if any (the full tree, not just direct dependencies), and evaluations for those dependencies as well
The component requires PHP 8.4 or later. It also requires the composer-plugin-api. This fits in the existing dependency of Drupal's components on composer-plugin-api version 2.
The Runtime component has no other dependencies but can optionally integrate (and is tested with) other Symfony components.
Remaining tasks
MR to update composer.json filesFramework manager sign-off(signed off by catch and alexpott in #3313404-32: Use symfony/runtime for less bespoke bootstrap/compatibility with varied runtime environments)Release manager sign-off(see [#3552922-23)-Write release-notes snippet
Issues after this one:
- #3453474: CLI entry point in Drupal Core (Dex)
- #3313404: Use symfony/runtime for less bespoke bootstrap/compatibility with varied runtime environments
User interface changes
Documentation Change
Symfony is already documented as PHP dependency for all components (symfony/symfony).
Introduced terminology
API changes
None, the new Drupal CLI will be the first (based on current issue readiness) consumer of the component in #3453474: CLI entry point in Drupal Core (Dex).
Improvements in moving Drupal's existing front-controllers to use the component are proposed in #3313404: Use symfony/runtime for less bespoke bootstrap/compatibility with varied runtime environments
Data model changes
Release notes snippet
Drupal has added the Symfony Runtime component. This will allow Drupal to start moving bootstrapping logic from the DrupalKernel into runtime classes that may be reused or swapped out by developers who are using Drupal. The first example of this will be in the upcoming Drupal CLI which uses the component to run the new console application.
Issue fork drupal-3552922
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
kingdutchComment #4
kingdutchComment #5
kingdutchRemoving framework manager review as per #3313404-32: Use symfony/runtime for less bespoke bootstrap/compatibility with varied runtime environments
Comment #6
klausiLooks good to me, thanks!
Comment #7
xjmI got to overhear the reasoning for #3313404: Use symfony/runtime for less bespoke bootstrap/compatibility with varied runtime environments earlier today and everything here convinces me this is worth the tradeoff of the additional dependency. Thanks @kingdutch!
Comment #8
xjmDiscussed with @alexpott. Having this dependency added separately from #3313404: Use symfony/runtime for less bespoke bootstrap/compatibility with varied runtime environments is a good separation of concerns; however, we don't want to end up in a situation where this dependency is added to a minor release without the functionality it unlocks. Since we're pretty close to alpha1 of 11.3 and we probably don't want to make a change as dramatic as #3313404: Use symfony/runtime for less bespoke bootstrap/compatibility with varied runtime environments in that release since it's so soon and it would not give us enough time for review and testing, we agreed to postpone this issue on 11.3.x being branched. Then potentially commit it to 11.x after that. I'm adding this issue to #3528698: [meta] Release preparation steps for 11.3.0 and 10.6.0 to keep track of it.
Thanks!
Comment #9
klausiTagging.
Comment #10
quietone commentedSince 11.3.x has been branch, I am setting this to active.
Comment #11
nicxvan commentedI agree this should be done separately, but think it should still be postponed until the concerns in the other issue are resolved.
Comment #12
quietone commentedComment #13
quietone commentedI meant to set this to Active, so doing that now.
@nicxvan, can you elaborate on what you think this should be postponed on?
Comment #14
nicxvan commentedYes there are two fairly divergent options in the related issue.
Now that both approaches have an mr demonstrating how they would work i have a bit less concern about this.
But I thought the dependency question should wait until an approach is decided upon. Both approaches use runtime so this is probably safe to move forward.
Comment #15
ghost of drupal pastAlthough currently the two branches there are divergent if you check my comment then you'll see the next steps are to bring them very close to achieve znerol's most excellent appcontext idea with the only difference being how front controllers are written
So yeah this issue should go ahead the other issue will resolve hopefully soon
Comment #16
quietone commentedOK, then changing to Needs work to get the MR updated
Comment #17
larowlanThis is now blocking #3453474: CLI entry point in Drupal Core (Dex) which is a strategic priority.
Given we have another use-case for it that doesn't involve a major rewrite of our front-controller like #3313404: Use symfony/runtime for less bespoke bootstrap/compatibility with varied runtime environments does - can we move forward with this?
The goal is to get #3453474: CLI entry point in Drupal Core (Dex) in before Drupal dev days to unlock the porting of other commands.
I'll reach out to RMs on slack
Comment #18
nicxvan commentedI'll take a look at the command issue, I'm interested if it looks like: #3576593: Create pre-bootstrap extension mechanism which still feels like the correct direction for the front controllers.
Comment #19
quietone commentedComment #21
mradcliffeI rebased onto current main.
I ran
COMPOSER_ROOT_VERSION=dev-main composer update drupal/core-recommended symfony/runtime, which added 8.0.8 to core-recommended. This was released on 2026.03.30 a couple of weeks after main was updated to Symfony 8. The prior release was 8.0.1 released in 2025.12.I did a quick spot check by running ComposerIntegrationTest locally, which passed.
Comment #22
mradcliffeI updated the PHP version that is required by symfony/runtime to 8.4 since Symfony 8 was released.
Comment #23
godotislateDiscussed with @catch and @longwave and have release manager approval. Also appears per #7 & #8 that @xjm also approved. Removing tag.
Comment #24
mradcliffeRebased again since I think we are close to RTBC.
Comment #25
mradcliffeTest failures seem unrelated:
Comment #26
mradcliffeRebased and the previous test failures disappeared. So we’re green if anyone wants to do another review of the issue summary and changes to RTBC?
Comment #27
kingdutchAs original author of the PR I'm happy with the rebased state and believe it reflects the correct changes against the current version of Drupal, as originally RTBC'd by Klausi in #6 and approved by xjm in #7. Given that I originally authored it I don't feel like I can be the person to now mark it as RTBC, but I don't know if that provides precedence for making those RTBCs apply, or gives someone else the confidence to give their final review.
Comment #28
kingdutchI've adjusted the issue summary to also reference the Drupal CLI since with the current state of issues, that'll likely be the first adopter of the component. I've also updated the release note snippet to reflect that.
Comment #29
klausiThanks, looks good to me. We are only adding the new dependency here, which is approved by release managers.
Comment #30
xjmThe approach that we discussed at DrupalCon Vienna 2025 was waiting for one of the issues that requires the dependency to be RTBC and ready for commit. Then, we would update this issue for the latest
composer.locketc., commit it, and then rebase the others for a smaller MR for final review there. (That way, the dependency does not sit unused in HEAD requiring dependency management while we're waiting for a usecase to maybe-land-maybe-not.)Comment #31
xjmProper status is postponed to not clutter the queue; this will probably need to be rerolled against both main and 11.x once one or the other of the child issues is ready. It can be Re-TBCed then. Thanks everyone!