@rebasepro/server-postgres 0.16.1-canary.g6b5da92 → 0.16.1-canary.g7666df7

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/index.es.js CHANGED
@@ -5,7 +5,7 @@ import { a as createReadReplicaConnection, c as poolMaxCeiling, i as createPostg
5
5
  import { C as getTableName$1, F as firstFreeKey, I as generateForeignKeyName, J as resolveClientListLimit, L as legacyForeignKeyName, T as resolveCollectionRelations, U as camelCase, W as toSnakeCase, Z as isManyToMany, c as parseOrderBySpecStrict, l as CollectionRegistry, o as OrderBySpecError, q as ListLimitError, z as toWireKey } from "./collection-index-DxJBvVTH.js";
6
6
  import { l as isRelationalCollectionConfig } from "./src-DiDgtX8P.js";
7
7
  import { d as authUsersColumnSql, u as AUTH_USERS_COLUMNS } from "./ensure-collection-tables-DMjOkeRy.js";
8
- import { C as deriveRowAddress, E as buildPropertyCallbacks, S as getUnknownFilterFieldsMode, T as warnOnKeysTheAdminCannotResolve, _ as sanitizeErrorForClient, a as AuthenticatedPostgresBackendDriver, b as configureUnknownFilterFields, c as RoleSwitchUnavailableError, d as generateSchema, f as getDrizzleColumn, g as extractPgError, h as classifyConnectFailure, l as effectiveSqlRole, m as DataService, n as PUBLIC_TYPES, o as CONNECTION_OWNER, p as BranchService, r as createPostgresWebSocket, s as PostgresBackendDriver, t as ADMIN_ONLY_TYPES, u as isRoleSwitchingOptedOut, v as DrizzleConditionBuilder, w as getPrimaryKeys, x as escapeLikePattern, y as PostgresConditionBuilder } from "./websocket-CUnpSe8v.js";
8
+ import { C as deriveRowAddress, E as buildPropertyCallbacks, S as getUnknownFilterFieldsMode, T as warnOnKeysTheAdminCannotResolve, _ as sanitizeErrorForClient, a as AuthenticatedPostgresBackendDriver, b as configureUnknownFilterFields, c as RoleSwitchUnavailableError, d as generateSchema, f as getDrizzleColumn, g as extractPgError, h as classifyConnectFailure, l as effectiveSqlRole, m as DataService, n as PUBLIC_TYPES, o as CONNECTION_OWNER, p as BranchService, r as createPostgresWebSocket, s as PostgresBackendDriver, t as ADMIN_ONLY_TYPES, u as isRoleSwitchingOptedOut, v as DrizzleConditionBuilder, w as getPrimaryKeys, x as escapeLikePattern, y as PostgresConditionBuilder } from "./websocket-HcyLl1ZM.js";
9
9
  import { a as warnOnAnonymousGrants, c as REBASE_USER_ROLE, i as validatePolicyPgRoles, l as revokeInternalTableAccess, n as detectConnectionPosture, o as warnOnLegacyRlsFunctions, r as ensureAppRole, s as warnOnRoleSchemaCollision, t as applyAuthContext, u as revokeInternalTableSql } from "./rls-enforcement-CInuYj1-.js";
10
10
  import { A as parseDbNameFromUrl, C as buildRowSecurityPgOptions, D as joinStorageKey, E as globalsFileForDump, F as withDatabaseName, M as resolveConnectionString, N as serverVersionNumToMajor, O as parseBackupDestination, P as splitGlobalsStatements, S as buildPgRestoreListArgs, T as diagnoseRowSecurityDumpFailure, _ as selectBackupsToPrune, a as detectToolMajor, b as buildPgDumpallGlobalsArgs, c as getServerVersionMajor, d as pruneBackups, f as resolvePgBinary, g as require_source, h as validateDump, i as createDump, j as parsePgToolMajor, k as parseBackupTimestamp, l as listBackups, m as uploadBackup, n as applyGlobals, o as discardPartialDump, p as restoreDump, s as ensureDatabaseExists, t as BackupToolError, u as preflight, v as buildBackupFilename, w as checkToolServerCompatibility, x as buildPgRestoreArgs, y as buildPgDumpArgs } from "./backup-service-BtgHxfFm.js";
11
11
  import { t as RLS_BOOTSTRAP_STATEMENTS } from "./rls-bootstrap-sql-DNzaWd4C.js";
@@ -1888,13 +1888,13 @@ var RealtimeService = class RealtimeService extends EventEmitter {
1888
1888
  }
1889
1889
  }
1890
1890
  }
1891
+ await this.presenceStoreOp(() => this.presenceStore.removeClient(clientId), "client removal");
1891
1892
  for (const [channel, members] of this.channels.entries()) if (members.has(clientId)) {
1892
1893
  members.delete(clientId);
1893
1894
  this.removePresence(clientId, channel, { skipStore: true });
1894
1895
  if (members.size === 0) this.channels.delete(channel);
1895
1896
  }
1896
1897
  for (const [channel] of this.presence) this.removePresence(clientId, channel, { skipStore: true });
1897
- this.presenceStoreOp(() => this.presenceStore.removeClient(clientId), "client removal");
1898
1898
  }
1899
1899
  async handleMessage(clientId, message, authContext) {
1900
1900
  const payload = message.payload;
@@ -6956,7 +6956,7 @@ function createPostgresBootstrapper(pgConfig) {
6956
6956
  },
6957
6957
  mountRoutes(app, basePath, driverResult) {},
6958
6958
  async initializeWebsockets(server, realtimeService, driver, config, adapter) {
6959
- const { createPostgresWebSocket } = await import("./websocket-CUnpSe8v.js").then((n) => n.i);
6959
+ const { createPostgresWebSocket } = await import("./websocket-HcyLl1ZM.js").then((n) => n.i);
6960
6960
  createPostgresWebSocket(server, realtimeService, driver, config, adapter);
6961
6961
  }
6962
6962
  };