@cap-js/postgres 2.3.0 → 3.0.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.
package/CHANGELOG.md CHANGED
@@ -4,6 +4,24 @@
4
4
  - The format is based on [Keep a Changelog](http://keepachangelog.com/).
5
5
  - This project adheres to [Semantic Versioning](http://semver.org/).
6
6
 
7
+ ## [3.0.0](https://github.com/cap-js/cds-dbs/compare/postgres-v2.3.0...postgres-v3.0.0) (2026-06-01)
8
+
9
+
10
+ ### ⚠ BREAKING CHANGES
11
+
12
+ * require cds10 ([#1628](https://github.com/cap-js/cds-dbs/issues/1628))
13
+
14
+ ### Added
15
+
16
+ * require cds10 ([#1628](https://github.com/cap-js/cds-dbs/issues/1628)) ([93e8305](https://github.com/cap-js/cds-dbs/commit/93e83053679f9ef94293caa08917855404db880d))
17
+
18
+
19
+ ### Dependencies
20
+
21
+ * The following workspace dependencies were updated
22
+ * dependencies
23
+ * @cap-js/db-service bumped from ^2.11.0 to ^3.0.0
24
+
7
25
  ## [2.3.0](https://github.com/cap-js/cds-dbs/compare/postgres-v2.2.2...postgres-v2.3.0) (2026-04-29)
8
26
 
9
27
 
@@ -606,11 +606,10 @@ GROUP BY k
606
606
  try {
607
607
  const con = await this.factory.create(system)
608
608
  this.dbc = con
609
+ await this.exec(`SELECT pg_advisory_lock(hashtext('${creds.database}'))`)
609
610
  const exists = await this.exec(`SELECT datname FROM pg_catalog.pg_database WHERE datname='${creds.database}'`)
610
611
 
611
612
  if (exists.rowCount) return
612
- // REVISIT: cleanup database for local development
613
- if (!process._send) await this.exec(`DROP DATABASE IF EXISTS "${creds.database}"`)
614
613
  await this.exec(`
615
614
  DROP GROUP IF EXISTS "${creds.usergroup}";
616
615
  DROP USER IF EXISTS "${creds.user}";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cap-js/postgres",
3
- "version": "2.3.0",
3
+ "version": "3.0.0",
4
4
  "description": "CDS database service for Postgres",
5
5
  "homepage": "https://github.com/cap-js/cds-dbs/tree/main/postgres#cds-database-service-for-postgres",
6
6
  "repository": {
@@ -27,12 +27,12 @@
27
27
  "start": "docker compose -f pg-stack.yml up -d"
28
28
  },
29
29
  "dependencies": {
30
- "@cap-js/db-service": "^2.11.0",
30
+ "@cap-js/db-service": "^3.0.0",
31
31
  "pg": "^8"
32
32
  },
33
33
  "peerDependencies": {
34
- "@sap/cds": ">=9.8",
35
- "@sap/cds-dk": ">=9"
34
+ "@sap/cds": "^10",
35
+ "@sap/cds-dk": "^10"
36
36
  },
37
37
  "peerDependenciesMeta": {
38
38
  "@sap/cds-dk": {