Skip to content

Register ResolverInterface and MutationInterface for auto configuration #439

@ruudk

Description

@ruudk
Q A
Bug report? no
Feature request? yes

We are in the process of upgrading our codebase from Symfony 3.3 to Symfony 4 and want to use autowire. We were quite surprised to find out that OverBlogGraphQLBundle has it's own "auto wire" (auto mapping). We disabled that option (overblog_graphql: definitions: auto_mapping: false) but then found out that the bundle doesn't auto configure the interfaces with the given tags.

By adding the following 2 lines to our own extension, it worked:

$container->registerForAutoconfiguration(ResolverInterface::class)->addTag('overblog_graphql.resolver');
$container->registerForAutoconfiguration(MutationInterface::class)->addTag('overblog_graphql.mutation');

Is there a reason this is not added? I can make a PR to add it.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions