Add missing Merge Request features to GraphQL API
Problem to solve
The GraphQL API cannot be used to express queries that we can perform in the REST API. This means that clients have to write multiple queries where one might suffice, and GitLab instances suffer from waste of resources.
Some missing features include:
-
MergeRequest.author
field is missing - cannot filter
Project.mergeRequests
by any useful search criteria (branch names, labels, state, search strings) - cannot sort
- cannot find merge requests by author or assignee
Intended users
- Sasha (Software Developer) will write queries to fetch data about merge requests. This will take less time and be more performant.
- Dana (Data Analyst) can use GraphQL aware tools more effectively if this functionality is available. -->
Proposal
Bring GraphQL up to feature parity with REST api with respect to Merge Requests.
Documentation
GraphQL documentation is automated and enforced by static checks.
Availability & Testing
New GraphQL features need unit tests (at the type, field, resolver, finder and request level).
What does success look like, and how can we measure that?
Tools that use the REST api for merge requests can always be re-written to use the GraphQL api.