Problem/Motivation

As drupal supports autowire add aliases to services.

Core CR: https://www.drupal.org/node/3218156

Proposed resolution

Create service aliases for public services:
- flag
- flag.link_builder

Remaining tasks

- Create aliases

User interface changes

No changes

API changes

Should not be any

Data model changes

No changes

Issue fork flag-3455365

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

kbrodej created an issue. See original summary.

kbrodej’s picture

Assigned: kbrodej » Unassigned
ivnish’s picture

Status: Active » Needs work
Issue tags: +Needs reroll

MR needs rebase

tr made their first commit to this issue’s fork.

tr’s picture

Status: Needs work » Active
Issue tags: -Needs reroll

Rebased. But why are only two of the services aliased?

tr’s picture

Status: Active » Needs work

Also, why just add the aliases? Why not change the service classes to use the autowiring? That is where the real benefit comes in, and that also serves as a tests to demonstrate that the change to both flag.services.yml and the service implementation classes are correct.

ivnish’s picture

Version: 8.x-4.x-dev » 5.x-dev
Category: Feature request » Task

deaom made their first commit to this issue’s fork.

deaom’s picture

Title: Alias services for autowiring » Update services for autowiring
Status: Needs work » Needs review

Based on comment #7 updated the services to use autowire where possible, meaning plugin managers do not use it. Updated the kernel tests to show autowire works. The issue with previous composer failing is because of #3564269: Composer 2.9 blocks dependencies which have security advisories. Can be ignored until fixed. Marking the issue as needs review as other tests are passing.

  • ivnish committed 21f58491 on 5.x authored by kbrodej
    refactor: #3455365 Update services for autowiring
    
    By: kbrodej
    By:...
ivnish’s picture

Status: Needs review » Fixed

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.