Commit graph

382 commits

Author SHA1 Message Date
Evans Hauser
086ac9f9b0
apollo-server: use node's url module for path creation 2018-05-11 15:53:13 -07:00
Evans Hauser
21b68a849d
apollo-server: comment how graphqlPath uses /graphql as default 2018-05-11 15:53:13 -07:00
Evans Hauser
80f96fc862
apollo-server: cleared up comment on default application of middleware 2018-05-11 15:53:13 -07:00
Evans Hauser
0a770964be
graphiql > gui and make content-type check only if necessary 2018-05-11 15:53:12 -07:00
Evans Hauser
68a368b775
shared graphql ide and execution for koa 2018-05-11 15:53:12 -07:00
Evans Hauser
1b672e5c8f
fix default path to return /graphql rather than undefined 2018-05-11 15:53:12 -07:00
Evans Hauser
1e3e23cf08
implemeted shared route for graphql ide and exection by checking request details 2018-05-11 15:53:12 -07:00
Evans Hauser
33e976fae6
apollo-server: add accepts and remove unused packages 2018-05-11 15:53:12 -07:00
Evans Hauser
27c12d94bf
graphiql to a boolean and add graphqlPath to url on listen return 2018-05-11 15:53:11 -07:00
Evans Hauser
541476f3be
accept non application/json for simple get requests with ?query= 2018-05-11 15:53:11 -07:00
Evans Hauser
05fd515d5c
default apollo-server offers graphiql at all endpoints if request not application/json 2018-05-11 15:53:11 -07:00
Evans Hauser
93efedf6f3
apollo-server: add health check endpoint (#992)
* apollo-server: add health check with async callback for backend querying

* apollo-server: add changelog entry

* change to engine healthcheck url, add disable, 503 on fail and conform to rfc

* apollo-server: fixed health check comment grammar and location

* update changelog to include new endpoint
2018-05-11 15:53:11 -07:00
Evans Hauser
0992208e69
apollo-server: add prepublish command 2018-05-11 15:53:11 -07:00
Evans Hauser
e20755142a
add error for passing app to nonvariant and added /graphiql callout 2018-05-11 15:53:10 -07:00
Evans Hauser
1fdef0c5f5
apollo-server: npm compile uses cp to avoid breaking npm linked code 2018-05-11 15:53:10 -07:00
James Baxley
4a06ca4b6f
update from feedback 2018-05-11 15:53:10 -07:00
Evans Hauser
d88100aca8
errors: change formatError to internalFormatError and fix when user defines formatError 2018-05-11 15:53:10 -07:00
Evans Hauser
cb09fef524
Errors: latest codes and add exports to the apollo-server package 2018-05-11 15:53:10 -07:00
James Baxley
59e68a2b25
how did a yarn lockfile get here? 2018-05-11 15:53:09 -07:00
James Baxley
2bdc1fa19b
support all apollo-server-core options and setup build 2018-05-11 15:53:09 -07:00
Evans Hauser
35a5858125
errors: change INTERNAL_ERROR to INTERNAL_SERVER_ERROR, matching http errors 2018-05-11 15:53:09 -07:00
James Baxley
de2d9dc192
version bump with graphiql at root 2018-05-11 15:53:09 -07:00
James Baxley
b3b15e8b85
make graphiql root 2018-05-11 15:53:09 -07:00
James Baxley
6d06a1cba6
allow passing engine: true and using env variables 2018-05-11 15:53:08 -07:00
James Baxley
44a54123f9
use canary version 2018-05-11 15:53:08 -07:00
James Baxley
bdabe6259b
fix odd case in error handling 2018-05-11 15:53:08 -07:00
James Baxley
e75fbf4b53
clean up of first pass and addition of koa 2018-05-11 15:53:08 -07:00
James Baxley
4c029b09b7
clean up and ui 2018-05-11 15:53:08 -07:00
James Baxley
4ed7e5d4f2
move to using express instead of micro 2018-05-11 15:53:07 -07:00
James Baxley
f3bb8267fc
move to updated API design 2018-05-11 15:53:07 -07:00
James Baxley
a7a4e3dd07
started work on new apollo-server 2018-05-11 15:53:07 -07:00
Evans Hauser
0e68e2ec4f
errors: send stack in debug, codes, make ApolloErrors 2018-05-11 15:53:07 -07:00
renovate[bot]
e5590e5c4b
chore(deps): update dependency hapi to v17.4.0 (#1009) 2018-05-11 15:53:05 -07:00
Renovate Bot
0fb310f155
chore(deps): update dependency koa to v2.5.1 2018-05-11 15:53:05 -07:00
Renovate Bot
275057343b
chore(deps): update dependency @types/aws-lambda to v8.10.3 2018-05-11 15:53:05 -07:00
Brian Dennis
11aa855d43
docs: Fix typo in lambda package README (#999) 2018-05-11 15:53:04 -07:00
Renovate Bot
bd80dd194d
chore(deps): update dependency @adonisjs/bodyparser to v2.0.3 2018-05-11 15:53:04 -07:00
Jesse Rosenberger
9ab4f9d0f8
Merge pull request #942 from apollographql/docs-overhaul
[Work in Progress] 2.0 Documentation
2018-05-02 17:41:48 -07:00
Renovate Bot
3815aa63cf chore(deps): update dependency @types/koa-router to v7.0.28 2018-04-25 09:46:24 +00:00
Renovate Bot
d8fecdc5c8 chore(deps): update dependency @types/body-parser to v1.17.0 2018-04-25 08:02:19 +00:00
Renovate Bot
363171bff2 chore(deps): update dependency @types/aws-lambda to v8.10.2 2018-04-25 06:52:23 +00:00
David Glasser
b32e89c060 v1.3.6 2018-04-24 11:35:14 -07:00
Jesse Rosenberger
b2fa5d0c7d
Merge branch 'master' into docs-overhaul 2018-04-24 16:59:22 +03:00
David Glasser
e2df79d06c 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.
2018-04-24 06:29:07 -04:00
Jesse Rosenberger
c65b7a57bf
Merge remote-tracking branch 'origin/master' into docs-overhaul 2018-04-23 15:28:29 +03:00
Jesse Rosenberger
70c1d79a64
Bash syntax highlighting to just "Shell". 2018-04-20 19:34:35 +03:00
Renovate Bot
591b0f2cae chore(deps): update dependency typescript to v2.8.3 2018-04-20 10:02:15 +00:00
Jesse Rosenberger
9d0e7b6866
v1.3.5 2018-04-18 16:10:04 +03:00
David Glasser
cbb2b22570 core: fix HttpQueryRequest typing (#834)
This field generally gets used in `any` contexts, so the error didn't cause any compilation failures.
2018-04-18 16:00:44 +03:00
Steve Rice
083a1ee60e Avoid TypeError when querystring is present, but query missing (#964)
The express-graphql reference implementation [provides a check]
(2e27a73358/src/index.js (L201-L208))
to protect against cases where a GET request is made that does not
have a `query` parameter where the GraphQL query would be present.

Without this guard, graphql-js's `parse` will return `undefined`
for the `DocumentNode` since it has no document to read. Subsequently
passing this to `isQueryOperation` results in a `TypeError`, because
we are providing `undefined` where `getOperationAst` [expects to get
a DocumentNode](5fe39262a3/src/utilities/getOperationAST.js (L19)).

A new test file is added for `runHttpQuery`, as one previously did
not seem to exist.
2018-04-18 15:38:57 +03:00