@rebasepro/server-postgres 0.17.1 → 0.17.2-canary.g4d21a53
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.
- package/dist/{backup-service-BtgHxfFm.js → backup-service-DCk7KhhL.js} +3 -3
- package/dist/{backup-service-BtgHxfFm.js.map → backup-service-DCk7KhhL.js.map} +1 -1
- package/dist/cli-helpers.d.ts +26 -14
- package/dist/{collection-index-DxJBvVTH.js → collection-index-BRUg10H5.js} +2 -2
- package/dist/{collection-index-DxJBvVTH.js.map → collection-index-BRUg10H5.js.map} +1 -1
- package/dist/{ensure-collection-policies-BHk4TRuf.js → ensure-collection-policies-UCqgv_8c.js} +4 -4
- package/dist/{ensure-collection-policies-BHk4TRuf.js.map → ensure-collection-policies-UCqgv_8c.js.map} +1 -1
- package/dist/{ensure-collection-tables-DMjOkeRy.js → ensure-collection-tables-DgVixhX3.js} +256 -38
- package/dist/ensure-collection-tables-DgVixhX3.js.map +1 -0
- package/dist/index.es.js +12 -12
- package/dist/{rls-bootstrap-sql-DNzaWd4C.js → rls-bootstrap-sql-B5C9LoJ6.js} +2 -2
- package/dist/{rls-bootstrap-sql-DNzaWd4C.js.map → rls-bootstrap-sql-B5C9LoJ6.js.map} +1 -1
- package/dist/{rls-enforcement-C1RJ1uI2.js → rls-enforcement-DvAbL9YJ.js} +3 -3
- package/dist/{rls-enforcement-C1RJ1uI2.js.map → rls-enforcement-DvAbL9YJ.js.map} +1 -1
- package/dist/schema/atlas-argv.d.ts +58 -0
- package/dist/schema/carved-out-migration.d.ts +65 -0
- package/dist/schema/ensure-collection-tables.d.ts +13 -1
- package/dist/schema/generate-postgres-ddl-logic.d.ts +57 -5
- package/dist/schema/vector-index.d.ts +120 -0
- package/dist/{src-DiDgtX8P.js → src-DiB5RP2Z.js} +33 -3
- package/dist/{src-DiDgtX8P.js.map → src-DiB5RP2Z.js.map} +1 -1
- package/dist/{websocket-g1Ji7m4o.js → websocket-BZ4H5wUz.js} +19 -9
- package/dist/websocket-BZ4H5wUz.js.map +1 -0
- package/package.json +6 -6
- package/src/cli-helpers.ts +65 -34
- package/src/cli.ts +168 -71
- package/src/schema/atlas-argv.ts +94 -0
- package/src/schema/carved-out-migration.ts +404 -0
- package/src/schema/ensure-collection-tables.ts +59 -32
- package/src/schema/generate-postgres-ddl-logic.ts +147 -21
- package/src/schema/generate-postgres-ddl.ts +59 -6
- package/src/schema/generate-schema-commit.ts +31 -6
- package/src/schema/vector-index.ts +213 -0
- package/dist/ensure-collection-tables-DMjOkeRy.js.map +0 -1
- package/dist/websocket-g1Ji7m4o.js.map +0 -1
package/dist/cli-helpers.d.ts
CHANGED
|
@@ -67,23 +67,35 @@ export declare function applySearchDdl(databaseUrl: string, drizzleDir?: string)
|
|
|
67
67
|
*/
|
|
68
68
|
export declare function getSearchExcludes(collectionsPath: string): Promise<string[]>;
|
|
69
69
|
/**
|
|
70
|
-
*
|
|
70
|
+
* The generated SQL for the project's `vector` properties, if it has any.
|
|
71
71
|
*
|
|
72
|
-
*
|
|
73
|
-
*
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
*
|
|
78
|
-
*
|
|
79
|
-
*
|
|
80
|
-
*
|
|
72
|
+
* @param drizzleDir directory holding the generated SQL. Defaults to `drizzle`
|
|
73
|
+
* under the working directory.
|
|
74
|
+
*/
|
|
75
|
+
export declare function readVectorDdl(drizzleDir?: string): string;
|
|
76
|
+
/**
|
|
77
|
+
* Install pgvector and bring the vector columns and their ANN indexes up to
|
|
78
|
+
* date.
|
|
79
|
+
*
|
|
80
|
+
* Runs *after* Atlas, like {@link applySearchDdl} and for the same reason: the
|
|
81
|
+
* statements are `ALTER TABLE … ADD COLUMN`, so the table has to exist. Atlas
|
|
82
|
+
* is told to ignore these objects entirely ({@link getVectorExcludes}) — it
|
|
83
|
+
* cannot manage a type its dev database is structurally incapable of having,
|
|
84
|
+
* and left to itself it would plan a `DROP COLUMN` for every one.
|
|
85
|
+
*
|
|
86
|
+
* A no-op when no collection declares a `vector` property. A failure is *not*
|
|
87
|
+
* swallowed: a push that reported success while the embedding column never
|
|
88
|
+
* appeared is how a project ends up with vector search configured, no error
|
|
89
|
+
* anywhere, and no results.
|
|
90
|
+
*/
|
|
91
|
+
export declare function applyVectorDdl(databaseUrl: string, drizzleDir?: string): Promise<void>;
|
|
92
|
+
/**
|
|
93
|
+
* Glob patterns keeping Atlas away from the vector objects.
|
|
81
94
|
*
|
|
82
|
-
*
|
|
83
|
-
*
|
|
84
|
-
* and really are missing, Atlas says so a moment later in its own words.
|
|
95
|
+
* Returns an empty list — and so changes nothing — for a project with no
|
|
96
|
+
* `vector` property, which is every project that has not opted in.
|
|
85
97
|
*/
|
|
86
|
-
export declare function
|
|
98
|
+
export declare function getVectorExcludes(collectionsPath: string): Promise<string[]>;
|
|
87
99
|
/**
|
|
88
100
|
* Query the live database for every user table/view outside the system
|
|
89
101
|
* catalogs. Separated from {@link getTableExcludes} so its failure mode can
|
|
@@ -2,7 +2,7 @@ import { createRequire as __createRequire } from "module";
|
|
|
2
2
|
import "process";
|
|
3
3
|
__createRequire(import.meta.url);
|
|
4
4
|
import { d as __require, l as __commonJSMin } from "./connection-GOKU3Hu5.js";
|
|
5
|
-
import {
|
|
5
|
+
import { a as RLS_UID_SQL, b as sortKeyToString, c as getDeclaredSubcollections, f as getDataSourceCapabilities, g as REST_TO_CANONICAL, h as NULL_OPS, i as RLS_ROLES_SQL, l as isPostgresCollectionConfig, m as CANONICAL_TO_REST, o as rewriteLegacyRlsFunctions, p as ALL_WHERE_FILTER_OPS, u as isRelationalCollectionConfig, v as isRelationAggregateSort, x as toCanonicalOp } from "./src-DiB5RP2Z.js";
|
|
6
6
|
//#region ../types/src/errors.ts
|
|
7
7
|
/**
|
|
8
8
|
* The single error type thrown across the entire Rebase client surface —
|
|
@@ -5687,4 +5687,4 @@ var buildCollectionIndexPlan = (collections, resolveColumnName) => collections.f
|
|
|
5687
5687
|
//#endregion
|
|
5688
5688
|
export { sortCollectionsBySlug as A, getPolicyNamesForRule as B, getTableName as C, getDeclaredPrimaryKeys as D, buildCompositeId as E, firstFreeKey as F, DEFAULT_ONE_OF_TYPE as G, mergeDeep as H, generateForeignKeyName as I, resolveClientListLimit as J, DEFAULT_ONE_OF_VALUE as K, legacyForeignKeyName as L, createRelationRefWithData as M, normalizeToEntityRelation as N, isAddressableId as O, updateDateAutoValues as P, Vector as Q, toPostgresIdentifier as R, getEnumVarName as S, resolveCollectionRelations as T, camelCase as U, isPrototypePollutingKey as V, toSnakeCase as W, hasForeignKeyOnTarget as X, ANONYMOUS_USER_ID as Y, isManyToMany as Z, securityRuleToConditions as _, buildSdkData as a, findRelation as b, parseOrderBySpecStrict as c, getJunctionCollectionConfig as d, getJunctionSecurityRules as f, policyToPostgres as g, getInjectedSecurityRules as h, collectionIndexStatements as i, createRelationRef as j, parseIdValues as k, CollectionRegistry as l, getEffectiveSecurityRules as m, buildCollectionIndexSpecs as n, OrderBySpecError as o, resolveJunctionSpecs as p, ListLimitError as q, collectionIndexStatement as r, normalizeDriverOrderBy as s, buildCollectionIndexPlan as t, relationalCollections as u, findAnonymousGrants as v, getTableVarName as w, getColumnName as x, fieldKeyForColumn as y, toWireKey as z };
|
|
5689
5689
|
|
|
5690
|
-
//# sourceMappingURL=collection-index-
|
|
5690
|
+
//# sourceMappingURL=collection-index-BRUg10H5.js.map
|