Our experience of getting ready for Drupal 10

22.05.2023

When we think of the challenges facing us in 2023, the Drupal 10 release in December of 2022 immediately comes to mind. Drupal 10 does have a lot of nice improvements, so we are very motivated to adopt it in our projects early. In this blog post, I will share our experience adopting Drupal 10 and describe the roadmap ahead.

For a comprehensive overview of Drupal 10 features we’d like to refer to drupal.org, whereas in this blogpost we will focus on the implementation process. The drupal community did great work as usual and developed an exciting and promising new version. Moreover on the release day the essential extension modules are already updated and Dupal 10 compatible.

Before we begin the upgrade process, we review the experience from the previous upgrade. In this case, it was the update from Drupal 8 to Drupal 9. From a developers perspective, it went really smoothly for all our projects. There were issues to be resolved, but due to semantic versioning, we were able to upgrade Drupal 8 sites to Drupal 9 without having to re-create the website and migrate the data (which was the major difficulty we had with Drupal 7 upgrades). We are convinced, that the update to Drupal 10 will be even more pleasant.

Shortly after the release of Drupal 9, drunomics set a goal to have Drupal 10 compatible releases for all the extension modules, which are currently maintained by drunomics, on the day of the Drupal 10 release. The reason for this is, that a specific project can only be upgraded when all the modules, that are used in the project, are compatible with the upgrade also. Many companies had already joined this initiative for the Drupal 9 release. With regard to the upcoming Drupal 10 release drunomics encouraged them once again to get involved in contributing and update extension modules. We distributed our own projects between our developers, each person becoming the maintainer of one or more modules.

drunomics launched this initiative shortly after the release of Drupal 9.4, the final minor release before the upcoming Drupal 10 release. We had 6 months to achieve our goal, so this was the right time to begin. Despite a lot of effort was also being spent on the development of our Lupus Decoupled distribution, we did a good job for Drupal 10 readiness. On the release day most of our maintained projects were Drupal 10 compatible.

More details about the preparation process of extension modules

It is recommended to check the compatibility of a single module or the entire project by using the Upgrade status module. Just give it a try and it will show you what to do. If there are a lot of changes needed you can use Drupal Rector to automatically fix deprecated code. The final step is to manually fix and test any remaining issues.

Why is it important to us to share our experiences?

Even though much of the work concerning the update of extension modules is already done, much remains. Despite the highest readiness level on the day of release, many modules did not achieve Drupal 10 readiness. At the moment of writing only 4729/9632 (~49%) of all extension modules are Drupal 10 compatible. The statistic looks better though for the most commonly installed modules:

  • Top 1000 installed modules - 82% ready
  • Top 500 installed modules - 92% ready
  • Top 100 installed modules - 96% ready

This information is tracked by Acquia on their Drupal 10 readiness dashboard.

In addition I want to say, that in most cases it is very simple to become Drupal 10 compatible, and that the process provides for beginners an easy way to earn valuable contribution credits.

What comes next?

We at drunomics can't wait to update all client projects to Drupal 10 and start using all the new features.

The drunomics development workflow follows best CI/CD practices for open-source projects. It means that we develop in smaller increments, integrate early and deploy often. To achieve this, we leverage automated testing via PHPUnit, Behat, Playwright, VRT, phpcs, phpstan, etc.

Another big part of work, that in most cases can already be done prior to the update, is the PHP update. For Drupal 10 the minimum required version is PHP 8.1, which is also supported by Drupal 9. The helper tool we used was https://github.com/PHPCompatibility/PHPCompatibility.

In addition to PHP do not forget to check other system requirements like MariaDB, Redis etc. 

Moreover this is a good opportunity to check versions of other software essential to your project, even if it's not software used by Drupal 10. For example, check if the project is using a maintained version of ElasticSearch, Solr, or others. It is highly recommended to avoid using any outdated dependencies.

We prefer to not postpone such things till the end or do everything in a huge Pull Request (PR). It may cause extra risks and possibly complicate troubleshooting in case something goes wrong.

When should you upgrade to Drupal 10? In short: early 2023.

Looks like 2023 is going to be the year of upgrades to Drupal 10. Drupal 9 will stay maintained and reach its EOL in November 2023.

Of course, Drupal 10 release doesn't mean that you must update immediately. But also it's highly recommended, not to postpone it till the last months but better prepare everything in advance as already described above. The Drupal 10 upgrade process is very promising and we expect it will be very smooth and even easier than the Drupal 9 upgrade. Nonetheless, be careful to not miss some important parts that could cause a delay.

What if your hosting provider doesn't support PHP 8.1? What if some PHP SDK-packages you're using for third-party integrations don't have PHP 8.1 compatible releases or are deprecated at all? Who knows what other challenges could be hidden in your projects? Certainly you already noticed, that sometimes things don't go a 100% according to plan.

Professinally plan such things in advance and keep your customers happy as we do.

Everything written above is assuming that you currently use Drupal 9.

Let's not forget another important thing. Statistic usage shows that about half of all Drupal projects are still running on Drupal 7 whose End-of-Life date is the same as for Drupal 9 - November 2023.

For sites running on Drupal 7, please read Blogpost #2.

 

More articles