diff --git a/example/apollo-server/authScopes.js b/example/apollo-server/authScopes.js index 4f1d244b..672e8f48 100644 --- a/example/apollo-server/authScopes.js +++ b/example/apollo-server/authScopes.js @@ -3,13 +3,11 @@ import { ApolloServer } from 'apollo-server'; import neo4j from 'neo4j-driver'; // JWT -// eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyLCJzY29wZXMiOlsicmVhZDp1c2VyIiwiY3JlYXRlOnVzZXIiXX0.jCidMhYKk_0s8aQpXojYwZYz00eIG9lD_DbeXRKj4vA // scopes // "scopes": ["read:user", "create:user"] // JWT_SECRET -// oqldBPU1yMXcrTwcha1a9PGi9RHlPVzQ const typeDefs = ` type User { diff --git a/package-lock.json b/package-lock.json index c35a5dc3..e0f2904e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { - "name": "neo4j-graphql-js", - "version": "2.19.0", + "name": "@cognite/neo4j-graphql-js", + "version": "2.19.1", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index eb0d8479..7c055140 100755 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { - "name": "neo4j-graphql-js", - "version": "2.19.1", + "name": "@cognite/neo4j-graphql-js", + "version": "2.19.3", "description": "A GraphQL to Cypher query execution layer for Neo4j. ", "main": "./dist/index.js", "scripts": { @@ -36,7 +36,7 @@ "license": "Apache-2.0", "repository": { "type": "git", - "url": "git+https://github.com/neo4j-graphql/neo4j-graphql-js" + "url": "git+https://github.com/neo4j-graphql/neo4j-graphql-js.git" }, "devDependencies": { "@apollo/federation": "^0.20.7", @@ -94,5 +94,13 @@ "prettier --write", "git add" ] + }, + "bugs": { + "url": "https://github.com/neo4j-graphql/neo4j-graphql-js/issues" + }, + "homepage": "https://github.com/neo4j-graphql/neo4j-graphql-js#readme", + "directories": { + "example": "example", + "test": "test" } } diff --git a/src/index.js b/src/index.js index 099fae19..e5882104 100644 --- a/src/index.js +++ b/src/index.js @@ -318,11 +318,12 @@ export const assertSchema = ({ driver, schema, dropExisting = true, - debug = false + debug = false, + sessionParams = {} }) => { const statement = schemaAssert({ schema, dropExisting }); const executeQuery = driver => { - const session = driver.session(); + const session = driver.session(sessionParams); return session .writeTransaction(tx => tx.run(statement).then(result => { @@ -341,8 +342,13 @@ export const assertSchema = ({ }); }; -export const searchSchema = async ({ driver, schema, debug = false }) => { - const session = driver.session(); +export const searchSchema = async ({ + driver, + schema, + debug = false, + sessionParams = {} +}) => { + const session = driver.session(sessionParams); // drop all search indexes, given they cannot be updated via a second CALL to createNodeIndex const dropStatement = ` CALL db.indexes() YIELD name, provider WHERE provider = "fulltext-1.0"