Skip to content
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

Added possibility to propagate subscription error properly #419

Commits on Nov 11, 2020

  1. Added possibility to subscription error properly

    After a subscription has started and sent some results to the user, from the resolver
    perspective, it's not right now possible to propagate error correctly to the user using the
    top-level object.
    
    Since a `chan <type>` type is required for the top-level subscription resolver, it cannot
    convey any error information. By adding a `SubscriptionError` interface that top-level
    resolver's object can implement, the library upon reception of the result from the channel
    can check if it implements the `SubscriptionError` interface, if it's the case and the
    interface's method returned a non-nil error, the subscription is terminated, the channel
    is closed and the error is propagated to the user.
    Matthieu Vachon committed Nov 11, 2020
    Configuration menu
    Copy the full SHA
    18f0128 View commit details
    Browse the repository at this point in the history