You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Avoid further processing when GraphQL request is cancelled
As of gh-1149, CANCEL signals are propagated from the transport request
up to reactive `DataFetcher`s. This efficiently cancels processing and
avoids spending resources when execution results won't be sent to the
client.
Prior to this commit, this would have no effect on non-reactive
`DataFetcher`s because they would still be executed. While we cannot
consistently cancel ongoing blocking operations, we can avoid further
processing and other `DataFetcher`s from being called by returning an
error result instead of the original result.
This commit updates the `ContextDataFetcherDecorator` to detect if the
request has been cancelled and return early a data fetcher result with a
`AbortExecutionException` error instead of the original result.
Closesgh-1153
0 commit comments