hasura / hasura/graphql-engine

Support for relationships from nested action fields

Open
#8,015 0 comments 21 reactions 0 assignees View on GitHub
c/actions c/server k/enhancement team-blaam/handover
Dominant language
TypeScript
Stars
32.1k
Forks
3k
PR merge metrics
PR metrics pending

Description

### Is your proposal related to a problem?

With the addition of support for nested types in actions: (https://github.com/hasura/graphql-engine/issues/4796) the next logical functionality is to add support for joining across relationships from within nested fields.

### Describe the solution you'd like

If a relationship is established from an associated action type that should be able to be traversed via field selection as with a normal GraphQL query. This would include fields within objects, arrays to arbitrary levels of nesting.

### Drawbacks

Particularly tricky scenarios include the following:

* Joins across actions
* How to ensure the optimal amount of logic is performed in the DB
* Lazily traversing fields so that self/co-recursive relationships don't cause infinite loops

### Describe alternatives you've considered

Currently we only support relationships from top-level fields.

### If the feature is approved, would you be willing to submit a PR?

Yes.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.