-
Notifications
You must be signed in to change notification settings - Fork 2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
core: return PersistedQueryNotSupported for Apollo Persisted Queries (#…
…982) Apollo Persisted Queries is a standard for sending queries as short hashes instead of full strings, designed to work well with GET requests. It is implemented by servers including the Apollo Engine Proxy, and by the apollo-link-persisted-query client. A common configuration is to set up persisted queries on production servers but not in development. It is still convenient to leave apollo-link-persisted-query always on, though. While apollo-link-persisted-query can detect that servers don't support PQs, it works better if the server actually says it doesn't support the PQ, instead of trying to process a request without a query and potentially printing a confusing stack trace. This commit makes apollo-server directly return PersistedQueryNotSupported instead of allowing confusing stack traces to occur.
- Loading branch information
Showing
2 changed files
with
89 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters