0

When I passing existing GrpahqlSchema to buildFederatedSchema, I am getting below error

Cannot read property 'kind' of undefined

This is because when I pass GrpahqlSchema to buildFederatedSchema it is failing at its validations.

 at Object.validateSDL (/Users/alti/Projects/woundtech/woundtech-fhir-graphql/node_modules/graphql/validation/validate.js:62:24)
at Object.buildSchemaFromSDL (/Users/alti/Projects/woundtech/woundtech-fhir-graphql/node_modules/apollo-graphql/lib/schema/buildSchemaFromSDL.js:36:31)
at buildFederatedSchema (/Users/alti/Projects/woundtech/woundtech-fhir-graphql/node_modules/@apollo/federation/dist/service/buildFederatedSchema.js:32:35)

There is an open PR on this https://github.com/apollographql/apollo-server/pull/3013. Is there any alternative to this?

Srinivas
  • 294
  • 3
  • 18

1 Answers1

0

You likely have types with the same names in different graphql schemas.

Mike Lyons
  • 22,575
  • 2
  • 16
  • 19