Deep dive: State of Drupal 9
@gaborhojtsy @amberhimesmatz
Slides are open source
(CC BY-NC-SA 2.5)
Created by @gaborhojtsy at @acquia
Thanks to @amberhimesmatz, @svettes,
@kristen_pol, @dan2k3k4 for improvements
Review links, check out speaker notes and present your own from slides.com/gaborhojtsy/state-of-drupal9
Amber Matz
Osio Labs / Drupalize.me
Co-maintainer of experimental core module Help Topics.
Contact me at @amberhimesmatz
Gábor Hojtsy
Acquia
Initiative coordinator for Drupal 9.
Drupal contributor since 2003, committer since 2007.
Contact me at @gaborhojtsy
Who is using Drupal 7?
Drupal 7 to 8
Rebuild from Drupal 7 to 8/9
Upgrade Status
Drupal Module Upgrader
Migrate Suite
Improvements with Drupal 9
- Drupal Module Upgrader rules are now Drupal 8 and 9 compatible
- Migrate Multilingual core module became stable in Drupal 8.9.0 and
Drupal 9.0.0
2020 | 2021 | 2022 | 2023 | 2024 |
---|
Drupal 7 security and
bug fix support
Vendor extended commercial
support for Drupal 7
Q1 | Q2 | Q3 | Q4 | Q1 | Q2 | Q3 | Q4 |
---|
Q1 | Q2 | Q3 | Q4 | Q1 | Q2 | Q3 | Q4 |
---|
Q1 | Q2 | Q3 | Q4 |
---|
7.71 | 7.x | 7.x | 7.x | 7.x |
---|
Innovation is different from Drupal 8 onwards
Drupal 7 to 8
Drupal 8 to 9 to 10
Semantic versioning
Scheduled releases
Experimental projects
Why Drupal 9 then?
2020 | 2021 | 2022 | 2023 | 2024 |
---|
Q1 | Q2 | Q3 | Q4 | Q1 | Q2 | Q3 | Q4 |
---|
Q1 | Q2 | Q3 | Q4 | Q1 | Q2 | Q3 | Q4 |
---|
Q1 | Q2 | Q3 | Q4 |
---|
Symfony 3 End of Life
8.9 | |||||||
---|---|---|---|---|---|---|---|
9.0 | 9.1 | 9.2 | 9.3 |
9.4 |
Symfony 4 End of Life
Drupal 9 security and
bug fix support
Drupal 8 security and
bug fix support
Drupal 10 security and
bug fix support
10.0 | 10.1 | 10.2 | 10.3 | ||||
Deprecation processes
Drupal 8 to 9 to 10
...
New solution |
---|
Deprecated |
Symfony 3.4 |
Deprecated |
8.9 API
Deprecated |
New solution |
---|
New solution |
---|
Symfony 4.4 |
9.0 API
New solution |
---|
Symfony 4.4 |
New solution |
---|
Deprecated |
Symfony 3.4 |
Deprecated |
8.7 API
8.9 API
New solution |
---|
New solution |
---|
Deprecated |
Symfony 3.4 |
Deprecated |
Deprecated |
Drupal 9.0 API =
Drupal 8.9 API minus
deprecated parts
plus third party dependencies updated
New solution |
---|
Symfony 4.4 |
9.0 API
New solution |
---|
Symfony 4.4 |
New solution |
---|
Deprecated |
Symfony 3.4 |
Deprecated |
8.9 API
Deprecated |
New solution |
---|
Drupal 8 code not using deprecated APIs will continue to work on Drupal 9.
New solution |
---|
Symfony 4.4 |
9.0 API
New solution |
---|
Symfony 4.4 |
$ composer create-project drupal/recommended-project:9.0.0 try9
$ php try9/web/core/scripts/drupal quick-start demo_umami
Try Drupal 9 with composer + PHP
5 steps to upgrade from Drupal 8 to 9
Ensure your environment is compatible with Drupal 9
PHP
7.3
Drush 10
MySQL 5.7.8
...
#1
Keep Drupal 8 core
up-to-date
#2
Only upgrades from Drupal 8.8 and 8.9 are supported
Update contributed projects to their latest versions
#3
Token module
Webform
type: module
name: Token
description: Provides a user interface for the Token API...
core_version_requirement: ^8.8 || ^9
8.x-1.7
Token module
Key introduced in Drupal 8.7.7
and Drupal 8.8.0
6.0.0-alpha2
Semantic versioning now available for all projects
Webform module
Top 200 projects
Remove deprecated API use in your custom projects
#4
Update core itself
to Drupal 9
#5
Recap
- Ensure your environment is compatible with Drupal 9
- Keep Drupal 8 core up-to-date
- Update contributed projects to their latest versions
- Remove deprecated API use in your custom projects
- Update core itself to Drupal 9
8
9
Upgrade Tools
/**
* Sets a message to display to the user.
*
* [...]
*
* @deprecated in drupal:8.5.0 and is removed from drupal:9.0.0.
* Use \Drupal\Core\Messenger\MessengerInterface::addMessage() instead.
*/
function drupal_set_message($message = NULL, $type = 'status', $repeat = FALSE) {
@trigger_error('drupal_set_message() is deprecated in Drupal 8.5.0 and will be removed before Drupal 9.0.0. Use \\Drupal\\Core\\Messenger\\MessengerInterface::addMessage() instead. See https://www.drupal.org/node/2774931', E_USER_DEPRECATED); $messenger = \Drupal::messenger();
if (isset($message)) {
$messenger
->addMessage($message, $type, $repeat);
}
return $messenger
->all();
}
Upgrade Status
Upgrade Rector
(drupal-rector)
Covers 42% of
all issues found
in all drupal.org projects
!
Run your automated tests against Drupal 9.0.0
# drupalci.yml to add and run with Drupal 8.
build:
assessment:
validate_codebase:
# Static analysis of code for @deprecated uses.
phpstan:
halt-on-fail: false
No tests, or not enough coverage?
dev.acquia.com/drupal9
What are the new
features of Drupal 9?
"The big deal about Drupal 9 is ... that it should not be a big deal"
Dries Buytaert
First release with new features is 9.1.0 on
December 2, 2020
Summary
-
Drupal 7 to 8/9 is the last big step
-
Vendor Extended Support is provided until end of 2025
-
-
Drupal 8 to 9 is the easiest upgrade in a decade
-
Keep up with Drupal 8 core and contributed projects
-
Remove your own deprecated API use with tools
-
When all components are ready, upgrade to 9
-
You are getting ready in your Drupal 8 site
-
- Drupal 9 will continue to get exciting new features
Read more and discuss
Drupal 9 landing page: drupal.org/9
Status of contrib projects: dev.acquia.com/drupal9
Ask questions: drupal.slack.com #d9readiness channel
Slack meetings every other Monday at 7pm UTC
Thanks!
@gaborhojtsy @amberhimesmatz
Review links, check out speaker notes and present your own from slides.com/gaborhojtsy/state-of-drupal9
Evaluate this session at www.surveymonkey.com/r/
DCGlobal20SessionEval?title=DeepDiveD9&id=30513
Contribute with us all week at
contrib2020.getopensocial.net
2020 | 2021 | 2022 | 2023 | 2024 |
---|
Q1 | Q2 | Q3 | Q4 | Q1 | Q2 | Q3 | Q4 |
---|
Q1 | Q2 | Q3 | Q4 | Q1 | Q2 | Q3 | Q4 |
---|
Q1 | Q2 | Q3 | Q4 |
---|
8.9 | |||||||
---|---|---|---|---|---|---|---|
9.0 | 9.1 | 9.2 | 9.3 |
9.4 |
Drupal 9 security and
bug fix support
Drupal 8 security and
bug fix support
Drupal 7 security and
bug fix support
Vendor extended commercial
support for Drupal 7
Drupal 10 security and
bug fix support
10.0 | 10.1 | 10.2 | 10.3 | ||||
Deep Dive: State of Drupal 9 -- for DrupalCon Global
By Gábor Hojtsy
Deep Dive: State of Drupal 9 -- for DrupalCon Global
- 3,920