Replies: 1 comment
-
updated the question with more context |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I do have 2 schemas stitched using @graphql-tools/[email protected].
One of those two subschemas is the combination of a remote schema and a local schema which is needed to attach some custom logic to the remote schema.
For context, the remote schema speaks directly to the GraphQL interface of Dgraph, and the local schema is mandatory since it's not possible to create custom resolvers and custom logic directly in Dgraph.
This is how i accomplished to merge the two schema in a single datagraph to stitch with other services:
I noticed that when I perform queries like
it gets exploded in
because when the
deletagetToSchema" at
mergeSchemaslevel is called, the
ExpandAbstractTypestransformer sees that the remote schema has less fields in my interface than the merged one (
typeCustomDefsadds some fields which are then resolved by the attached resolvers) and causes the fragment on interface
Content ` to be expanded to all implementing types.this is causing me some trouble and it's suboptimal since the query becomes quite long and heavy pretty fast and dgraph do not accepts the that iì'm trying to resolve names on both
Computer
andProduct
(Already opened an issue).Is there a way to disable t
ExpandAbstractTypes
or a better architecture to attach resolvers to a remote source?Beta Was this translation helpful? Give feedback.
All reactions