From 49acdb872c356fe6c7434b1c9cd8001aa57becc4 Mon Sep 17 00:00:00 2001 From: hyrious Date: Tue, 7 Feb 2023 14:06:28 +0800 Subject: [PATCH] fix(convert): store failed step in convert start (#716) * Revert "chore(deps): bump fastify from 4.1.0 to 4.8.1 (#689)" This reverts commit 6c4b648112eb9af964ca977fc481dea46dee4d8e. * upgrade fast-jwt * fix(convert): store failed step in convert start * refactor: support opt-out transaction in dao --- package.json | 6 +- src/v2/dao/index.ts | 6 +- .../cloud-storage/__tests__/convert.test.ts | 35 +++ src/v2/services/cloud-storage/convert.ts | 36 +++ src/v2/services/whiteboard/conversion.ts | 2 +- src/v2/services/whiteboard/projector.ts | 2 +- yarn.lock | 255 ++++++++---------- 7 files changed, 194 insertions(+), 148 deletions(-) diff --git a/package.json b/package.json index a558f8f0..e143d730 100644 --- a/package.json +++ b/package.json @@ -65,7 +65,7 @@ "@fastify/cookie": "^8.3.0", "@fastify/cors": "^8.0.0", "@fastify/formbody": "^7.0.1", - "@fastify/jwt": "^6.1.0", + "@fastify/jwt": "^6.5.0", "@fastify/type-provider-typebox": "^1.0.0", "@fastify/view": "^7.1.0", "@sinclair/typebox": "^0.23.5", @@ -78,8 +78,8 @@ "crypto-random-string": "^3.3.0", "date-fns": "^2.16.1", "eta": "^1.12.3", - "fast-jwt": "^1.6.0", - "fastify": "^4.8.1", + "fast-jwt": "^2.1.0", + "fastify": "^4.1.0", "fastify-plugin": "^3.0.1", "filenamify": "^4.3.0", "fs-extra": "^10.0.0", diff --git a/src/v2/dao/index.ts b/src/v2/dao/index.ts index fb766839..28cf7e61 100644 --- a/src/v2/dao/index.ts +++ b/src/v2/dao/index.ts @@ -22,6 +22,7 @@ import { CloudStorageConfigsModel } from "../../model/cloudStorage/CloudStorageC import { OAuthInfosModel } from "../../model/oauth/oauth-infos"; import { OAuthSecretsModel } from "../../model/oauth/oauth-secrets"; import { OAuthUsersModel } from "../../model/oauth/oauth-users"; +import { dataSource } from "../../thirdPartyService/TypeORMService"; class DAO { public constructor(private readonly model: EntityTarget) {} @@ -117,7 +118,7 @@ class DAO { } public async update( - t: EntityManager, + t: EntityManager | null, updateData: QueryDeepPartialEntity, where: FindOptionsWhere, config?: { @@ -125,8 +126,7 @@ class DAO { limit?: number; }, ): Promise { - let sql = t - .createQueryBuilder() + let sql = (t ? t.createQueryBuilder() : dataSource.createQueryBuilder()) .update(this.model) .set(updateData) .where(DAOUtils.softDelete(where)) diff --git a/src/v2/services/cloud-storage/__tests__/convert.test.ts b/src/v2/services/cloud-storage/__tests__/convert.test.ts index 401e61ac..94ce064c 100644 --- a/src/v2/services/cloud-storage/__tests__/convert.test.ts +++ b/src/v2/services/cloud-storage/__tests__/convert.test.ts @@ -301,6 +301,41 @@ test(`${namespace} - start whiteboard projector - convertStep not none`, async a await releaseRunner(); }); +test.serial(`${namespace} - start whiteboard projector - failed`, async ava => { + const stubAxios = sinon.stub(ax, "post").resolves({ + data: { + uuid: undefined, + }, + }); + + const { t, releaseRunner } = await useTransaction(); + + const fileUUID = v4(); + + const cloudStorageConvertSVC = new CloudStorageConvertService(ids(), t, fileUUID); + + await ava.throwsAsync( + () => + cloudStorageConvertSVC.startWhiteboardProjector(v4(), v4(), { + region: Region.SG, + convertStep: FileConvertStep.Converting, + }), + { + instanceOf: FError, + message: `${Status.Failed}: ${ErrorCode.FileConvertFailed}`, + }, + ); + + const data = await cloudStorageFilesDAO.findOne(t, 'payload', { + file_uuid: fileUUID, + }); + + ava.is((data.payload as any)?.convertStep, FileConvertStep.Failed); + + stubAxios.restore(); + await releaseRunner(); +}); + test.serial(`${namespace} - start whiteboard projector - success`, async ava => { const { t, releaseRunner } = await useTransaction(); const { createCloudStorageFiles } = testService(t); diff --git a/src/v2/services/cloud-storage/convert.ts b/src/v2/services/cloud-storage/convert.ts index 72103e58..0477e227 100644 --- a/src/v2/services/cloud-storage/convert.ts +++ b/src/v2/services/cloud-storage/convert.ts @@ -110,6 +110,24 @@ export class CloudStorageConvertService { const whiteboardConversionSVC = new WhiteboardConversionService(this.ids); const taskUUID = await whiteboardConversionSVC.create(fileURL); + if (!taskUUID) { + await cloudStorageFilesDAO.update( + // we don't want to rollback this action + null, + { + payload: { + convertStep: FileConvertStep.Failed, + region: payload.region, + }, + }, + { + file_uuid: fileUUID, + } + ) + + throw new FError(ErrorCode.FileConvertFailed); + } + const taskToken = WhiteboardTokenService.createTask(taskUUID); await cloudStorageFilesDAO.update( @@ -193,6 +211,24 @@ export class CloudStorageConvertService { const whiteboardProjectorSVC = new WhiteboardProjectorService(this.ids); const taskUUID = await whiteboardProjectorSVC.create(fileURL); + if (!taskUUID) { + await cloudStorageFilesDAO.update( + // we don't want to rollback this action + null, + { + payload: { + convertStep: FileConvertStep.Failed, + region: payload.region, + }, + }, + { + file_uuid: fileUUID, + } + ) + + throw new FError(ErrorCode.FileConvertFailed); + } + const taskToken = WhiteboardTokenService.createTask(taskUUID); await cloudStorageFilesDAO.update( diff --git a/src/v2/services/whiteboard/conversion.ts b/src/v2/services/whiteboard/conversion.ts index abe0c6dd..3b2e972f 100644 --- a/src/v2/services/whiteboard/conversion.ts +++ b/src/v2/services/whiteboard/conversion.ts @@ -12,7 +12,7 @@ export class WhiteboardConversionService { public constructor(private readonly ids: IDS) {} - public async create(resource: string): Promise { + public async create(resource: string): Promise { const result = await ax.post( "https://api.netless.link/v5/services/conversion/tasks", { diff --git a/src/v2/services/whiteboard/projector.ts b/src/v2/services/whiteboard/projector.ts index a9282278..eb07599d 100644 --- a/src/v2/services/whiteboard/projector.ts +++ b/src/v2/services/whiteboard/projector.ts @@ -11,7 +11,7 @@ export class WhiteboardProjectorService { public constructor(private readonly ids: IDS) {} - public async create(resource: string): Promise { + public async create(resource: string): Promise { const { data } = await ax.post( "https://api.netless.link/v5/projector/tasks", { diff --git a/yarn.lock b/yarn.lock index aa9845ed..a44881a6 100644 --- a/yarn.lock +++ b/yarn.lock @@ -323,14 +323,14 @@ dependencies: fastify-plugin "^3.0.1" -"@fastify/ajv-compiler@^3.3.1": - version "3.3.1" - resolved "https://registry.yarnpkg.com/@fastify/ajv-compiler/-/ajv-compiler-3.3.1.tgz#7045dbf23c11c42b50011ccc36998cd624856e5d" - integrity sha512-IRnids8lblQ8e1i8h4JLyfJmebXE+ohcj8x8X/+Ew6ZB4H0Ui05z5YL6q5FOcl0zItVpu4adRzeyVNNUwmduIg== +"@fastify/ajv-compiler@^3.1.0": + version "3.1.0" + resolved "https://registry.yarnpkg.com/@fastify/ajv-compiler/-/ajv-compiler-3.1.0.tgz#7ccae63da5a115f583ae6cc68173dbc3c1f34405" + integrity sha512-+hRMMxcUmdqtnCGPwrI2yczFdlgp3IBR88WlPLimXlgRb8vHBTXz38I17R/9ui+hIt9jx0uOdZKOis77VooHfA== dependencies: - ajv "^8.11.0" + ajv "^8.10.0" ajv-formats "^2.1.1" - fast-uri "^2.0.0" + fast-uri "^1.0.1" "@fastify/cookie@^8.3.0": version "8.3.0" @@ -348,22 +348,17 @@ fastify-plugin "^3.0.0" vary "^1.1.2" -"@fastify/deepmerge@^1.0.0": - version "1.1.0" - resolved "https://registry.yarnpkg.com/@fastify/deepmerge/-/deepmerge-1.1.0.tgz#91f0a5a27034ff76b7bece63a5906894940ace82" - integrity sha512-E8Hfdvs1bG6u0N4vN5Nty6JONUfTdOciyD5rn8KnEsLKIenvOVcr210BQR9t34PRkNyjqnMLGk3e0BsaxRdL+g== - "@fastify/error@^3.0.0": version "3.0.0" resolved "https://registry.yarnpkg.com/@fastify/error/-/error-3.0.0.tgz#bfcb7b33cec0196413083a91ef2edc7b2c88455b" integrity sha512-dPRyT40GiHRzSCll3/Jn2nPe25+E1VXc9tDwRAIKwFCxd5Np5wzgz1tmooWG3sV0qKgrBibihVoCna2ru4SEFg== -"@fastify/fast-json-stringify-compiler@^4.1.0": - version "4.1.0" - resolved "https://registry.yarnpkg.com/@fastify/fast-json-stringify-compiler/-/fast-json-stringify-compiler-4.1.0.tgz#ebf657ce4ec88e27ba311f7560eaa0b37de8719d" - integrity sha512-cTKBV2J9+u6VaKDhX7HepSfPSzw+F+TSd+k0wzifj4rG+4E5PjSFJCk19P8R6tr/72cuzgGd+mbB3jFT6lvAgw== +"@fastify/fast-json-stringify-compiler@^3.0.1": + version "3.0.1" + resolved "https://registry.yarnpkg.com/@fastify/fast-json-stringify-compiler/-/fast-json-stringify-compiler-3.0.1.tgz#78dfd3989f1e991a2fed1b0abfe1ffb29fcc3fe8" + integrity sha512-X9BL9/N7827M9UTBVsa5G3xOoD3MQ6EqX+D6EyJyF8LdvWTHQJ//BDN4FAEaGZUA2sL+GEMC6+KNjHESnPwQuw== dependencies: - fast-json-stringify "^5.0.0" + fast-json-stringify "^4.2.0" "@fastify/formbody@^7.0.1": version "7.0.1" @@ -372,15 +367,15 @@ dependencies: fastify-plugin "^3.0.0" -"@fastify/jwt@^6.1.0": - version "6.1.0" - resolved "https://registry.yarnpkg.com/@fastify/jwt/-/jwt-6.1.0.tgz#982d6ed9dec95bca6cd35c0de3463890c208674d" - integrity sha512-HBNSmX4AH8bwGHjjf7p/nx+Zjk2weX4iRziBpKyvZvA9Ipc7GE/Oxk+f7VsaiNuZ3R2vs42nBgvddacT6guaEw== +"@fastify/jwt@^6.5.0": + version "6.5.0" + resolved "https://registry.npmjs.org/@fastify/jwt/-/jwt-6.5.0.tgz#99fa697e7114aee5039f0c8761d0b3278f74f30a" + integrity sha512-5fR5bRXuWurP56gy/owng3BS/3e9vA0mON1XCGLsznvsudLZUdiPaK0R8Bl5gVwFAW75iFkNOp8qgnw26Csjrw== dependencies: + "@fastify/error" "^3.0.0" "@lukeed/ms" "^2.0.0" - fast-jwt "^1.5.1" - fastify-plugin "^3.0.1" - http-errors "^2.0.0" + fast-jwt "^2.0.0" + fastify-plugin "^4.0.0" steed "^1.1.3" "@fastify/type-provider-typebox@^1.0.0": @@ -1101,7 +1096,7 @@ ajv@^6.10.0, ajv@^6.12.4, ajv@^6.12.5: json-schema-traverse "^0.4.1" uri-js "^4.2.2" -ajv@^8.0.0, ajv@^8.10.0, ajv@^8.11.0, ajv@^8.8.0: +ajv@^8.0.0, ajv@^8.1.0, ajv@^8.10.0, ajv@^8.11.0, ajv@^8.8.0: version "8.11.0" resolved "https://registry.yarnpkg.com/ajv/-/ajv-8.11.0.tgz#977e91dd96ca669f54a11e23e378e33b884a565f" integrity sha512-wGgprdCvMalC0BztXvitD2hC04YffAvtsUn93JbGXYLAtCUO4xd17mCCZQxUOItiBwZvJScWo8NIvQMQ71rdpg== @@ -1370,14 +1365,15 @@ ava@^4.3.1: write-file-atomic "^4.0.1" yargs "^17.5.1" -avvio@^8.2.0: - version "8.2.0" - resolved "https://registry.yarnpkg.com/avvio/-/avvio-8.2.0.tgz#aff28b0266617bf07ffc1c2d5f4220c3663ce1c2" - integrity sha512-bbCQdg7bpEv6kGH41RO/3B2/GMMmJSo2iBK+X8AWN9mujtfUipMDfIjsgHCfpnKqoGEQrrmCDKSa5OQ19+fDmg== +avvio@^8.1.3: + version "8.1.3" + resolved "https://registry.yarnpkg.com/avvio/-/avvio-8.1.3.tgz#9ff0839ade93bcab62e212e7bdd4281dd6adccc3" + integrity sha512-tl9TC0yDRKzP6gFLkrInqPyx8AkfBC/0QRnwkE9Jo31+OJjLrE/73GJuE0QgSB0Vpv38CTJJZGqU9hczowclWw== dependencies: archy "^1.0.0" debug "^4.0.0" fastq "^1.6.1" + queue-microtask "^1.1.2" awesome-phonenumber@^2.70.0: version "2.70.0" @@ -2095,11 +2091,6 @@ denque@^1.4.1: resolved "https://registry.yarnpkg.com/denque/-/denque-1.5.0.tgz#773de0686ff2d8ec2ff92914316a47b73b1c73de" integrity sha512-CYiCSgIF1p6EUByQPlGkKnP1M9g0ZV3qMIrqMqZqdwazygIA/YP2vrbcyl1h/WppKJTdl1F85cXIle+394iDAQ== -depd@2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/depd/-/depd-2.0.0.tgz#b696163cc757560d09cf22cc8fad1571b79e76df" - integrity sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw== - depd@~1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/depd/-/depd-1.1.2.tgz#9bcd52e14c097763e749b274c4346ed2e560b5a9" @@ -2585,11 +2576,6 @@ extend-shallow@^2.0.1: dependencies: is-extendable "^0.1.0" -fast-decode-uri-component@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/fast-decode-uri-component/-/fast-decode-uri-component-1.0.1.tgz#46f8b6c22b30ff7a81357d4f59abfae938202543" - integrity sha512-WKgKWg5eUxvRZGwW8FvfbaH7AXSh2cL+3j5fMGzUMCxWBJ3dV3a7Wz8y2f/uQ0e3B6WmodD3oS54jTQ9HVTIIg== - fast-deep-equal@^3.1.1, fast-deep-equal@^3.1.3: version "3.1.3" resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz#3a7d56b559d6cbc3eb512325244e619a65c6c525" @@ -2628,22 +2614,22 @@ fast-json-stable-stringify@^2.0.0: resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz#874bf69c6f404c2b5d99c481341399fd55892633" integrity sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw== -fast-json-stringify@^5.0.0: - version "5.4.0" - resolved "https://registry.yarnpkg.com/fast-json-stringify/-/fast-json-stringify-5.4.0.tgz#6d5066a13bb84f237141375588ddaabfaad6ba2d" - integrity sha512-PIzon53oX/zEGLrGbu4DpfNcYiV4K4rk+JsVrawRPO/G8cNBEMZ3KlIk2BCGqN+m1KCCA4zt5E7Hh3GG9ojRVA== +fast-json-stringify@^4.2.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/fast-json-stringify/-/fast-json-stringify-4.2.0.tgz#eb49243c79d1deca85eeb488caf69007b7336c7c" + integrity sha512-9RWBl82H7jwnPlkZ/ghi0VD5OFZVdwgwVui0nYzjnXbPQxJ3ES1+SQcWIoeCJOgrY7JkBkY/69UNZSroFPDRdQ== dependencies: - "@fastify/deepmerge" "^1.0.0" ajv "^8.10.0" ajv-formats "^2.1.1" - fast-deep-equal "^3.1.3" - fast-uri "^2.1.0" + deepmerge "^4.2.2" + fast-uri "^2.0.0" rfdc "^1.2.0" + string-similarity "^4.0.1" -fast-jwt@^1.5.1, fast-jwt@^1.6.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/fast-jwt/-/fast-jwt-1.6.0.tgz#cf907c89eb90ffd684672bdd598e1c7dae68d0f1" - integrity sha512-XFjyWeaDpUAtJi9QJz8tul6ducfYJ6A7gPJczdSRD5/2XR9OkjFonJ3t9yjMtUSIkeCNAK+wMXmuh8Nz7mw+2g== +fast-jwt@^2.0.0, fast-jwt@^2.1.0: + version "2.1.0" + resolved "https://registry.npmjs.org/fast-jwt/-/fast-jwt-2.1.0.tgz#bc508166a6860ba623da368f35e9c750cb56b807" + integrity sha512-NgDiaG9BacwCwSc39MfYywnDWMTAguRNDTE5bq1Vr34Qwpv0V6nNy7AeReXfa++aH8k/z4RYbqsoy2/PLNagQw== dependencies: asn1.js "^5.3.0" ecdsa-sig-formatter "^1.0.11" @@ -2654,19 +2640,17 @@ fast-levenshtein@^2.0.6, fast-levenshtein@~2.0.6: resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" integrity sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc= -fast-querystring@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/fast-querystring/-/fast-querystring-1.0.0.tgz#d6151cd025d4b100e09e24045f6c35ae9ff191ef" - integrity sha512-3LQi62IhQoDlmt4ULCYmh17vRO2EtS7hTSsG4WwoKWgV7GLMKBOecEh+aiavASnLx8I2y89OD33AGLo0ccRhzA== - dependencies: - fast-decode-uri-component "^1.0.1" - fast-redact@^3.1.1: version "3.1.1" resolved "https://registry.yarnpkg.com/fast-redact/-/fast-redact-3.1.1.tgz#790fcff8f808c2e12fabbfb2be5cb2deda448fa0" integrity sha512-odVmjC8x8jNeMZ3C+rPMESzXVSEU8tSWSHv9HFxP2mm89G/1WwqhrerJDQm9Zus8X6aoRgQDThKqptdNA6bt+A== -fast-uri@^2.0.0, fast-uri@^2.1.0: +fast-uri@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/fast-uri/-/fast-uri-1.0.1.tgz#dd637f093bccf17ebea58a70c178ee8a70b5aa45" + integrity sha512-dbO/+ny6lX4tt7pvfPMTiHfQVR5igYKFa5BJ2a21TWuOgd2ySp5DYswsEGuMcJZLL3/eJ/MQJ5KNcXyNUvDt8w== + +fast-uri@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/fast-uri/-/fast-uri-2.1.0.tgz#9279432d6b53675c90116b947ed2bbba582d6fb5" integrity sha512-qKRta6N7BWEFVlyonVY/V+BMLgFqktCUV0QjT259ekAIlbVrMaFnFLxJ4s/JPl4tou56S1BzPufI60bLe29fHA== @@ -2698,25 +2682,25 @@ fastify-plugin@^4.0.0: resolved "https://registry.yarnpkg.com/fastify-plugin/-/fastify-plugin-4.2.1.tgz#4b80020957938dbc44b8ad4a898fd8bcfbab3f65" integrity sha512-dlGKiwLzRBKkEf5J5ho0uAD/Jdv8GQVUbriB3tAX3ehRUXE4gTV3lRd5inEg9li1aLzb0EGj8y2K4/8g1TN06g== -fastify@^4.8.1: - version "4.8.1" - resolved "https://registry.yarnpkg.com/fastify/-/fastify-4.8.1.tgz#45a341daa47e87e295ede5de31868ced2a1728c5" - integrity sha512-3an6yyXg7j5XPHTRxgFqUwIRaJPR7F8OPR8Uboo0SIgHx1orOqc9Y8Sl5Kz8+xK7JCy3c3mfRujskDjMu/nFfA== +fastify@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/fastify/-/fastify-4.1.0.tgz#c5b7c03eff57233c2108e52c75559ede8e59eec8" + integrity sha512-nze95u3wpVIsOXMmSi5kgUaEIZq2HJmerk/+ivFBPtYozAydoDg92BcsxDtO4cb8vW4RBkahx8zL5PgH9YulCw== dependencies: - "@fastify/ajv-compiler" "^3.3.1" + "@fastify/ajv-compiler" "^3.1.0" "@fastify/error" "^3.0.0" - "@fastify/fast-json-stringify-compiler" "^4.1.0" + "@fastify/fast-json-stringify-compiler" "^3.0.1" abstract-logging "^2.0.1" - avvio "^8.2.0" - find-my-way "^7.3.0" - light-my-request "^5.6.1" - pino "^8.5.0" + avvio "^8.1.3" + find-my-way "^6.3.0" + light-my-request "^5.0.0" + pino "^8.0.0" process-warning "^2.0.0" proxy-addr "^2.0.7" rfdc "^1.3.0" - secure-json-parse "^2.5.0" + secure-json-parse "^2.4.0" semver "^7.3.7" - tiny-lru "^9.0.2" + tiny-lru "^8.0.2" fastparallel@^2.2.0: version "2.4.0" @@ -2802,13 +2786,12 @@ filter-obj@^1.1.0: resolved "https://registry.yarnpkg.com/filter-obj/-/filter-obj-1.1.0.tgz#9b311112bc6c6127a16e016c6c5d7f19e0805c5b" integrity sha1-mzERErxsYSehbgFsbF1/GeCAXFs= -find-my-way@^7.3.0: - version "7.3.1" - resolved "https://registry.yarnpkg.com/find-my-way/-/find-my-way-7.3.1.tgz#fd8a0b468a18c283e05be59f93a627f37e306cfa" - integrity sha512-kGvM08SOkqvheLcuQ8GW9t/H901Qb9rZEbcNWbXopzy4jDRoaJpJoObPSKf4MnQLZ20ZTp7rL5MpF6rf+pqmyg== +find-my-way@^6.3.0: + version "6.4.0" + resolved "https://registry.yarnpkg.com/find-my-way/-/find-my-way-6.4.0.tgz#2c25558878dfc1875beea6925e6c74ccc37b8c5c" + integrity sha512-OAxMF75jKPpy8jUb29WupNfypFAzBuAiPM6xS17twiP07hJb0tKkD6Fy8dy8pN14AD8hMlc0jA6q0d+Dg5reUQ== dependencies: fast-deep-equal "^3.1.3" - fast-querystring "^1.0.0" safe-regex2 "^2.0.0" find-up@^2.1.0: @@ -3255,17 +3238,6 @@ http-errors@1.7.3: statuses ">= 1.5.0 < 2" toidentifier "1.0.0" -http-errors@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/http-errors/-/http-errors-2.0.0.tgz#b7774a1486ef73cf7667ac9ae0858c012c57b9d3" - integrity sha512-FtwrG/euBzaEjYeRqOgly7G0qviiXoJWnvEH2Z1plBdXgbyjv34pHTSb9zoeHMyDy33+DWy5Wt9Wo+TURtOYSQ== - dependencies: - depd "2.0.0" - inherits "2.0.4" - setprototypeof "1.2.0" - statuses "2.0.1" - toidentifier "1.0.1" - http-proxy-agent@^4.0.0, http-proxy-agent@^4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/http-proxy-agent/-/http-proxy-agent-4.0.1.tgz#8a8c8ef7f5932ccf953c296ca8291b95aa74aa3a" @@ -3890,13 +3862,14 @@ levn@~0.3.0: prelude-ls "~1.1.2" type-check "~0.3.2" -light-my-request@^5.6.1: - version "5.6.1" - resolved "https://registry.yarnpkg.com/light-my-request/-/light-my-request-5.6.1.tgz#cff5c75d8cb35a354433d75406fea74a2f8bcdb1" - integrity sha512-sbJnC1UBRivi9L1kICr3CESb82pNiPNB3TvtdIrZZqW0Qh8uDXvoywMmWKZlihDcmw952CMICCzM+54LDf+E+g== +light-my-request@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/light-my-request/-/light-my-request-5.0.0.tgz#2ac329d472c5c74c74be62fb2a8790c444c22ab0" + integrity sha512-0OPHKV+uHgBOnRokzL1LqeMCnSAo5l/rZS7kyB6G1I8qxGCvhXpq1M6WK565Y9A5CSn50l3DVaHnJ5FCdpguZQ== dependencies: + ajv "^8.1.0" cookie "^0.5.0" - process-warning "^2.0.0" + process-warning "^1.0.0" set-cookie-parser "^2.4.1" lines-and-columns@^1.1.6: @@ -4838,27 +4811,27 @@ pino-abstract-transport@v1.0.0: readable-stream "^4.0.0" split2 "^4.0.0" -pino-std-serializers@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/pino-std-serializers/-/pino-std-serializers-6.0.0.tgz#4c20928a1bafca122fdc2a7a4a171ca1c5f9c526" - integrity sha512-mMMOwSKrmyl+Y12Ri2xhH1lbzQxwwpuru9VjyJpgFIH4asSj88F2csdMwN6+M5g1Ll4rmsYghHLQJw81tgZ7LQ== +pino-std-serializers@^5.0.0: + version "5.6.0" + resolved "https://registry.yarnpkg.com/pino-std-serializers/-/pino-std-serializers-5.6.0.tgz#31b141155d6520967c5ec72944d08fb45c490fd3" + integrity sha512-VdUXCw8gO+xhir7sFuoYSjTnzB+TMDGxhAC/ph3YS3sdHnXNdsK0wMtADNUltfeGkn2KDxEM21fnjF3RwXyC8A== -pino@^8.5.0: - version "8.6.1" - resolved "https://registry.yarnpkg.com/pino/-/pino-8.6.1.tgz#3fc43acc79bcd3e871670347854f7359e2612f10" - integrity sha512-fi+V2K98eMZjQ/uEHHSiMALNrz7HaFdKNYuyA3ZUrbH0f1e8sPFDmeRGzg7ZH2q4QDxGnJPOswmqlEaTAZeDPA== +pino@^8.0.0: + version "8.1.0" + resolved "https://registry.yarnpkg.com/pino/-/pino-8.1.0.tgz#6211c5e77d813624f6707ec4750f4fbf778d5621" + integrity sha512-53jlxs+02UNTtF1XwVWfa0dHipBiM5GK73XhkHn8M2hUl9y3L94dNwB8BwQhpd5WdHjBkyJiO7v0LRt4SGgsPg== dependencies: atomic-sleep "^1.0.0" fast-redact "^3.1.1" on-exit-leak-free "^2.1.0" pino-abstract-transport v1.0.0 - pino-std-serializers "^6.0.0" + pino-std-serializers "^5.0.0" process-warning "^2.0.0" quick-format-unescaped "^4.0.3" - real-require "^0.2.0" + real-require "^0.1.0" safe-stable-stringify "^2.3.1" - sonic-boom "^3.1.0" - thread-stream "^2.0.0" + sonic-boom "^3.0.0" + thread-stream "^1.0.0" pkg-conf@^4.0.0: version "4.0.0" @@ -4933,6 +4906,11 @@ process-nextick-args@~2.0.0: resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.1.tgz#7820d9b16120cc55ca9ae7792680ae7dba6d7fe2" integrity sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag== +process-warning@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/process-warning/-/process-warning-1.0.0.tgz#980a0b25dc38cd6034181be4b7726d89066b4616" + integrity sha512-du4wfLyj4yCZq1VupnVSZmRsPJsNuxoDQFdCFHLaYiEbFBD7QE0a+I4D7hOxrVnh78QE/YipFAj9lXHiXocV+Q== + process-warning@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/process-warning/-/process-warning-2.0.0.tgz#341dbeaac985b90a04ebcd844d50097c7737b2ee" @@ -5029,7 +5007,7 @@ query-string@^7.1.1: split-on-first "^1.0.0" strict-uri-encode "^2.0.0" -queue-microtask@^1.2.2: +queue-microtask@^1.1.2, queue-microtask@^1.2.2: version "1.2.3" resolved "https://registry.yarnpkg.com/queue-microtask/-/queue-microtask-1.2.3.tgz#4929228bbc724dfac43e0efb058caf7b6cfb6243" integrity sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A== @@ -5126,10 +5104,10 @@ readdirp@~3.6.0: dependencies: picomatch "^2.2.1" -real-require@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/real-require/-/real-require-0.2.0.tgz#209632dea1810be2ae063a6ac084fee7e33fba78" - integrity sha512-57frrGM/OCTLqLOAh0mhVA9VBMHd+9U7Zb2THMGdBUoZVOtGbJzjxsYGDJ3A9AYYCP4hn6y1TVbaOfzWtm5GFg== +real-require@^0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/real-require/-/real-require-0.1.0.tgz#736ac214caa20632847b7ca8c1056a0767df9381" + integrity sha512-r/H9MzAWtrv8aSVjPCMFpDMl5q66GqtmmRkRjpHTsp4zBAa+snZyiQNlMONiUmEJcsnaw0wCauJ2GWODr/aFkg== rechoir@^0.7.0: version "0.7.0" @@ -5347,10 +5325,10 @@ sdk-base@^2.0.1: dependencies: get-ready "~1.0.0" -secure-json-parse@^2.5.0: - version "2.5.0" - resolved "https://registry.yarnpkg.com/secure-json-parse/-/secure-json-parse-2.5.0.tgz#f929829df2adc7ccfb53703569894d051493a6ac" - integrity sha512-ZQruFgZnIWH+WyO9t5rWt4ZEGqCKPwhiw+YbzTwpmT9elgLrLcfuyUiSnwwjUiVy9r4VM3urtbNF1xmEh9IL2w== +secure-json-parse@^2.4.0: + version "2.4.0" + resolved "https://registry.yarnpkg.com/secure-json-parse/-/secure-json-parse-2.4.0.tgz#5aaeaaef85c7a417f76271a4f5b0cc3315ddca85" + integrity sha512-Q5Z/97nbON5t/L/sH6mY2EacfjVGwrCcSi5D3btRO2GZ8pf1K1UN7Z9H5J57hjVU2Qzxr1xO+FmBhOvEkzCMmg== semver-compare@^1.0.0: version "1.0.0" @@ -5362,7 +5340,7 @@ semver-compare@^1.0.0: resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7" integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== -semver@7.3.7, semver@^7.3.2, semver@^7.3.4, semver@^7.3.5, semver@^7.3.7: +semver@7.3.7, semver@^7.3.5, semver@^7.3.7: version "7.3.7" resolved "https://registry.yarnpkg.com/semver/-/semver-7.3.7.tgz#12c5b649afdbf9049707796e22a4028814ce523f" integrity sha512-QlYTucUYOews+WeEujDoEGziz4K6c47V/Bd+LjSSYcA94p+DmINdf7ncaUinThfvZyu13lN9OY1XDxt8C0Tw0g== @@ -5374,6 +5352,13 @@ semver@^6.0.0: resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw== +semver@^7.3.2, semver@^7.3.4: + version "7.3.5" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.3.5.tgz#0b621c879348d8998e4b0e4be94b3f12e6018ef7" + integrity sha512-PoeGJYh8HK4BTO/a9Tf6ZG3veo/A7ZVsYrSA6J8ny9nb3B1VrpkuN+z9OE5wfE5p6H4LchYZsegiQgbJD94ZFQ== + dependencies: + lru-cache "^6.0.0" + seq-queue@^0.0.5: version "0.0.5" resolved "https://registry.yarnpkg.com/seq-queue/-/seq-queue-0.0.5.tgz#d56812e1c017a6e4e7c3e3a37a1da6d78dd3c93e" @@ -5403,11 +5388,6 @@ setprototypeof@1.1.1: resolved "https://registry.yarnpkg.com/setprototypeof/-/setprototypeof-1.1.1.tgz#7e95acb24aa92f5885e0abef5ba131330d4ae683" integrity sha512-JvdAWfbXeIGaZ9cILp38HntZSFSo3mWg6xGcJJsd+d4aRMOqauag1C63dJfDw7OaMYwEbHMOxEZ1lqVRYP2OAw== -setprototypeof@1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/setprototypeof/-/setprototypeof-1.2.0.tgz#66c9a24a73f9fc28cbe66b09fed3d33dcaf1b424" - integrity sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw== - sha.js@^2.4.11: version "2.4.11" resolved "https://registry.yarnpkg.com/sha.js/-/sha.js-2.4.11.tgz#37a5cf0b81ecbc6943de109ba2960d1b26584ae7" @@ -5529,10 +5509,10 @@ socks@^2.3.3: ip "^1.1.5" smart-buffer "^4.1.0" -sonic-boom@^3.1.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/sonic-boom/-/sonic-boom-3.2.0.tgz#ce9f2de7557e68be2e52c8df6d9b052e7d348143" - integrity sha512-SbbZ+Kqj/XIunvIAgUZRlqd6CGQYq71tRRbXR92Za8J/R3Yh4Av+TWENiSiEgnlwckYLyP0YZQWVfyNC0dzLaA== +sonic-boom@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/sonic-boom/-/sonic-boom-3.0.0.tgz#235119a6606e2646919a27d83ef687f2ba6c0fba" + integrity sha512-p5DiZOZHbJ2ZO5MADczp5qrfOd3W5Vr2vHxfCpe7G4AzPwVOweIjbfgku8wSQUuk+Y5Yuo8W7JqRe6XKmKistg== dependencies: atomic-sleep "^1.0.0" @@ -5614,11 +5594,6 @@ standard-as-callback@^2.1.0: resolved "https://registry.yarnpkg.com/standard-as-callback/-/standard-as-callback-2.1.0.tgz#8953fc05359868a77b5b9739a665c5977bb7df45" integrity sha512-qoRRSyROncaz1z0mvYqIE4lCd9p2R90i6GxW3uZv5ucSu8tU7B5HXUP1gG8pVZsYNVaXjk8ClXHPttLyxAL48A== -statuses@2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/statuses/-/statuses-2.0.1.tgz#55cb000ccf1d48728bd23c685a063998cf1a1b63" - integrity sha512-RwNA9Z/7PrK06rYLIzFMlaF+l73iwpzsqRIFgbMLbTcLD6cOao82TaWefPXQvB2fOC4AjuYSEndS7N/mTCbkdQ== - "statuses@>= 1.5.0 < 2", statuses@^1.3.1: version "1.5.0" resolved "https://registry.yarnpkg.com/statuses/-/statuses-1.5.0.tgz#161c7dac177659fd9811f43771fa99381478628c" @@ -5661,6 +5636,11 @@ string-argv@0.3.1: resolved "https://registry.yarnpkg.com/string-argv/-/string-argv-0.3.1.tgz#95e2fbec0427ae19184935f816d74aaa4c5c19da" integrity sha512-a1uQGz7IyVy9YwhqjZIZu1c8JO8dNIe20xBmSS6qu9kv++k3JGzCVmprbNN5Kn+BgzD5E7YYwg1CcjuJMRNsvg== +string-similarity@^4.0.1: + version "4.0.4" + resolved "https://registry.yarnpkg.com/string-similarity/-/string-similarity-4.0.4.tgz#42d01ab0b34660ea8a018da8f56a3309bb8b2a5b" + integrity sha512-/q/8Q4Bl4ZKAPjj8WerIBJWALKkaPRfrvhfF8k/B23i4nzrlRj2/go1m90In7nG/3XDSbOo0+pu6RvCTM9RGMQ== + string-width@^4.1.0, string-width@^4.2.0: version "4.2.2" resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.2.tgz#dafd4f9559a7585cfba529c6a0a4f73488ebd4c5" @@ -5896,12 +5876,12 @@ thenify-all@^1.0.0: dependencies: any-promise "^1.0.0" -thread-stream@^2.0.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/thread-stream/-/thread-stream-2.2.0.tgz#310c03a253f729094ce5d4638ef5186dfa80a9e8" - integrity sha512-rUkv4/fnb4rqy/gGy7VuqK6wE1+1DOCOWy4RMeaV69ZHMP11tQKZvZSip1yTgrKCMZzEMcCL/bKfHvSfDHx+iQ== +thread-stream@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/thread-stream/-/thread-stream-1.0.0.tgz#a7ba5c3defceb77c69deea6c3a62faf74891e4ba" + integrity sha512-2Sw29jWubQWOcVa7MhLHJ51wjksUD/GHN4Fy3hP9w9DYTujifoZGSKBl54CMLRXWoD5h2pD707kY3fAdzhcwAg== dependencies: - real-require "^0.2.0" + real-require "^0.1.0" through2@^4.0.0: version "4.0.2" @@ -5920,10 +5900,10 @@ time-zone@^1.0.0: resolved "https://registry.yarnpkg.com/time-zone/-/time-zone-1.0.0.tgz#99c5bf55958966af6d06d83bdf3800dc82faec5d" integrity sha1-mcW/VZWJZq9tBtg73zgA3IL67F0= -tiny-lru@^9.0.2: - version "9.0.3" - resolved "https://registry.yarnpkg.com/tiny-lru/-/tiny-lru-9.0.3.tgz#f6a2121f433607a7f338881a23090829c1ea8cae" - integrity sha512-/i9GruRjXsnDgehxvy6iZ4AFNVxngEFbwzirhdulomMNPGPVV3ECMZOWSw0w4sRMZ9Al9m4jy08GPvRxRUGYlw== +tiny-lru@^8.0.2: + version "8.0.2" + resolved "https://registry.yarnpkg.com/tiny-lru/-/tiny-lru-8.0.2.tgz#812fccbe6e622ded552e3ff8a4c3b5ff34a85e4c" + integrity sha512-ApGvZ6vVvTNdsmt676grvCkUCGwzG9IqXma5Z07xJgiC5L7akUMof5U8G2JTI9Rz/ovtVhJBlY6mNhEvtjzOIg== to-arraybuffer@^1.0.0: version "1.0.1" @@ -5942,11 +5922,6 @@ toidentifier@1.0.0: resolved "https://registry.yarnpkg.com/toidentifier/-/toidentifier-1.0.0.tgz#7e1be3470f1e77948bc43d94a3c8f4d7752ba553" integrity sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw== -toidentifier@1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/toidentifier/-/toidentifier-1.0.1.tgz#3be34321a88a820ed1bd80dfaa33e479fbb8dd35" - integrity sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA== - trim-newlines@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/trim-newlines/-/trim-newlines-3.0.1.tgz#260a5d962d8b752425b32f3a7db0dcacd176c144"