Skip to content

Advanced Breaking Change Detection #6649

@n1ru4l

Description

@n1ru4l

Background

Currently, we visit fields, variables, arguments, and object fields in DocumentNode, collect their return types and parent types, and turn them into schema coordinates. When a schema is modified, Hive creates a list of touched schema coordinates and checks in ClickHouse if a schema coordinate was registered or not and if it’s a breaking change or not.

This is too safe 🙂 

There are scenarios where a change detected as a breaking change might not really be a breaking change. See https://github.com/kamilkisiela/graphql-breaking-changes

Some examples:

  • Changing type String to ID does not break clients (unless the scalar is used in a operation arguments definition
  • Changing Int to Int! for an argument is not breaking if all operation argument usages already define it as Int!
  • Renaming an Object type is not breaking if the __typename is not used.

We want to be able to cover these kind of "safe" breaking changes with our breaking change detection.

Resources

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions