aerogear / graphql-link

graphql-link is a GraphQL server that composes other GraphQL or OpenAPI endpoints
https://aerogear.github.io/graphql-link
Other
38 stars 8 forks source link

GW fails for non custom schema #38

Open wtrocki opened 4 years ago

wtrocki commented 4 years ago
listen: localhost:8080
upstreams:
  note:
    type: graphql
    url: http://127.0.0.1:4000/graphql
types:
  - name: Query
    actions:
    - type: mount
      upstream: note
      query: query {}

This happens with the latest release and master.

[wtrocki@graphapi gw ]$ /Users/wtrocki/Downloads/graphql-gw_0.2.0_mac_64bit-x86/graphql-gw serve 2020/10/13 12:38:30 downloading schema for upstream note: http://127.0.0.1:4000/graphql panic: runtime error: invalid memory address or nil pointer dereference

wtrocki commented 4 years ago

So I have done some investigations and it looks like GW is not working with latest changes to graphql spec.

directive @cacheControl(maxAge:Int, scope:CacheControlScope) on 
"Exposes a URL that specifies the behaviour of this scalar."
directive @specifiedBy(  
  "The URL that specifies the behaviour of this scalar."
  url:String!
) on

that are included into the schema crashing gw.

wtrocki commented 4 years ago

Workaround is to get schema locally. Remove directives and use --production mode. Amazing features @chirino. Really like how we can merge multiple serverless functions into single schema

chirino commented 4 years ago

Could you post the schemas that are giving you issues?

wtrocki commented 4 years ago

https://github.com/aerogear/OpenVolunteerPlatform/blob/debezium/integration/graphql-gw/upstreams/gateway.graphql

namit-chandwani commented 3 years ago

Hey, I'd like to work on this issue. What would be a good starting point for the same?

wtrocki commented 3 years ago

This actually requires updating graphql library we use to official one. #41

namit-chandwani commented 3 years ago

Okay. In that case, can I start working on issue #41 now?