Skip to content

Commit a7eb2e0

Browse files
committed
Merge branch 'main' into postdeploy
2 parents 5cb8159 + 452fcd0 commit a7eb2e0

File tree

10 files changed

+62
-18
lines changed

10 files changed

+62
-18
lines changed

CHANGELOG.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,24 @@
1+
## [1.0.5](https://github.com/adobe/da-admin/compare/v1.0.4...v1.0.5) (2025-12-18)
2+
3+
4+
### Bug Fixes
5+
6+
* fix prod worker name ([#227](https://github.com/adobe/da-admin/issues/227)) ([73b05c7](https://github.com/adobe/da-admin/commit/73b05c72aace78c99b8a3f54ea517172fa3120f0))
7+
8+
## [1.0.4](https://github.com/adobe/da-admin/compare/v1.0.3...v1.0.4) (2025-12-18)
9+
10+
11+
### Bug Fixes
12+
13+
* GH-221 - Disable anonymous access ([#225](https://github.com/adobe/da-admin/issues/225)) ([df98f3e](https://github.com/adobe/da-admin/commit/df98f3eca7b51ae05db7106a01b7f77f25f3c6c8)), closes [#221](https://github.com/adobe/da-admin/issues/221) [#221](https://github.com/adobe/da-admin/issues/221) [#221](https://github.com/adobe/da-admin/issues/221)
14+
15+
## [1.0.3](https://github.com/adobe/da-admin/compare/v1.0.2...v1.0.3) (2025-12-17)
16+
17+
18+
### Bug Fixes
19+
20+
* stalled response ([#226](https://github.com/adobe/da-admin/issues/226)) ([d32fa3e](https://github.com/adobe/da-admin/commit/d32fa3eb470c8fbdbca61e9b9ba7961956ab9bbf))
21+
122
## [1.0.2](https://github.com/adobe/da-admin/compare/v1.0.1...v1.0.2) (2025-12-15)
223

324

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "da-admin",
3-
"version": "1.0.2",
3+
"version": "1.0.5",
44
"description": "",
55
"main": "index.js",
66
"type": "module",

src/storage/utils/object.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,10 @@ export async function notifyCollab(api, url, env) {
3030
if (env.COLLAB_SHARED_SECRET) {
3131
headers.authorization = `token ${env.COLLAB_SHARED_SECRET}`;
3232
}
33-
await env.dacollab.fetch(invURL, {
33+
const resp = await env.dacollab.fetch(invURL, {
3434
// TODO: use POST for state changing operations
3535
// method: 'POST',
3636
headers,
3737
});
38+
resp.body.cancel();
3839
}

test/integration/conditional-e2e.test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ describe('Conditional Headers End-to-End', () => {
110110
const env = {
111111
AEM_BUCKET_NAME: 'test-bucket',
112112
dacollab: {
113-
fetch: async () => ({ status: 200 }),
113+
fetch: async () => ({ status: 200, body: { cancel: () => {} } }),
114114
},
115115
};
116116
const resp = await handler.default.fetch(req, env);

test/routes/source.test.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,10 @@ describe('Source Route', () => {
1919
it('Test invalidate using service binding', async () => {
2020
const sb_callbacks = [];
2121
const dacollab = {
22-
fetch: async (url) => sb_callbacks.push(url),
22+
fetch: async (url) => {
23+
sb_callbacks.push(url);
24+
return { body: { cancel: () => {} } };
25+
},
2326
};
2427
const env = {
2528
dacollab,

test/storage/object/copy.test.js

Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -343,7 +343,10 @@ describe('Object copy', () => {
343343
const collabCalled = [];
344344
const env = {
345345
dacollab: {
346-
fetch: (x) => { collabCalled.push(x); },
346+
fetch: (x) => {
347+
collabCalled.push(x);
348+
return { body: { cancel: () => {} } };
349+
},
347350
},
348351
};
349352
const daCtx = {
@@ -569,7 +572,10 @@ describe('Object copy', () => {
569572
const collabCalled = [];
570573
const env = {
571574
dacollab: {
572-
fetch: (x) => { collabCalled.push(x); },
575+
fetch: (x) => {
576+
collabCalled.push(x);
577+
return { body: { cancel: () => {} } };
578+
},
573579
},
574580
};
575581
const daCtx = { bucket: 'mybucket', org: 'xorg' };
@@ -631,7 +637,10 @@ describe('Object copy', () => {
631637
const collabCalled = [];
632638
const env = {
633639
dacollab: {
634-
fetch: (x) => { collabCalled.push(x); },
640+
fetch: (x) => {
641+
collabCalled.push(x);
642+
return { body: { cancel: () => {} } };
643+
},
635644
},
636645
};
637646
const daCtx = { bucket: 'test-bucket', org: 'qqqorg', origin: 'http://qqq' };
@@ -680,7 +689,7 @@ describe('Object copy', () => {
680689
return null;
681690
};
682691

683-
const env = { dacollab: { fetch: () => {} } };
692+
const env = { dacollab: { fetch: () => ({ body: { cancel: () => {} } }) } };
684693
const ctx = {
685694
bucket: 'root-bucket',
686695
org: 'foo',
@@ -713,7 +722,7 @@ describe('Object copy', () => {
713722
DA_JOBS[key] = value;
714723
},
715724
},
716-
dacollab: { fetch: () => {} },
725+
dacollab: { fetch: () => ({ body: { cancel: () => {} } }) },
717726
};
718727
s3Mock.on(ListObjectsV2Command)
719728
.resolves({
@@ -797,7 +806,7 @@ describe('Object copy', () => {
797806
return DA_JOBS[key];
798807
},
799808
},
800-
dacollab: { fetch: () => {} },
809+
dacollab: { fetch: () => ({ body: { cancel: () => {} } }) },
801810
};
802811

803812
// Mock getObject to return content type for HEAD requests
@@ -858,7 +867,7 @@ describe('Object copy', () => {
858867
delete DA_JOBS[key];
859868
},
860869
},
861-
dacollab: { fetch: () => {} },
870+
dacollab: { fetch: () => ({ body: { cancel: () => {} } }) },
862871
};
863872

864873
// Mock getObject to return content type for HEAD requests

test/storage/object/delete.test.js

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,12 @@ describe('Object delete', () => {
2525
describe('single context', () => {
2626
it('Delete a file', async () => {
2727
const collabCalled = [];
28-
const dacollab = { fetch: (u) => collabCalled.push(u) };
28+
const dacollab = {
29+
fetch: (u) => {
30+
collabCalled.push(u);
31+
return { body: { cancel: () => {} } };
32+
},
33+
};
2934

3035
const client = {};
3136
const env = { dacollab };
@@ -227,8 +232,7 @@ describe('Object delete', () => {
227232
};
228233
const env = {
229234
dacollab: {
230-
fetch: () => {
231-
},
235+
fetch: () => ({ body: { cancel: () => {} } }),
232236
},
233237
};
234238
const mockPostObjectVersion = async () => ({ status: 201 });
@@ -257,8 +261,7 @@ describe('Object delete', () => {
257261
};
258262
const env = {
259263
dacollab: {
260-
fetch: () => {
261-
},
264+
fetch: () => ({ body: { cancel: () => {} } }),
262265
},
263266
};
264267
const mockPostObjectVersion = async () => ({ status: 201 });

test/storage/utils/object.test.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ describe('Storage Object Utils tests', () => {
2121
fetch: async (url) => {
2222
console.log(`invalidate called with ${url}`);
2323
called.push(url);
24+
return { body: { cancel: () => {} } };
2425
},
2526
};
2627
const env = { dacollab };
@@ -53,6 +54,7 @@ describe('Storage Object Utils tests', () => {
5354
console.log(`invalidate called with ${url}`);
5455
assert.strictEqual(opts.headers.authorization, 'token example-secret');
5556
called.push(url);
57+
return { body: { cancel: () => {} } };
5658
},
5759
},
5860
COLLAB_SHARED_SECRET: 'example-secret',

wrangler.toml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ keep_vars = true
66
# ----------------------------------------------------------------------
77
# production environment
88
[env.production]
9+
name = "da-admin"
910
services = [
1011
{ binding = "dacollab", service = "da-collab" }
1112
]
@@ -29,6 +30,7 @@ AEM_BUCKET_NAME = "aem-content"
2930
# ----------------------------------------------------------------------
3031
# stage environment
3132
[env.stage]
33+
name = "da-admin-stage"
3234
services = [
3335
{ binding = "dacollab", service = "da-collab-stage" }
3436
]
@@ -52,6 +54,7 @@ AEM_BUCKET_NAME = "aem-content-stage"
5254
# ----------------------------------------------------------------------
5355
# ci environment (using stage content)
5456
[env.ci]
57+
name = "da-admin-ci"
5558
services = [
5659
{ binding = "dacollab", service = "da-collab-stage" }
5760
]
@@ -76,6 +79,7 @@ AEM_BUCKET_NAME = "aem-content-stage"
7679
# ----------------------------------------------------------------------
7780
# dev environment (local)
7881
[env.dev]
82+
name = "da-admin-dev"
7983
services = [
8084
{ binding = "dacollab", service = "da-collab-local" }
8185
]
@@ -99,6 +103,7 @@ AEM_BUCKET_NAME = "aem-content-dev"
99103
# ----------------------------------------------------------------------
100104
# integration test environment (local)
101105
[env.it]
106+
name = "da-admin-it"
102107
services = [
103108
{ binding = "dacollab", service = "da-collab-local" }
104109
]

0 commit comments

Comments
 (0)