Problem/Motivation

In Drupal 8 and 9, we used docblock attributes to find and provide metadata about plugins. PHP 8.0 introduced annotations as a first-class language feature.

Starting with Drupal core 10.2.0, plugin types should use annotations instead of attributes. We define two plugin types, ElasticSearchAnalyser, and ElasticSearchConnector. Using annotations to define plugin types will go away in Drupal 12.

Proposed resolution

Create ElasticSearchAnalyser and ElasticSearchConnector annotations. Update our plugin managers to use annotations. Update implementations in our own code to use annotations.

Write a change record.

Remaining tasks

  1. 9.0.x merge request
  2. 8.0.x merge request
  3. Community review
  4. Maintainer review
  5. Commit to 9.0.x
  6. Commit to 8.0.x
  7. Release 9.0.x
  8. Release 8.0.x

User interface changes

None.

API changes

Annotations are now available and recommended.

Data model changes

None.

Comments

mparker17 created an issue.