Skip to content

validate subscription function return type when generating schema #359

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
dariuszkuc opened this issue Sep 20, 2019 · 1 comment · Fixed by #476
Closed

validate subscription function return type when generating schema #359

dariuszkuc opened this issue Sep 20, 2019 · 1 comment · Fixed by #476
Assignees
Labels
good first issue A good place to start as a new contributor type: enhancement New feature or request

Comments

@dariuszkuc
Copy link
Collaborator

Is your feature request related to a problem? Please describe.
Per graphql-java docs subscription data fetchers should return some Publisher (e.g. Reactor Flux). Currently we don't perform any validations to verify that functions specified for subscriptions return valid types.

Describe the solution you'd like
Schema generator should fail generation process if subscription function returns unsupported type.

Describe alternatives you've considered
N/A

Additional context
Related issue -> #358

@dariuszkuc dariuszkuc added the type: enhancement New feature or request label Sep 20, 2019
@smyrick smyrick added the good first issue A good place to start as a new contributor label Nov 15, 2019
@smyrick smyrick self-assigned this Nov 15, 2019
@smyrick
Copy link
Contributor

smyrick commented Nov 15, 2019

Have a branch I am working on

smyrick pushed a commit to smyrick/graphql-kotlin that referenced this issue Nov 15, 2019
Subscriptions must return a org.reactivestreams.Publisher for graphql-java to work properly. An exception will now be thrown if any return type of a top level subscription is not a subclass of Publisher

Fixes ExpediaGroup#359
smyrick pushed a commit to smyrick/graphql-kotlin that referenced this issue Nov 15, 2019
Subscriptions must return a org.reactivestreams.Publisher for graphql-java to work properly. An exception will now be thrown if any return type of a top level subscription is not a subclass of Publisher

Fixes ExpediaGroup#359
dariuszkuc pushed a commit that referenced this issue Nov 19, 2019
Subscriptions must return a org.reactivestreams.Publisher for graphql-java to work properly. An exception will now be thrown if any return type of a top level subscription is not a subclass of Publisher

Fixes #359
dariuszkuc pushed a commit to dariuszkuc/graphql-kotlin that referenced this issue Aug 5, 2022
Subscriptions must return a org.reactivestreams.Publisher for graphql-java to work properly. An exception will now be thrown if any return type of a top level subscription is not a subclass of Publisher

Fixes ExpediaGroup#359
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue A good place to start as a new contributor type: enhancement New feature or request
Development

Successfully merging a pull request may close this issue.

2 participants