@loradb/lora-graphql 0.31.0 → 0.32.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5,6 +5,7 @@ import { OperationAccess } from './analyze/access.js';
5
5
  import { AccessEntry } from './analyze/verdicts.js';
6
6
  import { Statistics } from './analyze/statistics.js';
7
7
  import { CompiledRead, ReadSet } from './compile/read/types.js';
8
+ import { DriverSnapshot } from './driver.js';
8
9
  import { WriteChange } from './execute/changes.js';
9
10
  import { LoraTransaction } from './execute/transaction.js';
10
11
  import { Worker, WorkerOptions } from './events/worker.js';
@@ -195,6 +196,18 @@ export declare class LoraGraphQL {
195
196
  * sweep. `close()` stops it.
196
197
  */
197
198
  worker(type: string, options: WorkerOptions): Worker;
199
+ /**
200
+ * Write an online copy of the database into `targetDir` (missing or
201
+ * empty) while requests keep running: the graph as of one committed
202
+ * transaction, as `<targetDir>/<name>.loradb`, which opens with
203
+ * `createDatabase(name, { databaseDir: targetDir })`. Mutations wait
204
+ * only while the graph is taken, not while it is written. For an
205
+ * off-host backup of a database this process owns.
206
+ *
207
+ * Needs a driver with `snapshot()`: `loraDriver(db)` over a lora-node
208
+ * database opened with a name and `databaseDir`.
209
+ */
210
+ snapshot(targetDir: string): Promise<DriverSnapshot>;
198
211
  /** Stop the workers, and the engine change feed (with `changeFeed: true`). */
199
212
  close(): void;
200
213
  }
package/dist/testing.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { graphql as g } from "graphql";
2
- import { a as h, l as b } from "./lora-graphql-upoPizGA.js";
2
+ import { a as h, l as b } from "./lora-graphql-BW8S6TRu.js";
3
3
  async function T(l) {
4
4
  let u;
5
5
  try {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@loradb/lora-graphql",
3
- "version": "0.31.0",
3
+ "version": "0.32.1",
4
4
  "description": "Schema-first GraphQL for LoraDB: one annotated SDL becomes an executable, index-aware GraphQL API that compiles every operation to a single Cypher statement.",
5
5
  "license": "BUSL-1.1",
6
6
  "packageManager": "yarn@4.5.1",
@@ -65,7 +65,7 @@
65
65
  "bench:load": "node bench/load/main.mjs"
66
66
  },
67
67
  "peerDependencies": {
68
- "@loradb/lora-node": "^0.31.0",
68
+ "@loradb/lora-node": "^0.32.1",
69
69
  "graphql": "^16.8.0 || ^17.0.0"
70
70
  },
71
71
  "devDependencies": {