@payloadcms/storage-azure 3.78.0-internal.ab11ffa → 3.78.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.
@@ -1 +1 @@
1
- {"version":3,"file":"staticHandler.d.ts","sourceRoot":"","sources":["../src/staticHandler.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAA8B,eAAe,EAAE,MAAM,qBAAqB,CAAA;AACtF,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wCAAwC,CAAA;AAC3E,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAA;AAsC/C,UAAU,IAAI;IACZ,UAAU,EAAE,gBAAgB,CAAA;IAC5B,gBAAgB,EAAE,MAAM,eAAe,CAAA;CACxC;AAED,eAAO,MAAM,UAAU,qCAAsC,IAAI,KAAG,aA6GnE,CAAA"}
1
+ {"version":3,"file":"staticHandler.d.ts","sourceRoot":"","sources":["../src/staticHandler.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAA;AAC1D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wCAAwC,CAAA;AAC3E,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAA;AAO/C,UAAU,IAAI;IACZ,UAAU,EAAE,gBAAgB,CAAA;IAC5B,gBAAgB,EAAE,MAAM,eAAe,CAAA;CACxC;AAED,eAAO,MAAM,UAAU,qCAAsC,IAAI,KAAG,aAuGnE,CAAA"}
@@ -2,31 +2,8 @@ import { RestError } from '@azure/storage-blob';
2
2
  import { getFilePrefix } from '@payloadcms/plugin-cloud-storage/utilities';
3
3
  import path from 'path';
4
4
  import { getRangeRequestInfo } from 'payload/internal';
5
- const isNodeReadableStream = (body)=>{
6
- return typeof body === 'object' && body !== null && 'pipe' in body && typeof body.pipe === 'function' && 'destroy' in body && typeof body.destroy === 'function';
7
- };
8
- const abortRequestAndDestroyStream = ({ abortController, blob })=>{
9
- try {
10
- abortController.abort();
11
- } catch {
12
- /* noop */ }
13
- if (blob?.readableStreamBody && isNodeReadableStream(blob.readableStreamBody)) {
14
- blob.readableStreamBody.destroy();
15
- }
16
- };
17
5
  export const getHandler = ({ collection, getStorageClient })=>{
18
6
  return async (req, { headers: incomingHeaders, params: { clientUploadContext, filename } })=>{
19
- let blob = undefined;
20
- let streamed = false;
21
- const abortController = new AbortController();
22
- if (req.signal) {
23
- req.signal.addEventListener('abort', ()=>{
24
- abortRequestAndDestroyStream({
25
- abortController,
26
- blob
27
- });
28
- });
29
- }
30
7
  try {
31
8
  const prefix = await getFilePrefix({
32
9
  clientUploadContext,
@@ -56,11 +33,7 @@ export const getHandler = ({ collection, getStorageClient })=>{
56
33
  });
57
34
  }
58
35
  // Download with range if partial
59
- blob = rangeResult.type === 'partial' ? await blockBlobClient.download(rangeResult.rangeStart, rangeResult.rangeEnd - rangeResult.rangeStart + 1, {
60
- abortSignal: abortController.signal
61
- }) : await blockBlobClient.download(0, undefined, {
62
- abortSignal: abortController.signal
63
- });
36
+ const blob = rangeResult.type === 'partial' ? await blockBlobClient.download(rangeResult.rangeStart, rangeResult.rangeEnd - rangeResult.rangeStart + 1) : await blockBlobClient.download();
64
37
  let headers = new Headers(incomingHeaders);
65
38
  // Add range-related headers from the result
66
39
  for (const [key, value] of Object.entries(rangeResult.headers)){
@@ -87,24 +60,25 @@ export const getHandler = ({ collection, getStorageClient })=>{
87
60
  status: 304
88
61
  });
89
62
  }
90
- if (!blob.readableStreamBody || !isNodeReadableStream(blob.readableStreamBody)) {
91
- return new Response('Internal Server Error', {
92
- status: 500
93
- });
94
- }
95
- const stream = blob.readableStreamBody;
96
- stream.on('error', (err)=>{
97
- req.payload.logger.error({
98
- err,
99
- msg: 'Error while streaming Azure blob (aborting)'
100
- });
101
- abortRequestAndDestroyStream({
102
- abortController,
103
- blob
104
- });
63
+ // Manually create a ReadableStream for the web from a Node.js stream.
64
+ const readableStream = new ReadableStream({
65
+ start (controller) {
66
+ const nodeStream = blob.readableStreamBody;
67
+ if (!nodeStream) {
68
+ throw new Error('No readable stream body');
69
+ }
70
+ nodeStream.on('data', (chunk)=>{
71
+ controller.enqueue(new Uint8Array(chunk));
72
+ });
73
+ nodeStream.on('end', ()=>{
74
+ controller.close();
75
+ });
76
+ nodeStream.on('error', (err)=>{
77
+ controller.error(err);
78
+ });
79
+ }
105
80
  });
106
- streamed = true;
107
- return new Response(stream, {
81
+ return new Response(readableStream, {
108
82
  headers,
109
83
  status: rangeResult.status
110
84
  });
@@ -119,13 +93,6 @@ export const getHandler = ({ collection, getStorageClient })=>{
119
93
  return new Response('Internal Server Error', {
120
94
  status: 500
121
95
  });
122
- } finally{
123
- if (!streamed) {
124
- abortRequestAndDestroyStream({
125
- abortController,
126
- blob
127
- });
128
- }
129
96
  }
130
97
  };
131
98
  };
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/staticHandler.ts"],"sourcesContent":["import type { BlobDownloadResponseParsed, ContainerClient } from '@azure/storage-blob'\nimport type { StaticHandler } from '@payloadcms/plugin-cloud-storage/types'\nimport type { CollectionConfig } from 'payload'\nimport type { Readable } from 'stream'\n\nimport { RestError } from '@azure/storage-blob'\nimport { getFilePrefix } from '@payloadcms/plugin-cloud-storage/utilities'\nimport path from 'path'\nimport { getRangeRequestInfo } from 'payload/internal'\n\nconst isNodeReadableStream = (\n body: BlobDownloadResponseParsed['readableStreamBody'],\n): body is Readable => {\n return (\n typeof body === 'object' &&\n body !== null &&\n 'pipe' in body &&\n typeof body.pipe === 'function' &&\n 'destroy' in body &&\n typeof body.destroy === 'function'\n )\n}\n\nconst abortRequestAndDestroyStream = ({\n abortController,\n blob,\n}: {\n abortController: AbortController\n blob?: BlobDownloadResponseParsed\n}) => {\n try {\n abortController.abort()\n } catch {\n /* noop */\n }\n if (blob?.readableStreamBody && isNodeReadableStream(blob.readableStreamBody)) {\n blob.readableStreamBody.destroy()\n }\n}\n\ninterface Args {\n collection: CollectionConfig\n getStorageClient: () => ContainerClient\n}\n\nexport const getHandler = ({ collection, getStorageClient }: Args): StaticHandler => {\n return async (req, { headers: incomingHeaders, params: { clientUploadContext, filename } }) => {\n let blob: BlobDownloadResponseParsed | undefined = undefined\n let streamed = false\n\n const abortController = new AbortController()\n if (req.signal) {\n req.signal.addEventListener('abort', () => {\n abortRequestAndDestroyStream({ abortController, blob })\n })\n }\n\n try {\n const prefix = await getFilePrefix({ clientUploadContext, collection, filename, req })\n const blockBlobClient = getStorageClient().getBlockBlobClient(\n path.posix.join(prefix, filename),\n )\n\n // Get file size for range validation\n const properties = await blockBlobClient.getProperties()\n const fileSize = properties.contentLength\n\n if (!fileSize) {\n return new Response('Internal Server Error', { status: 500 })\n }\n\n // Handle range request\n const rangeHeader = req.headers.get('range')\n const rangeResult = getRangeRequestInfo({ fileSize, rangeHeader })\n\n if (rangeResult.type === 'invalid') {\n return new Response(null, {\n headers: new Headers(rangeResult.headers),\n status: rangeResult.status,\n })\n }\n\n // Download with range if partial\n blob =\n rangeResult.type === 'partial'\n ? await blockBlobClient.download(\n rangeResult.rangeStart,\n rangeResult.rangeEnd - rangeResult.rangeStart + 1,\n { abortSignal: abortController.signal },\n )\n : await blockBlobClient.download(0, undefined, { abortSignal: abortController.signal })\n\n let headers = new Headers(incomingHeaders)\n\n // Add range-related headers from the result\n for (const [key, value] of Object.entries(rangeResult.headers)) {\n headers.append(key, value)\n }\n\n // Add Azure-specific headers\n headers.append('Content-Type', String(properties.contentType))\n if (properties.etag) {\n headers.append('ETag', String(properties.etag))\n }\n\n // Add Content-Security-Policy header for SVG files to prevent executable code\n if (properties.contentType === 'image/svg+xml') {\n headers.append('Content-Security-Policy', \"script-src 'none'\")\n }\n\n const etagFromHeaders = req.headers.get('etag') || req.headers.get('if-none-match')\n\n if (\n collection.upload &&\n typeof collection.upload === 'object' &&\n typeof collection.upload.modifyResponseHeaders === 'function'\n ) {\n headers = collection.upload.modifyResponseHeaders({ headers }) || headers\n }\n\n if (etagFromHeaders && etagFromHeaders === properties.etag) {\n return new Response(null, {\n headers,\n status: 304,\n })\n }\n\n if (!blob.readableStreamBody || !isNodeReadableStream(blob.readableStreamBody)) {\n return new Response('Internal Server Error', { status: 500 })\n }\n\n const stream = blob.readableStreamBody\n stream.on('error', (err: Error) => {\n req.payload.logger.error({\n err,\n msg: 'Error while streaming Azure blob (aborting)',\n })\n abortRequestAndDestroyStream({ abortController, blob })\n })\n\n streamed = true\n return new Response(stream, { headers, status: rangeResult.status })\n } catch (err: unknown) {\n if (err instanceof RestError && err.statusCode === 404) {\n return new Response(null, { status: 404, statusText: 'Not Found' })\n }\n req.payload.logger.error(err)\n return new Response('Internal Server Error', { status: 500 })\n } finally {\n if (!streamed) {\n abortRequestAndDestroyStream({ abortController, blob })\n }\n }\n }\n}\n"],"names":["RestError","getFilePrefix","path","getRangeRequestInfo","isNodeReadableStream","body","pipe","destroy","abortRequestAndDestroyStream","abortController","blob","abort","readableStreamBody","getHandler","collection","getStorageClient","req","headers","incomingHeaders","params","clientUploadContext","filename","undefined","streamed","AbortController","signal","addEventListener","prefix","blockBlobClient","getBlockBlobClient","posix","join","properties","getProperties","fileSize","contentLength","Response","status","rangeHeader","get","rangeResult","type","Headers","download","rangeStart","rangeEnd","abortSignal","key","value","Object","entries","append","String","contentType","etag","etagFromHeaders","upload","modifyResponseHeaders","stream","on","err","payload","logger","error","msg","statusCode","statusText"],"mappings":"AAKA,SAASA,SAAS,QAAQ,sBAAqB;AAC/C,SAASC,aAAa,QAAQ,6CAA4C;AAC1E,OAAOC,UAAU,OAAM;AACvB,SAASC,mBAAmB,QAAQ,mBAAkB;AAEtD,MAAMC,uBAAuB,CAC3BC;IAEA,OACE,OAAOA,SAAS,YAChBA,SAAS,QACT,UAAUA,QACV,OAAOA,KAAKC,IAAI,KAAK,cACrB,aAAaD,QACb,OAAOA,KAAKE,OAAO,KAAK;AAE5B;AAEA,MAAMC,+BAA+B,CAAC,EACpCC,eAAe,EACfC,IAAI,EAIL;IACC,IAAI;QACF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AyB;oBAAEC,QAAQ;gBAAI;YAC7D;YAEA,MAAMqB,SAAShD,KAAKE,kBAAkB;YACtC8C,OAAOC,EAAE,CAAC,SAAS,CAACC;gBAClB5C,IAAI6C,OAAO,CAACC,MAAM,CAACC,KAAK,CAAC;oBACvBH;oBACAI,KAAK;gBACP;gBACAxD,6BAA6B;oBAAEC;oBAAiBC;gBAAK;YACvD;YAEAa,WAAW;YACX,OAAO,IAAIa,SAASsB,QAAQ;gBAAEzC;gBAASoB,QAAQG,YAAYH,MAAM;YAAC;QACpE,EAAE,OAAOuB,KAAc;YACrB,IAAIA,eAAe5D,aAAa4D,IAAIK,UAAU,KAAK,KAAK;gBACtD,OAAO,IAAI7B,SAAS,MAAM;oBAAEC,QAAQ;oBAAK6B,YAAY;gBAAY;YACnE;YACAlD,IAAI6C,OAAO,CAACC,MAAM,CAACC,KAAK,CAACH;YACzB,OAAO,IAAIxB,SAAS,yBAAyB;gBAAEC,QAAQ;YAAI;QAC7D,SAAU;YACR,IAAI,CAACd,UAAU;gBACbf,6BAA6B;oBAAEC;oBAAiBC;gBAAK;YACvD;QACF;IACF;AACF,EAAC"}
1
+ {"version":3,"sources":["../src/staticHandler.ts"],"sourcesContent":["import type { ContainerClient } from '@azure/storage-blob'\nimport type { StaticHandler } from '@payloadcms/plugin-cloud-storage/types'\nimport type { CollectionConfig } from 'payload'\n\nimport { RestError } from '@azure/storage-blob'\nimport { getFilePrefix } from '@payloadcms/plugin-cloud-storage/utilities'\nimport path from 'path'\nimport { getRangeRequestInfo } from 'payload/internal'\n\ninterface Args {\n collection: CollectionConfig\n getStorageClient: () => ContainerClient\n}\n\nexport const getHandler = ({ collection, getStorageClient }: Args): StaticHandler => {\n return async (req, { headers: incomingHeaders, params: { clientUploadContext, filename } }) => {\n try {\n const prefix = await getFilePrefix({ clientUploadContext, collection, filename, req })\n const blockBlobClient = getStorageClient().getBlockBlobClient(\n path.posix.join(prefix, filename),\n )\n\n // Get file size for range validation\n const properties = await blockBlobClient.getProperties()\n const fileSize = properties.contentLength\n\n if (!fileSize) {\n return new Response('Internal Server Error', { status: 500 })\n }\n\n // Handle range request\n const rangeHeader = req.headers.get('range')\n const rangeResult = getRangeRequestInfo({ fileSize, rangeHeader })\n\n if (rangeResult.type === 'invalid') {\n return new Response(null, {\n headers: new Headers(rangeResult.headers),\n status: rangeResult.status,\n })\n }\n\n // Download with range if partial\n const blob =\n rangeResult.type === 'partial'\n ? await blockBlobClient.download(\n rangeResult.rangeStart,\n rangeResult.rangeEnd - rangeResult.rangeStart + 1,\n )\n : await blockBlobClient.download()\n\n let headers = new Headers(incomingHeaders)\n\n // Add range-related headers from the result\n for (const [key, value] of Object.entries(rangeResult.headers)) {\n headers.append(key, value)\n }\n\n // Add Azure-specific headers\n headers.append('Content-Type', String(properties.contentType))\n if (properties.etag) {\n headers.append('ETag', String(properties.etag))\n }\n\n // Add Content-Security-Policy header for SVG files to prevent executable code\n if (properties.contentType === 'image/svg+xml') {\n headers.append('Content-Security-Policy', \"script-src 'none'\")\n }\n\n const etagFromHeaders = req.headers.get('etag') || req.headers.get('if-none-match')\n\n if (\n collection.upload &&\n typeof collection.upload === 'object' &&\n typeof collection.upload.modifyResponseHeaders === 'function'\n ) {\n headers = collection.upload.modifyResponseHeaders({ headers }) || headers\n }\n\n if (etagFromHeaders && etagFromHeaders === properties.etag) {\n return new Response(null, {\n headers,\n status: 304,\n })\n }\n\n // Manually create a ReadableStream for the web from a Node.js stream.\n const readableStream = new ReadableStream({\n start(controller) {\n const nodeStream = blob.readableStreamBody\n if (!nodeStream) {\n throw new Error('No readable stream body')\n }\n\n nodeStream.on('data', (chunk) => {\n controller.enqueue(new Uint8Array(chunk))\n })\n nodeStream.on('end', () => {\n controller.close()\n })\n nodeStream.on('error', (err) => {\n controller.error(err)\n })\n },\n })\n\n return new Response(readableStream, {\n headers,\n status: rangeResult.status,\n })\n } catch (err: unknown) {\n if (err instanceof RestError && err.statusCode === 404) {\n return new Response(null, { status: 404, statusText: 'Not Found' })\n }\n req.payload.logger.error(err)\n return new Response('Internal Server Error', { status: 500 })\n }\n }\n}\n"],"names":["RestError","getFilePrefix","path","getRangeRequestInfo","getHandler","collection","getStorageClient","req","headers","incomingHeaders","params","clientUploadContext","filename","prefix","blockBlobClient","getBlockBlobClient","posix","join","properties","getProperties","fileSize","contentLength","Response","status","rangeHeader","get","rangeResult","type","Headers","blob","download","rangeStart","rangeEnd","key","value","Object","entries","append","String","contentType","etag","etagFromHeaders","upload","modifyResponseHeaders","readableStream","ReadableStream","start","controller","nodeStream","readableStreamBody","Error","on","chunk","enqueue","Uint8Array","close","err","error","statusCode","statusText","payload","logger"],"mappings":"AAIA,SAASA,SAAS,QAAQ,sBAAqB;AAC/C,SAASC,aAAa,QAAQ,6CAA4C;AAC1E,OAAOC,UAAU,OAAM;AACvB,SAASC,mBAAmB,QAAQ,mBAAkB;AAOtD,OAAO,MAAMC,aAAa,CAAC,EAAEC,UAAU,EAAEC,gBAAgB,EAAQ;IAC/D,OAAO,OAAOC,KAAK,EAAEC,SAASC,eAAe,EAAEC,QAAQ,EAAEC,mBAAmB,EAAEC,QAAQ,EAAE,EAAE;QACxF,IAAI;YACF,MAAMC,SAAS,MAAMZ,cAAc;gBAAEU;gBAAqBN;gBAAYO;gBAAUL;YAAI;YACpF,MAAMO,kBAAkBR,mBAAmBS,kBAAkB,CAC3Db,KAAKc,KAAK,CAACC,IAAI,CAACJ,QAAQD;YAG1B,qCAAqC;YACrC,MAAMM,aAAa,MAAMJ,gBAAgBK,aAAa;YACtD,MAAMC,WAAWF,WAAWG,aAAa;YAEzC,IAAI,CAACD,UAAU;gBACb,OAAO,IAAIE,SAAS,yBAAyB;oBAAEC,QAAQ;gBAAI;YAC7D;YAEA,uBAAuB;YACvB,MAAMC,cAAcjB,IAAIC,OAAO,CAACiB,GAAG,CAAC;YACpC,MAAMC,cAAcvB,oBAAoB;gBAAEiB;gBAAUI;YAAY;YAEhE,IAAIE,YAAYC,IAAI,KAAK,WAAW;gBAClC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iB,IAAIC,eAAe;gBACxCC,OAAMC,UAAU;oBACd,MAAMC,aAAanB,KAAKoB,kBAAkB;oBAC1C,IAAI,CAACD,YAAY;wBACf,MAAM,IAAIE,MAAM;oBAClB;oBAEAF,WAAWG,EAAE,CAAC,QAAQ,CAACC;wBACrBL,WAAWM,OAAO,CAAC,IAAIC,WAAWF;oBACpC;oBACAJ,WAAWG,EAAE,CAAC,OAAO;wBACnBJ,WAAWQ,KAAK;oBAClB;oBACAP,WAAWG,EAAE,CAAC,SAAS,CAACK;wBACtBT,WAAWU,KAAK,CAACD;oBACnB;gBACF;YACF;YAEA,OAAO,IAAIlC,SAASsB,gBAAgB;gBAClCpC;gBACAe,QAAQG,YAAYH,MAAM;YAC5B;QACF,EAAE,OAAOiC,KAAc;YACrB,IAAIA,eAAexD,aAAawD,IAAIE,UAAU,KAAK,KAAK;gBACtD,OAAO,IAAIpC,SAAS,MAAM;oBAAEC,QAAQ;oBAAKoC,YAAY;gBAAY;YACnE;YACApD,IAAIqD,OAAO,CAACC,MAAM,CAACJ,KAAK,CAACD;YACzB,OAAO,IAAIlC,SAAS,yBAAyB;gBAAEC,QAAQ;YAAI;QAC7D;IACF;AACF,EAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@payloadcms/storage-azure",
3
- "version": "3.78.0-internal.ab11ffa",
3
+ "version": "3.78.0",
4
4
  "description": "Payload storage adapter for Azure Blob Storage",
5
5
  "homepage": "https://payloadcms.com",
6
6
  "repository": {
@@ -39,13 +39,13 @@
39
39
  "dependencies": {
40
40
  "@azure/abort-controller": "^1.1.0",
41
41
  "@azure/storage-blob": "^12.11.0",
42
- "@payloadcms/plugin-cloud-storage": "3.78.0-internal.ab11ffa"
42
+ "@payloadcms/plugin-cloud-storage": "3.78.0"
43
43
  },
44
44
  "devDependencies": {
45
- "payload": "3.78.0-internal.ab11ffa"
45
+ "payload": "3.78.0"
46
46
  },
47
47
  "peerDependencies": {
48
- "payload": "3.78.0-internal.ab11ffa"
48
+ "payload": "3.78.0"
49
49
  },
50
50
  "engines": {
51
51
  "node": "^18.20.2 || >=20.9.0"