0.0.253 • Published 8 months ago
quidproquo-neo4j v0.0.253
quidproquo-neo4j
- Go to https://neo4j.com/product/auradb/
- Select Start Free to set up a free database.
- Create an account (I used Sign in with Google).
- Agree to the Terms of Service and Privacy Policy.
- Choose an instance type; for development, I used AuraDB Free since it’s free.
- Save the credentials for
Instance01(we will need this later). - Wait for
Instance01to create (this could take a few minutes). - Add the database to your QPQ config, give it a name; I will call mine
graph.
import { defineGraphDatabaseNeo4j } from 'quidproquo-neo4j';
export default [
// other config
defineGraphDatabaseNeo4j('graph', apiBuildPath)
];- Deploy your service.
- Once the Neo4j database is created, under the name, you should see an instance ID. It will also be in the connection URI at the bottom, like this:
neo4j+s://XXXXXXXX.databases.neo4j.io.
- Note that instance ID down, we will need it for our config.
- On your deployed site, update the parameter
neo4j-${databaseName}-instancewith the instance ID we just got. - Update the secret
neo4j-${databaseName}-passwordwith the password we downloaded earlier. - You should then be able to run queries using QPQ.
const responseA = yield* askGraphDatabaseExecuteOpenCypherQuery(
'graph',
GraphDatabaseInstanceType.Write,
`
CREATE (p:Person $personProps)
CREATE (b:Backpack $backpackProps)
CREATE (p)-[:OWNS]->(b)
RETURN p, b
`,
{
personProps: { id: '1234', name: 'Joe', age: 30 },
backpackProps: { brand: 'Fun', color: 'Red' },
}
);
const responseB = yield* askGraphDatabaseExecuteOpenCypherQuery(
'graph',
GraphDatabaseInstanceType.Read,
'MATCH (a) RETURN a LIMIT 10'
);Notes
To set a version, you can pass it via the config
import { defineGraphDatabaseNeo4j, Neo4jVersion } from 'quidproquo-neo4j';
defineGraphDatabaseNeo4j('graph', apiBuildPath, Neo4jVersion.Version5)0.0.238
12 months ago
0.0.237
1 year ago
0.0.236
1 year ago
0.0.239
10 months ago
0.0.252
8 months ago
0.0.251
9 months ago
0.0.250
9 months ago
0.0.253
8 months ago
0.0.249
9 months ago
0.0.248
9 months ago
0.0.247
9 months ago
0.0.246
9 months ago
0.0.241
10 months ago
0.0.240
10 months ago
0.0.245
9 months ago
0.0.244
9 months ago
0.0.243
10 months ago
0.0.242
10 months ago
0.0.235
1 year ago
0.0.234
1 year ago
0.0.233
1 year ago
0.0.232
1 year ago
0.0.231
1 year ago
0.0.230
1 year ago