Problem/Motivation

We fully dropped the PECL YAML parser in #3205480: Drop PECL YAML library support in favor of only Symfony YAML to have more consistent YAML reading and writing and support advanced YAML features.

#3591680: Use the YAML parsing cache collector for config file storage and related issues add support for persistent caching of YAML parsing which can reduce CPU usage a lot including on relatively infrequent operations and across regular Drupal cache clears.

However, because .info.yml files are needed in the installer and also container building, we can never cache the parsing of those. We also don't need advanced YAML features.

Steps to reproduce

Proposed resolution

If the PECL YAML parser is available, use it in InfoParserDynamic

Remaining tasks

User interface changes

Introduced terminology

API changes

Data model changes

Release notes snippet

Issue fork drupal-3616275

Command icon 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

catch created an issue. See original summary.

catch’s picture

Status: Active » Needs review

catch’s picture

Attaching xhgui screenshots, as you can see it saves about 2-250ms (including xhprof overhead) - this is saved on every method of every functional test and kernel test, but it will also be saved on cache rebuilds, in the real installer etc.

longwave’s picture

Status: Needs review » Needs work

Seems like a reasonable idea when we know the YAML for these will be relatively standard.

Let's add a comment as to why this is here so when we rediscover it in the future we don't have to find this issue to remember why we did it.

catch’s picture

Status: Needs work » Needs review

Added a comment.

nicxvan’s picture

This looks like a great improvement, I was curious about the error handler swap so I asked in slack.

It's because it only triggers a warning, once we get a comment clarifying that I think this is ready.

longwave’s picture

Status: Needs review » Reviewed & tested by the community

Looks good, no further comments.