Lucas Munhoz
08/14/2018, 10:01 AMandrey
08/14/2018, 11:27 AMmartin
08/14/2018, 1:50 PMdex
08/14/2018, 3:12 PMMike
08/14/2018, 9:59 PMCCBCodeMonkey
08/15/2018, 3:43 AMCCBCodeMonkey
08/15/2018, 3:43 AMCCBCodeMonkey
08/15/2018, 3:44 AMCCBCodeMonkey
08/15/2018, 3:46 AMCCBCodeMonkey
08/15/2018, 3:46 AMCCBCodeMonkey
08/15/2018, 3:47 AMCCBCodeMonkey
08/15/2018, 4:14 AMCCBCodeMonkey
08/15/2018, 4:17 AMCCBCodeMonkey
08/15/2018, 4:18 AMCCBCodeMonkey
08/15/2018, 4:18 AMCCBCodeMonkey
08/15/2018, 4:18 AMCCBCodeMonkey
08/15/2018, 4:19 AMCCBCodeMonkey
08/15/2018, 4:19 AMGareth
08/15/2018, 7:26 AMMoritz
08/15/2018, 8:29 AMconst getUser = async (resolve, root, args, context, info) => {
//context.user = await userServiceBinding.query.authenticateUser(context);
console.log("first middlewhere called");
const result = await resolve(root, args, context, info)
console.log("second middlewhere called");
return null;
}
const server = new GraphQLServer({
typeDefs: './src/schema.graphql',
resolvers,
middlewares: [getUser],
context: req => ({
...req,
db: new Prisma({
endpoint: '<https://eu1.prisma.sh/twigbit/vos_objectservice/dev>', // the endpoint of the Prisma API
debug: true, // log all GraphQL queries & mutations sent to the Prisma API
// secret: 'mysecret123', // only needed if specified in `database/prisma.yml`
}),
}),
})
server.start(() => console.log('Server is running on <http://localhost:4000'>))
However, when I start the server using yarn dev
, the middlewhere is called a lot without me fireing any queries or mutations against the server (console output: ) first middlewhere called
first middlewhere called
first middlewhere called
first middlewhere called
first middlewhere called
second middlewhere called
second middlewhere called
second middlewhere called
second middlewhere called
second middlewhere called
Any ideas why this might be happening?Moritz
08/15/2018, 9:10 AMgraphql-bindings
? Thanks!Moritz
08/15/2018, 9:13 AMEmil
08/15/2018, 10:20 AMsandman
08/15/2018, 10:55 AMNick
08/15/2018, 12:16 PMimport { importSchema } from 'graphql-import'
in one of the typescript version
https://github.com/graphql-boilerplates/typescript-graphql-server/blob/master/basic/src/index.ts
I wonder is the import statement doing anything at all?halborg
08/15/2018, 12:36 PM.env
files along with Bitbucket Pipelines without having to commit the .env
files?cory
08/15/2018, 12:59 PMcory
08/15/2018, 12:59 PMcory
08/15/2018, 1:00 PMclient -> graphql server -> prisma api -> database
cory
08/15/2018, 1:00 PMgraphql server
piece?