@crvouga/mockingbird-service-postgres 3.2.0 → 3.4.0

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.
Files changed (53) hide show
  1. package/CHANGELOG.md +17 -1
  2. package/COMPATIBILITY.md +35 -5
  3. package/README.md +219 -57
  4. package/compat/coverage.json +8 -7
  5. package/compat/divergences.json +37 -2
  6. package/compat/requirements.json +1 -1
  7. package/compat/sections/cat.ts +49 -0
  8. package/compat/sections/ddl.ts +11 -0
  9. package/compat/unsupported-register.json +0 -3
  10. package/dist/admin.js +4812 -987
  11. package/dist/admin.js.map +4 -4
  12. package/dist/api/database.d.ts +11 -0
  13. package/dist/ast/nodes.d.ts +43 -1
  14. package/dist/constraints/enforce.d.ts +2 -0
  15. package/dist/executor/alter-column.d.ts +27 -0
  16. package/dist/executor/comment.d.ts +4 -0
  17. package/dist/executor/ddl.d.ts +1 -2
  18. package/dist/executor/dml.d.ts +2 -0
  19. package/dist/executor/extensions.d.ts +11 -0
  20. package/dist/executor/maintenance.d.ts +25 -0
  21. package/dist/expressions/context.d.ts +1 -1
  22. package/dist/index.d.ts +1 -1
  23. package/dist/index.js +3249 -549
  24. package/dist/index.js.map +4 -4
  25. package/dist/parser/parser.d.ts +9 -0
  26. package/dist/schema/catalog-extensions.d.ts +5 -0
  27. package/dist/schema/extensions.d.ts +33 -0
  28. package/dist/schema/index-catalog.d.ts +40 -0
  29. package/dist/schema/persistence.d.ts +32 -0
  30. package/dist/schema/storage.d.ts +22 -0
  31. package/dist/server.js +5390 -744
  32. package/dist/server.js.map +4 -4
  33. package/dist/sql/deparse-default.d.ts +12 -0
  34. package/dist/sql/deparse-index.d.ts +12 -2
  35. package/dist/sql/keywords.d.ts +6 -0
  36. package/dist/sql/ruleutils.d.ts +27 -0
  37. package/dist/storage/database-state.d.ts +51 -0
  38. package/dist/types/regnamespace.d.ts +23 -0
  39. package/dist/types/value.d.ts +2 -0
  40. package/dist/unstable.js +11520 -8875
  41. package/dist/unstable.js.map +4 -4
  42. package/dist/wire/cli.js +6445 -1260
  43. package/dist/wire/cli.js.map +4 -4
  44. package/dist/wire/cluster.d.ts +8 -0
  45. package/dist/wire/connection.d.ts +38 -0
  46. package/dist/wire/durable.d.ts +82 -0
  47. package/dist/wire/file-storage.d.ts +3 -0
  48. package/dist/wire/fleet.d.ts +210 -1
  49. package/dist/wire/index.d.ts +21 -1
  50. package/dist/wire/index.js +5383 -741
  51. package/dist/wire/index.js.map +4 -4
  52. package/dist/wire/startup.d.ts +36 -0
  53. package/package.json +1 -1
@@ -0,0 +1,36 @@
1
+ /** ErrorResponse fields of a rejected startup packet; the connection always ends with FATAL. */
2
+ export type StartupFailure = {
3
+ code: string;
4
+ message: string;
5
+ detail?: string;
6
+ hint?: string;
7
+ };
8
+ export declare class StartupError extends Error {
9
+ readonly fields: StartupFailure;
10
+ constructor(fields: StartupFailure);
11
+ }
12
+ export type StartupSetting = {
13
+ name: string;
14
+ value: string;
15
+ };
16
+ /**
17
+ * `pg_split_opts`: arguments are separated by whitespace; a backslash makes the next character
18
+ * literal (`\ ` is a space inside an argument, `\\` a backslash).
19
+ */
20
+ export declare const splitOptions: (options: string) => string[];
21
+ /**
22
+ * Every setting a startup packet asks for, in the order PostgreSQL applies them: the `options`
23
+ * switches, then the parameters sent by name (which therefore win).
24
+ */
25
+ export declare const startupSettings: (parameters: Readonly<Record<string, string>>) => StartupSetting[];
26
+ /**
27
+ * `SplitIdentifierString`: a comma-separated list of identifiers, each bare (folded to lower
28
+ * case) or double-quoted. Null when the list is malformed.
29
+ */
30
+ export declare const splitIdentifierList: (raw: string) => string[] | null;
31
+ /**
32
+ * Check `settings` and write them into `session`, a copy of the database's settings. Returns the
33
+ * values that are now the session's reset defaults. A parameter the engine has no setting for
34
+ * is `42704`, the same rule its `SET` follows; names containing a dot are custom parameters.
35
+ */
36
+ export declare const applyStartupSettings: (settings: readonly StartupSetting[], session: Map<string, string>) => Map<string, string>;
package/package.json CHANGED
@@ -185,5 +185,5 @@
185
185
  ],
186
186
  "type": "module",
187
187
  "types": "./dist/index.d.ts",
188
- "version": "3.2.0"
188
+ "version": "3.4.0"
189
189
  }