Skip to content

Commit 882548e

Browse files
committed
fix: add missing schema for graphql-http
1 parent 5f0ba9d commit 882548e

5 files changed

+7
-2
lines changed

benchmarks/fastify-express-graphql-jit.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
"use strict";
22

3-
const { createHandler } = require("graphql-http/lib/use/express");
3+
const { createHandler } = require("graphql-http/lib/use/fastify");
44
const app = require("fastify")();
55

66
const { compileQuery } = require("graphql-jit");
@@ -16,6 +16,7 @@ const schema = createApolloSchema();
1616
app.post(
1717
"/graphql",
1818
createHandler({
19+
schema,
1920
execute: (_, __, { query }) => {
2021
if (!(query in cache)) {
2122
const document = parse(query);

benchmarks/fastify-express-graphql-typed-jit.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
"use strict";
22

3-
const { createHandler } = require("graphql-http/lib/use/express");
3+
const { createHandler } = require("graphql-http/lib/use/fastify");
44
const app = require("fastify")();
55
const { compileQuery } = require("graphql-jit");
66
const { parse } = require("graphql");
@@ -14,6 +14,7 @@ createTypeGraphQLSchema().then((schema) => {
1414
app.post(
1515
"/graphql",
1616
createHandler({
17+
schema,
1718
execute: (_, __, { query }) => {
1819
if (!(query in cache)) {
1920
const document = parse(query);

benchmarks/graphql-http+graphql-jit+graphql-compose.js

+1
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ const schema = createGraphqlComposeSchema();
1717
app.use(
1818
"/graphql",
1919
createHandler({
20+
schema,
2021
async parseRequestParams(req) {
2122
const params = await processRequest(req.raw, req.context.res);
2223
if (Array.isArray(params)) {

benchmarks/graphql-http+graphql-jit+type-graphql.js

+1
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ createAsyncTypeGraphQLSchema().then((schema) => {
1717
app.use(
1818
"/graphql",
1919
createHandler({
20+
schema,
2021
async parseRequestParams(req) {
2122
const params = await processRequest(req.raw, req.context.res);
2223
if (Array.isArray(params)) {

benchmarks/graphql-http+graphql-jit.js

+1
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ const cache = {};
1515
app.use(
1616
"/graphql",
1717
createHandler({
18+
schema,
1819
async parseRequestParams(req) {
1920
const params = await processRequest(req.raw, req.context.res);
2021
if (Array.isArray(params)) {

0 commit comments

Comments
 (0)