Skip to content

We should offer a wiring validation (and maybe mapping validator) #2244

@andimarek

Description

@andimarek

RuntimeWiring is very silent at the moment when you configure it wrong: a wrong type or not existing field registered is just accepted.

This leads often to subtle problems, especially when bootstrapping or just prototyping something.

We should offer a simple Validator test util or maybe make the Wiring optionally more strict.

A more complex problem: The return type of a DataFetcher could be validated against the Schema. When you return for example a Dog object and the DataFetcher is registered for a type returning a Dog we could validate that the field of Java class type Dog matches the Schema type Dog. This needs more exploration/discussion.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions