@getstrata/core 2.2.55 → 2.2.56
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 +5 -0
- package/README.md +1 -1
- package/dist/entries/audit/exportAuditLogs.js +1 -6
- package/dist/entries/auth/basicAuthGuard.js +1 -6
- package/dist/entries/auth/oauth/samlProvider.js +1 -6
- package/dist/entries/auth/saml/samlServiceProvider.js +1 -6
- package/dist/entries/auth/scimAuthMiddleware.js +1 -6
- package/dist/entries/http/response.js +1 -6
- package/dist/entries/jobs/exportAuditLogsJob.js +1 -6
- package/dist/entries/queue/queueMetrics.js +1 -6
- package/dist/entries/tenant/databaseTenantContext.js +1 -6
- package/dist/entries/tenant/enableTenantRls.js +1 -1
- package/dist/entries/tenant/tenantDatabaseScope.js +1 -6
- package/dist/index.js +3 -11
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
# @getstrata/core changelog
|
|
2
2
|
|
|
3
|
+
## 2.2.56
|
|
4
|
+
|
|
5
|
+
- Stop adding schema CREATE to PostgreSQL runtime roles; keep USAGE, existing object/default grants and both catalog/ACL concurrency protocols. Existing grants, PUBLIC privileges, memberships and ownership are not revoked automatically; restricted deployments can use the documented public schema-only migration runner.
|
|
6
|
+
- Require Bun >=1.4.4 and retain the native SQL timer regression matrix. Preserve ORM/transaction behavior while removing two redundant private guards; strengthen error, empty-data and adapter-metadata coverage without changing public or protected APIs.
|
|
7
|
+
|
|
3
8
|
## 2.2.55
|
|
4
9
|
|
|
5
10
|
- Align the lockstep version with the starter startup-cleanup correction. Core runtime, ORM, lifecycle policy and public/protected APIs are unchanged.
|
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @getstrata/core
|
|
2
2
|
|
|
3
|
-
Runtime library for [Strata](https://github.com/EyK-26/strata) apps: HTTP, auth, database, queue, mail, and security. Requires Bun >=1.4.
|
|
3
|
+
Runtime library for [Strata](https://github.com/EyK-26/strata) apps: HTTP, auth, database, queue, mail, and security. Requires Bun >=1.4.4 (tested on 1.4.4).
|
|
4
4
|
|
|
5
5
|
Generate an app rather than wiring this by hand:
|
|
6
6
|
|
|
@@ -138,12 +138,7 @@ function requestTransactionRollback() {
|
|
|
138
138
|
if (!state || index < 0) {
|
|
139
139
|
return;
|
|
140
140
|
}
|
|
141
|
-
|
|
142
|
-
const current = flags[index];
|
|
143
|
-
if (current === undefined) {
|
|
144
|
-
return;
|
|
145
|
-
}
|
|
146
|
-
flags[index] = true;
|
|
141
|
+
state.rollback[index] = true;
|
|
147
142
|
}
|
|
148
143
|
function scopeRequestsRollback() {
|
|
149
144
|
const state = transactionScopes.getStore();
|
|
@@ -195,12 +195,7 @@ function requestTransactionRollback() {
|
|
|
195
195
|
if (!state || index < 0) {
|
|
196
196
|
return;
|
|
197
197
|
}
|
|
198
|
-
|
|
199
|
-
const current = flags[index];
|
|
200
|
-
if (current === undefined) {
|
|
201
|
-
return;
|
|
202
|
-
}
|
|
203
|
-
flags[index] = true;
|
|
198
|
+
state.rollback[index] = true;
|
|
204
199
|
}
|
|
205
200
|
function scopeRequestsRollback() {
|
|
206
201
|
const state = transactionScopes.getStore();
|
|
@@ -339,12 +339,7 @@ function requestTransactionRollback() {
|
|
|
339
339
|
if (!state || index < 0) {
|
|
340
340
|
return;
|
|
341
341
|
}
|
|
342
|
-
|
|
343
|
-
const current = flags[index];
|
|
344
|
-
if (current === undefined) {
|
|
345
|
-
return;
|
|
346
|
-
}
|
|
347
|
-
flags[index] = true;
|
|
342
|
+
state.rollback[index] = true;
|
|
348
343
|
}
|
|
349
344
|
function scopeRequestsRollback() {
|
|
350
345
|
const state = transactionScopes.getStore();
|
|
@@ -339,12 +339,7 @@ function requestTransactionRollback() {
|
|
|
339
339
|
if (!state || index < 0) {
|
|
340
340
|
return;
|
|
341
341
|
}
|
|
342
|
-
|
|
343
|
-
const current = flags[index];
|
|
344
|
-
if (current === undefined) {
|
|
345
|
-
return;
|
|
346
|
-
}
|
|
347
|
-
flags[index] = true;
|
|
342
|
+
state.rollback[index] = true;
|
|
348
343
|
}
|
|
349
344
|
function scopeRequestsRollback() {
|
|
350
345
|
const state = transactionScopes.getStore();
|
|
@@ -138,12 +138,7 @@ function requestTransactionRollback() {
|
|
|
138
138
|
if (!state || index < 0) {
|
|
139
139
|
return;
|
|
140
140
|
}
|
|
141
|
-
|
|
142
|
-
const current = flags[index];
|
|
143
|
-
if (current === undefined) {
|
|
144
|
-
return;
|
|
145
|
-
}
|
|
146
|
-
flags[index] = true;
|
|
141
|
+
state.rollback[index] = true;
|
|
147
142
|
}
|
|
148
143
|
function scopeRequestsRollback() {
|
|
149
144
|
const state = transactionScopes.getStore();
|
|
@@ -61,12 +61,7 @@ function requestTransactionRollback() {
|
|
|
61
61
|
if (!state || index < 0) {
|
|
62
62
|
return;
|
|
63
63
|
}
|
|
64
|
-
|
|
65
|
-
const current = flags[index];
|
|
66
|
-
if (current === undefined) {
|
|
67
|
-
return;
|
|
68
|
-
}
|
|
69
|
-
flags[index] = true;
|
|
64
|
+
state.rollback[index] = true;
|
|
70
65
|
}
|
|
71
66
|
function scopeRequestsRollback() {
|
|
72
67
|
const state = transactionScopes.getStore();
|
|
@@ -138,12 +138,7 @@ function requestTransactionRollback() {
|
|
|
138
138
|
if (!state || index < 0) {
|
|
139
139
|
return;
|
|
140
140
|
}
|
|
141
|
-
|
|
142
|
-
const current = flags[index];
|
|
143
|
-
if (current === undefined) {
|
|
144
|
-
return;
|
|
145
|
-
}
|
|
146
|
-
flags[index] = true;
|
|
141
|
+
state.rollback[index] = true;
|
|
147
142
|
}
|
|
148
143
|
function scopeRequestsRollback() {
|
|
149
144
|
const state = transactionScopes.getStore();
|
|
@@ -448,12 +448,7 @@ function requestTransactionRollback() {
|
|
|
448
448
|
if (!state || index < 0) {
|
|
449
449
|
return;
|
|
450
450
|
}
|
|
451
|
-
|
|
452
|
-
const current = flags[index];
|
|
453
|
-
if (current === undefined) {
|
|
454
|
-
return;
|
|
455
|
-
}
|
|
456
|
-
flags[index] = true;
|
|
451
|
+
state.rollback[index] = true;
|
|
457
452
|
}
|
|
458
453
|
function scopeRequestsRollback() {
|
|
459
454
|
const state = transactionScopes.getStore();
|
|
@@ -138,12 +138,7 @@ function requestTransactionRollback() {
|
|
|
138
138
|
if (!state || index < 0) {
|
|
139
139
|
return;
|
|
140
140
|
}
|
|
141
|
-
|
|
142
|
-
const current = flags[index];
|
|
143
|
-
if (current === undefined) {
|
|
144
|
-
return;
|
|
145
|
-
}
|
|
146
|
-
flags[index] = true;
|
|
141
|
+
state.rollback[index] = true;
|
|
147
142
|
}
|
|
148
143
|
function scopeRequestsRollback() {
|
|
149
144
|
const state = transactionScopes.getStore();
|
|
@@ -196,7 +196,7 @@ function postgresAppRolePrivilegeSql(options) {
|
|
|
196
196
|
const database = assertSafeSqlIdentifier(options.database, "database name");
|
|
197
197
|
const role = assertSafeSqlIdentifier(options.role ?? POSTGRES_APP_ROLE, "role name");
|
|
198
198
|
return `GRANT CONNECT ON DATABASE ${database} TO ${role};
|
|
199
|
-
GRANT USAGE
|
|
199
|
+
GRANT USAGE ON SCHEMA public TO ${role};
|
|
200
200
|
GRANT ALL PRIVILEGES ON ALL TABLES IN SCHEMA public TO ${role};
|
|
201
201
|
GRANT ALL PRIVILEGES ON ALL SEQUENCES IN SCHEMA public TO ${role};
|
|
202
202
|
GRANT EXECUTE ON ALL FUNCTIONS IN SCHEMA public TO ${role};
|
|
@@ -61,12 +61,7 @@ function requestTransactionRollback() {
|
|
|
61
61
|
if (!state || index < 0) {
|
|
62
62
|
return;
|
|
63
63
|
}
|
|
64
|
-
|
|
65
|
-
const current = flags[index];
|
|
66
|
-
if (current === undefined) {
|
|
67
|
-
return;
|
|
68
|
-
}
|
|
69
|
-
flags[index] = true;
|
|
64
|
+
state.rollback[index] = true;
|
|
70
65
|
}
|
|
71
66
|
function scopeRequestsRollback() {
|
|
72
67
|
const state = transactionScopes.getStore();
|
package/dist/index.js
CHANGED
|
@@ -243,12 +243,7 @@ function requestTransactionRollback() {
|
|
|
243
243
|
if (!state || index < 0) {
|
|
244
244
|
return;
|
|
245
245
|
}
|
|
246
|
-
|
|
247
|
-
const current = flags[index];
|
|
248
|
-
if (current === undefined) {
|
|
249
|
-
return;
|
|
250
|
-
}
|
|
251
|
-
flags[index] = true;
|
|
246
|
+
state.rollback[index] = true;
|
|
252
247
|
}
|
|
253
248
|
function scopeRequestsRollback() {
|
|
254
249
|
const state = transactionScopes.getStore();
|
|
@@ -8476,11 +8471,8 @@ async function eagerLoadOnModels(models, paths, knownAbsentMorphRoots = new Map)
|
|
|
8476
8471
|
}
|
|
8477
8472
|
await Promise.all([...grouped.entries()].map(async ([head, nested]) => {
|
|
8478
8473
|
const unloaded = models.filter((model) => model.loaded(head) === undefined && !knownAbsentMorphRoots.get(model)?.has(head));
|
|
8479
|
-
|
|
8480
|
-
|
|
8481
|
-
if (!first) {
|
|
8482
|
-
return;
|
|
8483
|
-
}
|
|
8474
|
+
const first = unloaded[0];
|
|
8475
|
+
if (first) {
|
|
8484
8476
|
const relationQuery = resolveModelRelation(first, head);
|
|
8485
8477
|
const query = first.getRepository().query();
|
|
8486
8478
|
relationQuery.applyEagerLoad(query, head);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@getstrata/core",
|
|
3
|
-
"version": "2.2.
|
|
3
|
+
"version": "2.2.56",
|
|
4
4
|
"description": "Strata Bun framework public API",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -982,7 +982,7 @@
|
|
|
982
982
|
}
|
|
983
983
|
},
|
|
984
984
|
"engines": {
|
|
985
|
-
"bun": ">=1.4.
|
|
985
|
+
"bun": ">=1.4.4"
|
|
986
986
|
},
|
|
987
987
|
"dependencies": {
|
|
988
988
|
"@opentelemetry/api": "1.9.1",
|