From 53ae3870e4f332310a7b6e359188371aa16714cf Mon Sep 17 00:00:00 2001 From: Daniel Chambers Date: Thu, 9 May 2024 10:21:40 +1000 Subject: [PATCH] Remove type inference recursion limit (#33) * Update to NDC TS SDK v4.6.0 --- CHANGELOG.md | 8 +- ndc-lambda-sdk/package-lock.json | 494 ++++++++++++++++------------- ndc-lambda-sdk/package.json | 4 +- ndc-lambda-sdk/src/inference.ts | 43 ++- yeoman-generator/package-lock.json | 4 +- yeoman-generator/package.json | 2 +- 6 files changed, 296 insertions(+), 259 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 936f3ee..4ce6cd9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,4 @@ -# NodeJS Lambda Connector Changelog +# Node.js Lambda Connector Changelog This changelog documents the changes between release versions. > [!IMPORTANT] @@ -7,6 +7,12 @@ This changelog documents the changes between release versions. ## [Unreleased] Changes to be included in the next upcoming release +## [1.4.0] - 2024-05-08 +- Removed type inference recursion limit ([#33](https://github.com/hasura/ndc-nodejs-lambda/pull/33)). This enables the use of very nested object graphs. +- Updated the NDC TypeScript SDK to v4.6.0 ([#33](https://github.com/hasura/ndc-nodejs-lambda/pull/33)). + - This enables the /metrics endpoint to return the default prometheus metrics + - `ConnectorError`s can be thrown and now use any HTTP status code + ## [1.3.0] - 2024-04-17 - Fixed watch mode not reloading after files with compiler errors are changed [#27](https://github.com/hasura/ndc-nodejs-lambda/pull/27) - Fixed functions that are imported then re-exported causing a crash [#28](https://github.com/hasura/ndc-nodejs-lambda/pull/28) diff --git a/ndc-lambda-sdk/package-lock.json b/ndc-lambda-sdk/package-lock.json index 388c536..9d80705 100644 --- a/ndc-lambda-sdk/package-lock.json +++ b/ndc-lambda-sdk/package-lock.json @@ -1,15 +1,15 @@ { "name": "@hasura/ndc-lambda-sdk", - "version": "1.3.0", + "version": "1.4.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@hasura/ndc-lambda-sdk", - "version": "1.3.0", + "version": "1.4.0", "license": "Apache-2.0", "dependencies": { - "@hasura/ndc-sdk-typescript": "^4.5.0", + "@hasura/ndc-sdk-typescript": "^4.6.0", "@tsconfig/node20": "^20.1.3", "commander": "^11.1.0", "cross-spawn": "^7.0.3", @@ -73,25 +73,25 @@ } }, "node_modules/@grpc/grpc-js": { - "version": "1.10.1", - "resolved": "https://registry.npmjs.org/@grpc/grpc-js/-/grpc-js-1.10.1.tgz", - "integrity": "sha512-55ONqFytZExfOIjF1RjXPcVmT/jJqFzbbDqxK9jmRV4nxiYWtL9hENSW1Jfx0SdZfrvoqd44YJ/GJTqfRrawSQ==", + "version": "1.10.7", + "resolved": "https://registry.npmjs.org/@grpc/grpc-js/-/grpc-js-1.10.7.tgz", + "integrity": "sha512-ZMBVjSeDAz3tFSehyO6Pd08xZT1HfIwq3opbeM4cDlBh52gmwp0wVIPcQur53NN0ac68HMZ/7SF2rGRD5KmVmg==", "dependencies": { - "@grpc/proto-loader": "^0.7.8", - "@types/node": ">=12.12.47" + "@grpc/proto-loader": "^0.7.13", + "@js-sdsl/ordered-map": "^4.4.2" }, "engines": { - "node": "^8.13.0 || >=10.10.0" + "node": ">=12.10.0" } }, "node_modules/@grpc/proto-loader": { - "version": "0.7.10", - "resolved": "https://registry.npmjs.org/@grpc/proto-loader/-/proto-loader-0.7.10.tgz", - "integrity": "sha512-CAqDfoaQ8ykFd9zqBDn4k6iWT9loLAlc2ETmDFS9JCD70gDcnA4L3AFEo2iV7KyAtAAHFW9ftq1Fz+Vsgq80RQ==", + "version": "0.7.13", + "resolved": "https://registry.npmjs.org/@grpc/proto-loader/-/proto-loader-0.7.13.tgz", + "integrity": "sha512-AiXO/bfe9bmxBjxxtYxFAXGZvMaN5s8kO+jBHAJCON8rJoB5YS/D6X7ZNc6XQkuHNmyl4CYaMI1fJ/Gn27RGGw==", "dependencies": { "lodash.camelcase": "^4.3.0", "long": "^5.0.0", - "protobufjs": "^7.2.4", + "protobufjs": "^7.2.5", "yargs": "^17.7.2" }, "bin": { @@ -140,24 +140,25 @@ } }, "node_modules/@hasura/ndc-sdk-typescript": { - "version": "4.5.0", - "resolved": "https://registry.npmjs.org/@hasura/ndc-sdk-typescript/-/ndc-sdk-typescript-4.5.0.tgz", - "integrity": "sha512-yRkezh73OZ5BrTFusueEkl0kifWs/oHmkyVb3iUAakVK4obYHLWQrpYOaPfPqA3RysO19opnJcxq6Y07TEh6Hg==", + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/@hasura/ndc-sdk-typescript/-/ndc-sdk-typescript-4.6.0.tgz", + "integrity": "sha512-2WkDrzqCFOMm4hJafZ7+H0ABhDHjIFaU3xi1wkAm8fQM11GveSlI5cpQ2SM38U8a9sbq8qI8UPmeony3niIB/w==", "dependencies": { "@json-schema-tools/meta-schema": "^1.7.0", - "@opentelemetry/api": "^1.7.0", - "@opentelemetry/exporter-metrics-otlp-proto": "^0.48.0", - "@opentelemetry/instrumentation-fastify": "^0.33.0", - "@opentelemetry/instrumentation-fetch": "^0.48.0", - "@opentelemetry/instrumentation-http": "^0.48.0", - "@opentelemetry/instrumentation-pino": "^0.35.0", - "@opentelemetry/resources": "^1.21.0", - "@opentelemetry/sdk-metrics": "^1.21.0", - "@opentelemetry/sdk-node": "^0.48.0", - "@opentelemetry/semantic-conventions": "^1.21.0", + "@opentelemetry/api": "^1.8.0", + "@opentelemetry/exporter-metrics-otlp-proto": "^0.51.0", + "@opentelemetry/instrumentation-fastify": "^0.36.0", + "@opentelemetry/instrumentation-fetch": "^0.51.0", + "@opentelemetry/instrumentation-http": "^0.51.0", + "@opentelemetry/instrumentation-pino": "^0.38.0", + "@opentelemetry/resources": "^1.24.0", + "@opentelemetry/sdk-metrics": "^1.24.0", + "@opentelemetry/sdk-node": "^0.51.0", + "@opentelemetry/semantic-conventions": "^1.24.0", "commander": "^11.0.0", "fastify": "^4.23.2", - "pino-pretty": "^10.2.3" + "pino-pretty": "^10.2.3", + "prom-client": "^15.1.2" } }, "node_modules/@jridgewell/resolve-uri": { @@ -182,23 +183,32 @@ "@jridgewell/sourcemap-codec": "^1.4.10" } }, + "node_modules/@js-sdsl/ordered-map": { + "version": "4.4.2", + "resolved": "https://registry.npmjs.org/@js-sdsl/ordered-map/-/ordered-map-4.4.2.tgz", + "integrity": "sha512-iUKgm52T8HOE/makSxjqoWhe95ZJA1/G1sYsGev2JDKUSS14KAgg1LHb+Ba+IPow0xflbnSkOsZcO08C7w1gYw==", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/js-sdsl" + } + }, "node_modules/@json-schema-tools/meta-schema": { "version": "1.7.0", "resolved": "https://registry.npmjs.org/@json-schema-tools/meta-schema/-/meta-schema-1.7.0.tgz", "integrity": "sha512-3pDzVUssW3hVnf8gvSu1sKaVIpLyvmpbxgGfkUoaBiErFKRS2CZOufHD0pUFoa5e6Cd5oa72s402nJbnDz76CA==" }, "node_modules/@opentelemetry/api": { - "version": "1.7.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/api/-/api-1.7.0.tgz", - "integrity": "sha512-AdY5wvN0P2vXBi3b29hxZgSFvdhdxPB9+f0B6s//P9Q8nibRWeA3cHm8UmLpio9ABigkVHJ5NMPk+Mz8VCCyrw==", + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/@opentelemetry/api/-/api-1.8.0.tgz", + "integrity": "sha512-I/s6F7yKUDdtMsoBWXJe8Qz40Tui5vsuKCWJEWVL+5q9sSWRzzx6v2KeNsOBEwd94j0eWkpWCH4yB6rZg9Mf0w==", "engines": { "node": ">=8.0.0" } }, "node_modules/@opentelemetry/api-logs": { - "version": "0.48.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/api-logs/-/api-logs-0.48.0.tgz", - "integrity": "sha512-1/aMiU4Eqo3Zzpfwu51uXssp5pzvHFObk8S9pKAiXb1ne8pvg1qxBQitYL1XUiAMEXFzgjaidYG2V6624DRhhw==", + "version": "0.51.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/api-logs/-/api-logs-0.51.1.tgz", + "integrity": "sha512-E3skn949Pk1z2XtXu/lxf6QAZpawuTM/IUEXcAzpiUkTd73Hmvw26FiN3cJuTmkpM5hZzHwkomVdtrh/n/zzwA==", "dependencies": { "@opentelemetry/api": "^1.0.0" }, @@ -207,40 +217,40 @@ } }, "node_modules/@opentelemetry/context-async-hooks": { - "version": "1.21.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/context-async-hooks/-/context-async-hooks-1.21.0.tgz", - "integrity": "sha512-t0iulGPiMjG/NrSjinPQoIf8ST/o9V0dGOJthfrFporJlNdlKIQPfC7lkrV+5s2dyBThfmSbJlp/4hO1eOcDXA==", + "version": "1.24.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/context-async-hooks/-/context-async-hooks-1.24.1.tgz", + "integrity": "sha512-R5r6DO4kgEOVBxFXhXjwospLQkv+sYxwCfjvoZBe7Zm6KKXAV9kDSJhi/D1BweowdZmO+sdbENLs374gER8hpQ==", "engines": { "node": ">=14" }, "peerDependencies": { - "@opentelemetry/api": ">=1.0.0 <1.8.0" + "@opentelemetry/api": ">=1.0.0 <1.9.0" } }, "node_modules/@opentelemetry/core": { - "version": "1.21.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/core/-/core-1.21.0.tgz", - "integrity": "sha512-KP+OIweb3wYoP7qTYL/j5IpOlu52uxBv5M4+QhSmmUfLyTgu1OIS71msK3chFo1D6Y61BIH3wMiMYRCxJCQctA==", + "version": "1.24.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/core/-/core-1.24.1.tgz", + "integrity": "sha512-wMSGfsdmibI88K9wB498zXY04yThPexo8jvwNNlm542HZB7XrrMRBbAyKJqG8qDRJwIBdBrPMi4V9ZPW/sqrcg==", "dependencies": { - "@opentelemetry/semantic-conventions": "1.21.0" + "@opentelemetry/semantic-conventions": "1.24.1" }, "engines": { "node": ">=14" }, "peerDependencies": { - "@opentelemetry/api": ">=1.0.0 <1.8.0" + "@opentelemetry/api": ">=1.0.0 <1.9.0" } }, "node_modules/@opentelemetry/exporter-metrics-otlp-http": { - "version": "0.48.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/exporter-metrics-otlp-http/-/exporter-metrics-otlp-http-0.48.0.tgz", - "integrity": "sha512-lZ0gah/WjPpUBVR2Qml8GHraLznsXEpmIS897vdL2IXCxJzGev7sCb9IwAiq89+MgHkuGUWhTWFB2frKrqX1sA==", + "version": "0.51.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/exporter-metrics-otlp-http/-/exporter-metrics-otlp-http-0.51.1.tgz", + "integrity": "sha512-oFXvif9iksHUxrzG3P8ohMLt7xSrl+oDMqxD/3XXndU761RFAKSbRDpfrQs25U5D+A2aMV3qk+4kfUWdJhZ77g==", "dependencies": { - "@opentelemetry/core": "1.21.0", - "@opentelemetry/otlp-exporter-base": "0.48.0", - "@opentelemetry/otlp-transformer": "0.48.0", - "@opentelemetry/resources": "1.21.0", - "@opentelemetry/sdk-metrics": "1.21.0" + "@opentelemetry/core": "1.24.1", + "@opentelemetry/otlp-exporter-base": "0.51.1", + "@opentelemetry/otlp-transformer": "0.51.1", + "@opentelemetry/resources": "1.24.1", + "@opentelemetry/sdk-metrics": "1.24.1" }, "engines": { "node": ">=14" @@ -250,17 +260,17 @@ } }, "node_modules/@opentelemetry/exporter-metrics-otlp-proto": { - "version": "0.48.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/exporter-metrics-otlp-proto/-/exporter-metrics-otlp-proto-0.48.0.tgz", - "integrity": "sha512-lWvYUYcviDhKx6/vMnWJJ3PvkgZhm0hWmWwvNqS2KgSlcyDaNHs+6yZGFwnPYvGOL6keIAywfPRzzgVPUOOK2g==", + "version": "0.51.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/exporter-metrics-otlp-proto/-/exporter-metrics-otlp-proto-0.51.1.tgz", + "integrity": "sha512-jhj8xD6S4cydXGCuf2tp56+4QI0DbDH6g+0MiPPJVdXjxLj+iycQuqB2cwljWpByblFaOjyUsL/VKtm8C7sQ9A==", "dependencies": { - "@opentelemetry/core": "1.21.0", - "@opentelemetry/exporter-metrics-otlp-http": "0.48.0", - "@opentelemetry/otlp-exporter-base": "0.48.0", - "@opentelemetry/otlp-proto-exporter-base": "0.48.0", - "@opentelemetry/otlp-transformer": "0.48.0", - "@opentelemetry/resources": "1.21.0", - "@opentelemetry/sdk-metrics": "1.21.0" + "@opentelemetry/core": "1.24.1", + "@opentelemetry/exporter-metrics-otlp-http": "0.51.1", + "@opentelemetry/otlp-exporter-base": "0.51.1", + "@opentelemetry/otlp-proto-exporter-base": "0.51.1", + "@opentelemetry/otlp-transformer": "0.51.1", + "@opentelemetry/resources": "1.24.1", + "@opentelemetry/sdk-metrics": "1.24.1" }, "engines": { "node": ">=14" @@ -270,16 +280,16 @@ } }, "node_modules/@opentelemetry/exporter-trace-otlp-grpc": { - "version": "0.48.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/exporter-trace-otlp-grpc/-/exporter-trace-otlp-grpc-0.48.0.tgz", - "integrity": "sha512-+qRQXUbdRW6aNRT5yWOG3G6My1VxxKeqgUyLkkdIjkT20lvymjiN2RpBfGMtAf/oqnuRknf9snFl9VSIO2gniw==", + "version": "0.51.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/exporter-trace-otlp-grpc/-/exporter-trace-otlp-grpc-0.51.1.tgz", + "integrity": "sha512-P9+Hkszih95ITvldGZ+kXvj9HpD1QfS+PwooyHK72GYA+Bgm+yUSAsDkUkDms8+s9HW6poxURv3LcjaMuBBpVQ==", "dependencies": { "@grpc/grpc-js": "^1.7.1", - "@opentelemetry/core": "1.21.0", - "@opentelemetry/otlp-grpc-exporter-base": "0.48.0", - "@opentelemetry/otlp-transformer": "0.48.0", - "@opentelemetry/resources": "1.21.0", - "@opentelemetry/sdk-trace-base": "1.21.0" + "@opentelemetry/core": "1.24.1", + "@opentelemetry/otlp-grpc-exporter-base": "0.51.1", + "@opentelemetry/otlp-transformer": "0.51.1", + "@opentelemetry/resources": "1.24.1", + "@opentelemetry/sdk-trace-base": "1.24.1" }, "engines": { "node": ">=14" @@ -289,15 +299,15 @@ } }, "node_modules/@opentelemetry/exporter-trace-otlp-http": { - "version": "0.48.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/exporter-trace-otlp-http/-/exporter-trace-otlp-http-0.48.0.tgz", - "integrity": "sha512-QEZKbfWqXrbKVpr2PHd4KyKI0XVOhUYC+p2RPV8s+2K5QzZBE3+F9WlxxrXDfkrvGmpQAZytBoHQQYA3AGOtpw==", + "version": "0.51.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/exporter-trace-otlp-http/-/exporter-trace-otlp-http-0.51.1.tgz", + "integrity": "sha512-n+LhLPsX07URh+HhV2SHVSvz1t4G/l/CE5BjpmhAPqeTceFac1VpyQkavWEJbvnK5bUEXijWt4LxAxFpt2fXyw==", "dependencies": { - "@opentelemetry/core": "1.21.0", - "@opentelemetry/otlp-exporter-base": "0.48.0", - "@opentelemetry/otlp-transformer": "0.48.0", - "@opentelemetry/resources": "1.21.0", - "@opentelemetry/sdk-trace-base": "1.21.0" + "@opentelemetry/core": "1.24.1", + "@opentelemetry/otlp-exporter-base": "0.51.1", + "@opentelemetry/otlp-transformer": "0.51.1", + "@opentelemetry/resources": "1.24.1", + "@opentelemetry/sdk-trace-base": "1.24.1" }, "engines": { "node": ">=14" @@ -307,16 +317,16 @@ } }, "node_modules/@opentelemetry/exporter-trace-otlp-proto": { - "version": "0.48.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/exporter-trace-otlp-proto/-/exporter-trace-otlp-proto-0.48.0.tgz", - "integrity": "sha512-hVXr/8DYlAKAzQYMsCf3ZsGweS6NTK3IHIEqmLokJZYcvJQBEEazeAdISfrL/utWnapg1Qnpw8u+W6SpxNzmTw==", + "version": "0.51.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/exporter-trace-otlp-proto/-/exporter-trace-otlp-proto-0.51.1.tgz", + "integrity": "sha512-SE9f0/6V6EeXC9i+WA4WFjS1EYgaBCpAnI5+lxWvZ7iO7EU1IvHvZhP6Kojr0nLldo83gqg6G7OWFqsID3uF+w==", "dependencies": { - "@opentelemetry/core": "1.21.0", - "@opentelemetry/otlp-exporter-base": "0.48.0", - "@opentelemetry/otlp-proto-exporter-base": "0.48.0", - "@opentelemetry/otlp-transformer": "0.48.0", - "@opentelemetry/resources": "1.21.0", - "@opentelemetry/sdk-trace-base": "1.21.0" + "@opentelemetry/core": "1.24.1", + "@opentelemetry/otlp-exporter-base": "0.51.1", + "@opentelemetry/otlp-proto-exporter-base": "0.51.1", + "@opentelemetry/otlp-transformer": "0.51.1", + "@opentelemetry/resources": "1.24.1", + "@opentelemetry/sdk-trace-base": "1.24.1" }, "engines": { "node": ">=14" @@ -326,14 +336,14 @@ } }, "node_modules/@opentelemetry/exporter-zipkin": { - "version": "1.21.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/exporter-zipkin/-/exporter-zipkin-1.21.0.tgz", - "integrity": "sha512-J0ejrOx52s1PqvjNalIHvY/4v9ZxR2r7XS7WZbwK3qpVYZlGVq5V1+iCNweqsKnb/miUt/4TFvJBc9f5Q/kGcA==", + "version": "1.24.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/exporter-zipkin/-/exporter-zipkin-1.24.1.tgz", + "integrity": "sha512-+Rl/VFmu2n6eaRMnVbyfZx1DqR/1KNyWebYuHyQBZaEAVIn/ZLgmofRpXN1X2nhJ4BNaptQUNxAstCYYz6dKoQ==", "dependencies": { - "@opentelemetry/core": "1.21.0", - "@opentelemetry/resources": "1.21.0", - "@opentelemetry/sdk-trace-base": "1.21.0", - "@opentelemetry/semantic-conventions": "1.21.0" + "@opentelemetry/core": "1.24.1", + "@opentelemetry/resources": "1.24.1", + "@opentelemetry/sdk-trace-base": "1.24.1", + "@opentelemetry/semantic-conventions": "1.24.1" }, "engines": { "node": ">=14" @@ -343,12 +353,13 @@ } }, "node_modules/@opentelemetry/instrumentation": { - "version": "0.48.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/instrumentation/-/instrumentation-0.48.0.tgz", - "integrity": "sha512-sjtZQB5PStIdCw5ovVTDGwnmQC+GGYArJNgIcydrDSqUTdYBnMrN9P4pwQZgS3vTGIp+TU1L8vMXGe51NVmIKQ==", + "version": "0.51.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/instrumentation/-/instrumentation-0.51.1.tgz", + "integrity": "sha512-JIrvhpgqY6437QIqToyozrUG1h5UhwHkaGK/WAX+fkrpyPtc+RO5FkRtUd9BH0MibabHHvqsnBGKfKVijbmp8w==", "dependencies": { + "@opentelemetry/api-logs": "0.51.1", "@types/shimmer": "^1.0.2", - "import-in-the-middle": "1.7.1", + "import-in-the-middle": "1.7.4", "require-in-the-middle": "^7.1.1", "semver": "^7.5.2", "shimmer": "^1.2.1" @@ -361,13 +372,13 @@ } }, "node_modules/@opentelemetry/instrumentation-fastify": { - "version": "0.33.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/instrumentation-fastify/-/instrumentation-fastify-0.33.0.tgz", - "integrity": "sha512-sl3q9Mt+yM6GlZJKhfLUIRrVEYqfmI0hqYLha5OFG5rLrgnZCCZVy8ra4+Pa40ecH1409cvwwBPf7k9AHEQBTw==", + "version": "0.36.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/instrumentation-fastify/-/instrumentation-fastify-0.36.1.tgz", + "integrity": "sha512-3Nfm43PI0I+3EX+1YbSy6xbDu276R1Dh1tqAk68yd4yirnIh52Kd5B+nJ8CgHA7o3UKakpBjj6vSzi5vNCzJIA==", "dependencies": { "@opentelemetry/core": "^1.8.0", - "@opentelemetry/instrumentation": "^0.48.0", - "@opentelemetry/semantic-conventions": "^1.0.0" + "@opentelemetry/instrumentation": "^0.51.0", + "@opentelemetry/semantic-conventions": "^1.22.0" }, "engines": { "node": ">=14" @@ -377,14 +388,14 @@ } }, "node_modules/@opentelemetry/instrumentation-fetch": { - "version": "0.48.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/instrumentation-fetch/-/instrumentation-fetch-0.48.0.tgz", - "integrity": "sha512-y4Zw9VeUUMaowg3aXYZXcaUJQ7IKfpR6sjClrAQOJwWG8LYFpM6NIRSoAeJv/ShfxWWCPWC0P4zgXcKRqpURFQ==", + "version": "0.51.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/instrumentation-fetch/-/instrumentation-fetch-0.51.1.tgz", + "integrity": "sha512-LzciqAnJmmYaXWo2hlrN99NMbYbExo6n6lBKBeMHAi7X/ddhCSOsgSNVbF3kDB7P++PJhjYqLT3hy6SU4AFHcg==", "dependencies": { - "@opentelemetry/core": "1.21.0", - "@opentelemetry/instrumentation": "0.48.0", - "@opentelemetry/sdk-trace-web": "1.21.0", - "@opentelemetry/semantic-conventions": "1.21.0" + "@opentelemetry/core": "1.24.1", + "@opentelemetry/instrumentation": "0.51.1", + "@opentelemetry/sdk-trace-web": "1.24.1", + "@opentelemetry/semantic-conventions": "1.24.1" }, "engines": { "node": ">=14" @@ -394,13 +405,13 @@ } }, "node_modules/@opentelemetry/instrumentation-http": { - "version": "0.48.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/instrumentation-http/-/instrumentation-http-0.48.0.tgz", - "integrity": "sha512-uXqOsLhW9WC3ZlGm6+PSX0xjSDTCfy4CMjfYj6TPWusOO8dtdx040trOriF24y+sZmS3M+5UQc6/3/ZxBJh4Mw==", + "version": "0.51.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/instrumentation-http/-/instrumentation-http-0.51.1.tgz", + "integrity": "sha512-6b3nZnFFEz/3xZ6w8bVxctPUWIPWiXuPQ725530JgxnN1cvYFd8CJ75PrHZNjynmzSSnqBkN3ef4R9N+RpMh8Q==", "dependencies": { - "@opentelemetry/core": "1.21.0", - "@opentelemetry/instrumentation": "0.48.0", - "@opentelemetry/semantic-conventions": "1.21.0", + "@opentelemetry/core": "1.24.1", + "@opentelemetry/instrumentation": "0.51.1", + "@opentelemetry/semantic-conventions": "1.24.1", "semver": "^7.5.2" }, "engines": { @@ -411,11 +422,11 @@ } }, "node_modules/@opentelemetry/instrumentation-pino": { - "version": "0.35.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/instrumentation-pino/-/instrumentation-pino-0.35.0.tgz", - "integrity": "sha512-gMfJ5Qy793mbaAGnQE3yp1Cb0y4np74rBPu20Oy/v8TTgPQOEV5PyNI0GNGggmZQIJSkdtYa8Ndb3huH3iZE5g==", + "version": "0.38.0", + "resolved": "https://registry.npmjs.org/@opentelemetry/instrumentation-pino/-/instrumentation-pino-0.38.0.tgz", + "integrity": "sha512-m4tkO+tuKv0zs2uLNxsMw06RwBNjHua8r9FYUlSlVcaF4EHTqC2XOk3h3OWw8HosZAvJvjryAgbEGuX9wJPn7A==", "dependencies": { - "@opentelemetry/instrumentation": "^0.48.0" + "@opentelemetry/instrumentation": "^0.51.0" }, "engines": { "node": ">=14" @@ -425,11 +436,11 @@ } }, "node_modules/@opentelemetry/otlp-exporter-base": { - "version": "0.48.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/otlp-exporter-base/-/otlp-exporter-base-0.48.0.tgz", - "integrity": "sha512-T4LJND+Ugl87GUONoyoQzuV9qCn4BFIPOnCH1biYqdGhc2JahjuLqVD9aefwLzGBW638iLAo88Lh68h2F1FLiA==", + "version": "0.51.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/otlp-exporter-base/-/otlp-exporter-base-0.51.1.tgz", + "integrity": "sha512-UYlnOYyDdzo1Gw559EHCzru0RwhvuXCwoH8jGo9J4gO1TE58GjnEmIjomMsKBCym3qWNJfIQXw+9SZCV0DdQNg==", "dependencies": { - "@opentelemetry/core": "1.21.0" + "@opentelemetry/core": "1.24.1" }, "engines": { "node": ">=14" @@ -439,13 +450,13 @@ } }, "node_modules/@opentelemetry/otlp-grpc-exporter-base": { - "version": "0.48.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/otlp-grpc-exporter-base/-/otlp-grpc-exporter-base-0.48.0.tgz", - "integrity": "sha512-Vdp56RK9OU+Oeoy3YQC/UMOWglKQ9qvgGr49FgF4r8vk5DlcTUgVS0m3KG8pykmRPA+5ZKaDuqwPw5aTvWmHFw==", + "version": "0.51.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/otlp-grpc-exporter-base/-/otlp-grpc-exporter-base-0.51.1.tgz", + "integrity": "sha512-ZAS+4pq8o7dsugGTwV9s6JMKSxi+guIHdn0acOv0bqj26e9pWDFx5Ky+bI0aY46uR9Y0JyXqY+KAEYM/SO3DFA==", "dependencies": { "@grpc/grpc-js": "^1.7.1", - "@opentelemetry/core": "1.21.0", - "@opentelemetry/otlp-exporter-base": "0.48.0", + "@opentelemetry/core": "1.24.1", + "@opentelemetry/otlp-exporter-base": "0.51.1", "protobufjs": "^7.2.3" }, "engines": { @@ -456,12 +467,12 @@ } }, "node_modules/@opentelemetry/otlp-proto-exporter-base": { - "version": "0.48.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/otlp-proto-exporter-base/-/otlp-proto-exporter-base-0.48.0.tgz", - "integrity": "sha512-14GSTvPZPfrWsB54fYMGb8v+Uge5xGXyz0r2rf4SzcRnO2hXCPHEuL3yyL50emaKPAY+fj29Dm0bweawe8UA6A==", + "version": "0.51.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/otlp-proto-exporter-base/-/otlp-proto-exporter-base-0.51.1.tgz", + "integrity": "sha512-gxxxwfk0inDMb5DLeuxQ3L8TtptxSiTNHE4nnAJH34IQXAVRhXSXW1rK8PmDKDngRPIZ6J7ncUCjjIn8b+AgqQ==", "dependencies": { - "@opentelemetry/core": "1.21.0", - "@opentelemetry/otlp-exporter-base": "0.48.0", + "@opentelemetry/core": "1.24.1", + "@opentelemetry/otlp-exporter-base": "0.51.1", "protobufjs": "^7.2.3" }, "engines": { @@ -472,180 +483,180 @@ } }, "node_modules/@opentelemetry/otlp-transformer": { - "version": "0.48.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/otlp-transformer/-/otlp-transformer-0.48.0.tgz", - "integrity": "sha512-yuoS4cUumaTK/hhxW3JUy3wl2U4keMo01cFDrUOmjloAdSSXvv1zyQ920IIH4lymp5Xd21Dj2/jq2LOro56TJg==", + "version": "0.51.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/otlp-transformer/-/otlp-transformer-0.51.1.tgz", + "integrity": "sha512-OppYOXwV9LQqqtYUCywqoOqX/JT9LQ5/FMuPZ//eTkvuHdUC4ZMwz2c6uSoT2R90GWvvGnF1iEqTGyTT3xAt2Q==", "dependencies": { - "@opentelemetry/api-logs": "0.48.0", - "@opentelemetry/core": "1.21.0", - "@opentelemetry/resources": "1.21.0", - "@opentelemetry/sdk-logs": "0.48.0", - "@opentelemetry/sdk-metrics": "1.21.0", - "@opentelemetry/sdk-trace-base": "1.21.0" + "@opentelemetry/api-logs": "0.51.1", + "@opentelemetry/core": "1.24.1", + "@opentelemetry/resources": "1.24.1", + "@opentelemetry/sdk-logs": "0.51.1", + "@opentelemetry/sdk-metrics": "1.24.1", + "@opentelemetry/sdk-trace-base": "1.24.1" }, "engines": { "node": ">=14" }, "peerDependencies": { - "@opentelemetry/api": ">=1.3.0 <1.8.0" + "@opentelemetry/api": ">=1.3.0 <1.9.0" } }, "node_modules/@opentelemetry/propagator-b3": { - "version": "1.21.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/propagator-b3/-/propagator-b3-1.21.0.tgz", - "integrity": "sha512-3ZTobj2VDIOzLsIvvYCdpw6tunxUVElPxDvog9lS49YX4hohHeD84A8u9Ns/6UYUcaN5GSoEf891lzhcBFiOLA==", + "version": "1.24.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/propagator-b3/-/propagator-b3-1.24.1.tgz", + "integrity": "sha512-nda97ZwhpZKyUJTXqQuKzNhPMUgMLunbbGWn8kroBwegn+nh6OhtyGkrVQsQLNdVKJl0KeB5z0ZgeWszrYhwFw==", "dependencies": { - "@opentelemetry/core": "1.21.0" + "@opentelemetry/core": "1.24.1" }, "engines": { "node": ">=14" }, "peerDependencies": { - "@opentelemetry/api": ">=1.0.0 <1.8.0" + "@opentelemetry/api": ">=1.0.0 <1.9.0" } }, "node_modules/@opentelemetry/propagator-jaeger": { - "version": "1.21.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/propagator-jaeger/-/propagator-jaeger-1.21.0.tgz", - "integrity": "sha512-8TQSwXjBmaDx7JkxRD7hdmBmRK2RGRgzHX1ArJfJhIc5trzlVweyorzqQrXOvqVEdEg+zxUMHkL5qbGH/HDTPA==", + "version": "1.24.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/propagator-jaeger/-/propagator-jaeger-1.24.1.tgz", + "integrity": "sha512-7bRBJn3FG1l195A1m+xXRHvgzAOBsfmRi9uZ5Da18oTh7BLmNDiA8+kpk51FpTsU1PCikPVpRDNPhKVB6lyzZg==", "dependencies": { - "@opentelemetry/core": "1.21.0" + "@opentelemetry/core": "1.24.1" }, "engines": { "node": ">=14" }, "peerDependencies": { - "@opentelemetry/api": ">=1.0.0 <1.8.0" + "@opentelemetry/api": ">=1.0.0 <1.9.0" } }, "node_modules/@opentelemetry/resources": { - "version": "1.21.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/resources/-/resources-1.21.0.tgz", - "integrity": "sha512-1Z86FUxPKL6zWVy2LdhueEGl9AHDJcx+bvHStxomruz6Whd02mE3lNUMjVJ+FGRoktx/xYQcxccYb03DiUP6Yw==", + "version": "1.24.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/resources/-/resources-1.24.1.tgz", + "integrity": "sha512-cyv0MwAaPF7O86x5hk3NNgenMObeejZFLJJDVuSeSMIsknlsj3oOZzRv3qSzlwYomXsICfBeFFlxwHQte5mGXQ==", "dependencies": { - "@opentelemetry/core": "1.21.0", - "@opentelemetry/semantic-conventions": "1.21.0" + "@opentelemetry/core": "1.24.1", + "@opentelemetry/semantic-conventions": "1.24.1" }, "engines": { "node": ">=14" }, "peerDependencies": { - "@opentelemetry/api": ">=1.0.0 <1.8.0" + "@opentelemetry/api": ">=1.0.0 <1.9.0" } }, "node_modules/@opentelemetry/sdk-logs": { - "version": "0.48.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/sdk-logs/-/sdk-logs-0.48.0.tgz", - "integrity": "sha512-lRcA5/qkSJuSh4ItWCddhdn/nNbVvnzM+cm9Fg1xpZUeTeozjJDBcHnmeKoOaWRnrGYBdz6UTY6bynZR9aBeAA==", + "version": "0.51.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/sdk-logs/-/sdk-logs-0.51.1.tgz", + "integrity": "sha512-ULQQtl82b673PpZc5/0EtH4V+BrwVOgKJZEB7tYZnGTG3I98tQVk89S9/JSixomDr++F4ih+LSJTCqIKBz+MQQ==", "dependencies": { - "@opentelemetry/core": "1.21.0", - "@opentelemetry/resources": "1.21.0" + "@opentelemetry/core": "1.24.1", + "@opentelemetry/resources": "1.24.1" }, "engines": { "node": ">=14" }, "peerDependencies": { - "@opentelemetry/api": ">=1.4.0 <1.8.0", + "@opentelemetry/api": ">=1.4.0 <1.9.0", "@opentelemetry/api-logs": ">=0.39.1" } }, "node_modules/@opentelemetry/sdk-metrics": { - "version": "1.21.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/sdk-metrics/-/sdk-metrics-1.21.0.tgz", - "integrity": "sha512-on1jTzIHc5DyWhRP+xpf+zrgrREXcHBH4EDAfaB5mIG7TWpKxNXooQ1JCylaPsswZUv4wGnVTinr4HrBdGARAQ==", + "version": "1.24.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/sdk-metrics/-/sdk-metrics-1.24.1.tgz", + "integrity": "sha512-FrAqCbbGao9iKI+Mgh+OsC9+U2YMoXnlDHe06yH7dvavCKzE3S892dGtX54+WhSFVxHR/TMRVJiK/CV93GR0TQ==", "dependencies": { - "@opentelemetry/core": "1.21.0", - "@opentelemetry/resources": "1.21.0", + "@opentelemetry/core": "1.24.1", + "@opentelemetry/resources": "1.24.1", "lodash.merge": "^4.6.2" }, "engines": { "node": ">=14" }, "peerDependencies": { - "@opentelemetry/api": ">=1.3.0 <1.8.0" + "@opentelemetry/api": ">=1.3.0 <1.9.0" } }, "node_modules/@opentelemetry/sdk-node": { - "version": "0.48.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/sdk-node/-/sdk-node-0.48.0.tgz", - "integrity": "sha512-3o3GS6t+VLGVFCV5bqfGOcWIgOdkR/UE6Qz7hHksP5PXrVBeYsPqts7cPma5YXweaI3r3h26mydg9PqQIcqksg==", - "dependencies": { - "@opentelemetry/api-logs": "0.48.0", - "@opentelemetry/core": "1.21.0", - "@opentelemetry/exporter-trace-otlp-grpc": "0.48.0", - "@opentelemetry/exporter-trace-otlp-http": "0.48.0", - "@opentelemetry/exporter-trace-otlp-proto": "0.48.0", - "@opentelemetry/exporter-zipkin": "1.21.0", - "@opentelemetry/instrumentation": "0.48.0", - "@opentelemetry/resources": "1.21.0", - "@opentelemetry/sdk-logs": "0.48.0", - "@opentelemetry/sdk-metrics": "1.21.0", - "@opentelemetry/sdk-trace-base": "1.21.0", - "@opentelemetry/sdk-trace-node": "1.21.0", - "@opentelemetry/semantic-conventions": "1.21.0" + "version": "0.51.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/sdk-node/-/sdk-node-0.51.1.tgz", + "integrity": "sha512-GgmNF9C+6esr8PIJxCqHw84rEOkYm6XdFWZ2+Wyc3qaUt92ACoN7uSw5iKNvaUq62W0xii1wsGxwHzyENtPP8w==", + "dependencies": { + "@opentelemetry/api-logs": "0.51.1", + "@opentelemetry/core": "1.24.1", + "@opentelemetry/exporter-trace-otlp-grpc": "0.51.1", + "@opentelemetry/exporter-trace-otlp-http": "0.51.1", + "@opentelemetry/exporter-trace-otlp-proto": "0.51.1", + "@opentelemetry/exporter-zipkin": "1.24.1", + "@opentelemetry/instrumentation": "0.51.1", + "@opentelemetry/resources": "1.24.1", + "@opentelemetry/sdk-logs": "0.51.1", + "@opentelemetry/sdk-metrics": "1.24.1", + "@opentelemetry/sdk-trace-base": "1.24.1", + "@opentelemetry/sdk-trace-node": "1.24.1", + "@opentelemetry/semantic-conventions": "1.24.1" }, "engines": { "node": ">=14" }, "peerDependencies": { - "@opentelemetry/api": ">=1.3.0 <1.8.0" + "@opentelemetry/api": ">=1.3.0 <1.9.0" } }, "node_modules/@opentelemetry/sdk-trace-base": { - "version": "1.21.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/sdk-trace-base/-/sdk-trace-base-1.21.0.tgz", - "integrity": "sha512-yrElGX5Fv0umzp8Nxpta/XqU71+jCAyaLk34GmBzNcrW43nqbrqvdPs4gj4MVy/HcTjr6hifCDCYA3rMkajxxA==", + "version": "1.24.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/sdk-trace-base/-/sdk-trace-base-1.24.1.tgz", + "integrity": "sha512-zz+N423IcySgjihl2NfjBf0qw1RWe11XIAWVrTNOSSI6dtSPJiVom2zipFB2AEEtJWpv0Iz6DY6+TjnyTV5pWg==", "dependencies": { - "@opentelemetry/core": "1.21.0", - "@opentelemetry/resources": "1.21.0", - "@opentelemetry/semantic-conventions": "1.21.0" + "@opentelemetry/core": "1.24.1", + "@opentelemetry/resources": "1.24.1", + "@opentelemetry/semantic-conventions": "1.24.1" }, "engines": { "node": ">=14" }, "peerDependencies": { - "@opentelemetry/api": ">=1.0.0 <1.8.0" + "@opentelemetry/api": ">=1.0.0 <1.9.0" } }, "node_modules/@opentelemetry/sdk-trace-node": { - "version": "1.21.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/sdk-trace-node/-/sdk-trace-node-1.21.0.tgz", - "integrity": "sha512-1pdm8jnqs+LuJ0Bvx6sNL28EhC8Rv7NYV8rnoXq3GIQo7uOHBDAFSj7makAfbakrla7ecO1FRfI8emnR4WvhYA==", - "dependencies": { - "@opentelemetry/context-async-hooks": "1.21.0", - "@opentelemetry/core": "1.21.0", - "@opentelemetry/propagator-b3": "1.21.0", - "@opentelemetry/propagator-jaeger": "1.21.0", - "@opentelemetry/sdk-trace-base": "1.21.0", + "version": "1.24.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/sdk-trace-node/-/sdk-trace-node-1.24.1.tgz", + "integrity": "sha512-/FZX8uWaGIAwsDhqI8VvQ+qWtfMNlXjaFYGc+vmxgdRFppCSSIRwrPyIhJO1qx61okyYhoyxVEZAfoiNxrfJCg==", + "dependencies": { + "@opentelemetry/context-async-hooks": "1.24.1", + "@opentelemetry/core": "1.24.1", + "@opentelemetry/propagator-b3": "1.24.1", + "@opentelemetry/propagator-jaeger": "1.24.1", + "@opentelemetry/sdk-trace-base": "1.24.1", "semver": "^7.5.2" }, "engines": { "node": ">=14" }, "peerDependencies": { - "@opentelemetry/api": ">=1.0.0 <1.8.0" + "@opentelemetry/api": ">=1.0.0 <1.9.0" } }, "node_modules/@opentelemetry/sdk-trace-web": { - "version": "1.21.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/sdk-trace-web/-/sdk-trace-web-1.21.0.tgz", - "integrity": "sha512-MxkmY/UNXkDiZj7JUu5T7wWt8Ai4NJEwSjGoQQ9YLvgLUIivvaIo9Mne+Q+KLOUG2v/uhivz3qzxbCODVa0c1A==", + "version": "1.24.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/sdk-trace-web/-/sdk-trace-web-1.24.1.tgz", + "integrity": "sha512-0w+aKRai9VREeo3VrtW+hcbrE2Fl/uKL7G+oXgRNf6pI9QLaEGuEzUTX+oxXVPBadzjOd+5dqCHYdX7UeVjzwA==", "dependencies": { - "@opentelemetry/core": "1.21.0", - "@opentelemetry/sdk-trace-base": "1.21.0", - "@opentelemetry/semantic-conventions": "1.21.0" + "@opentelemetry/core": "1.24.1", + "@opentelemetry/sdk-trace-base": "1.24.1", + "@opentelemetry/semantic-conventions": "1.24.1" }, "engines": { "node": ">=14" }, "peerDependencies": { - "@opentelemetry/api": ">=1.0.0 <1.8.0" + "@opentelemetry/api": ">=1.0.0 <1.9.0" } }, "node_modules/@opentelemetry/semantic-conventions": { - "version": "1.21.0", - "resolved": "https://registry.npmjs.org/@opentelemetry/semantic-conventions/-/semantic-conventions-1.21.0.tgz", - "integrity": "sha512-lkC8kZYntxVKr7b8xmjCVUgE0a8xgDakPyDo9uSWavXPyYqLgYYGdEd2j8NxihRyb6UwpX3G/hFUF4/9q2V+/g==", + "version": "1.24.1", + "resolved": "https://registry.npmjs.org/@opentelemetry/semantic-conventions/-/semantic-conventions-1.24.1.tgz", + "integrity": "sha512-VkliWlS4/+GHLLW7J/rVBA00uXus1SWvwFvcUDxDwmFxYfg/2VI6ekwdXS28cjI8Qz2ky2BzG8OUHo+WeYIWqw==", "engines": { "node": ">=14" } @@ -1008,10 +1019,10 @@ "node": ">=0.4.0" } }, - "node_modules/acorn-import-assertions": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/acorn-import-assertions/-/acorn-import-assertions-1.9.0.tgz", - "integrity": "sha512-cmMwop9x+8KFhxvKrKfPYmN6/pKTYYHBqLa0DfvVZcKMJWNyWLnaqND7dx/qn66R7ewM1UX5XMaDVP5wlVTaVA==", + "node_modules/acorn-import-attributes": { + "version": "1.9.5", + "resolved": "https://registry.npmjs.org/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz", + "integrity": "sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ==", "peerDependencies": { "acorn": "^8" } @@ -1173,6 +1184,11 @@ "node": ">=8" } }, + "node_modules/bintrees": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/bintrees/-/bintrees-1.0.2.tgz", + "integrity": "sha512-VOMgTMwjAaUG580SXn3LacVgjurrbMme7ZZNYGSSV7mmtY6QQRh0Eg3pwIcntQ77DErK1L0NxkbetjcoXzVwKw==" + }, "node_modules/brace-expansion": { "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", @@ -1345,9 +1361,9 @@ } }, "node_modules/cjs-module-lexer": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/cjs-module-lexer/-/cjs-module-lexer-1.2.3.tgz", - "integrity": "sha512-0TNiGstbQmCFwt4akjjBg5pLRTSyj/PkWQ1ZoO2zntmg9yLqSRxwEa4iCfQLGjqhiqBfOJa7W/E8wfGrTDmlZQ==" + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/cjs-module-lexer/-/cjs-module-lexer-1.3.1.tgz", + "integrity": "sha512-a3KdPAANPbNE4ZUv9h6LckSl9zLsYOP4MBmhIPkRaeyybt+r4UghLvq+xw/YwUcC1gqylCkL4rdVs3Lwupjm4Q==" }, "node_modules/cliui": { "version": "7.0.4", @@ -1814,12 +1830,12 @@ ] }, "node_modules/import-in-the-middle": { - "version": "1.7.1", - "resolved": "https://registry.npmjs.org/import-in-the-middle/-/import-in-the-middle-1.7.1.tgz", - "integrity": "sha512-1LrZPDtW+atAxH42S6288qyDFNQ2YCty+2mxEPRtfazH6Z5QwkaBSTS2ods7hnVJioF6rkRfNoA6A/MstpFXLg==", + "version": "1.7.4", + "resolved": "https://registry.npmjs.org/import-in-the-middle/-/import-in-the-middle-1.7.4.tgz", + "integrity": "sha512-Lk+qzWmiQuRPPulGQeK5qq0v32k2bHnWrRPFgqyvhw7Kkov5L6MOLOIU3pcWeujc9W4q54Cp3Q2WV16eQkc7Bg==", "dependencies": { "acorn": "^8.8.2", - "acorn-import-assertions": "^1.9.0", + "acorn-import-attributes": "^1.9.5", "cjs-module-lexer": "^1.2.2", "module-details-from-path": "^1.0.3" } @@ -2432,6 +2448,18 @@ "resolved": "https://registry.npmjs.org/process-warning/-/process-warning-3.0.0.tgz", "integrity": "sha512-mqn0kFRl0EoqhnL0GQ0veqFHyIN1yig9RHh/InzORTUiZHFRAur+aMtRkELNwGs9aNwKS6tg/An4NYBPGwvtzQ==" }, + "node_modules/prom-client": { + "version": "15.1.2", + "resolved": "https://registry.npmjs.org/prom-client/-/prom-client-15.1.2.tgz", + "integrity": "sha512-on3h1iXb04QFLLThrmVYg1SChBQ9N1c+nKAjebBjokBqipddH3uxmOUcEkTnzmJ8Jh/5TSUnUqS40i2QB2dJHQ==", + "dependencies": { + "@opentelemetry/api": "^1.4.0", + "tdigest": "^0.1.1" + }, + "engines": { + "node": "^16 || ^18 || >=20" + } + }, "node_modules/protobufjs": { "version": "7.2.6", "resolved": "https://registry.npmjs.org/protobufjs/-/protobufjs-7.2.6.tgz", @@ -2549,9 +2577,9 @@ } }, "node_modules/require-in-the-middle": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/require-in-the-middle/-/require-in-the-middle-7.2.0.tgz", - "integrity": "sha512-3TLx5TGyAY6AOqLBoXmHkNql0HIf2RGbuMgCDT2WO/uGVAPJs6h7Kl+bN6TIZGd9bWhWPwnDnTHGtW8Iu77sdw==", + "version": "7.3.0", + "resolved": "https://registry.npmjs.org/require-in-the-middle/-/require-in-the-middle-7.3.0.tgz", + "integrity": "sha512-nQFEv9gRw6SJAwWD2LrL0NmQvAcO7FBwJbwmr2ttPAacfy0xuiOjE5zt+zM4xDyuyvUaxBi/9gb2SoCyNEVJcw==", "dependencies": { "debug": "^4.1.1", "module-details-from-path": "^1.0.3", @@ -2821,6 +2849,14 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/tdigest": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/tdigest/-/tdigest-0.1.2.tgz", + "integrity": "sha512-+G0LLgjjo9BZX2MfdvPfH+MKLCrxlXSYec5DaPYP1fe6Iyhf0/fSmJ0bFiZ1F8BT6cGXl2LpltQptzjXKWEkKA==", + "dependencies": { + "bintrees": "1.0.2" + } + }, "node_modules/thread-stream": { "version": "2.4.1", "resolved": "https://registry.npmjs.org/thread-stream/-/thread-stream-2.4.1.tgz", diff --git a/ndc-lambda-sdk/package.json b/ndc-lambda-sdk/package.json index a90895f..49cb56e 100644 --- a/ndc-lambda-sdk/package.json +++ b/ndc-lambda-sdk/package.json @@ -1,6 +1,6 @@ { "name": "@hasura/ndc-lambda-sdk", - "version": "1.3.0", + "version": "1.4.0", "description": "SDK that can automatically expose TypeScript functions as Hasura NDC functions/procedures", "author": "Hasura", "license": "Apache-2.0", @@ -30,7 +30,7 @@ "url": "git+https://github.com/hasura/ndc-nodejs-lambda.git" }, "dependencies": { - "@hasura/ndc-sdk-typescript": "^4.5.0", + "@hasura/ndc-sdk-typescript": "^4.6.0", "@tsconfig/node20": "^20.1.3", "commander": "^11.1.0", "cross-spawn": "^7.0.3", diff --git a/ndc-lambda-sdk/src/inference.ts b/ndc-lambda-sdk/src/inference.ts index d032d48..5ad82d7 100644 --- a/ndc-lambda-sdk/src/inference.ts +++ b/ndc-lambda-sdk/src/inference.ts @@ -278,14 +278,9 @@ function getParallelDegreeFromJsDoc(functionSymbol: ts.Symbol, functionIsReadonl } } -const MAX_TYPE_DERIVATION_RECURSION = 20; // Better to abort than get into an infinite loop, this could be increased if required. - -function deriveSchemaTypeForTsType(tsType: ts.Type, typeSource: TypeSource, typePath: schema.TypePathSegment[], allowRelaxedTypes: boolean, context: TypeDerivationContext, recursionDepth: number = 0): Result { +function deriveSchemaTypeForTsType(tsType: ts.Type, typeSource: TypeSource, typePath: schema.TypePathSegment[], allowRelaxedTypes: boolean, context: TypeDerivationContext): Result { const typeRenderedName = context.typeChecker.typeToString(tsType); - if (recursionDepth > MAX_TYPE_DERIVATION_RECURSION) - throw new Error(`Schema inference validation exceeded depth ${MAX_TYPE_DERIVATION_RECURSION} for type ${typeRenderedName}`) - if (unwrapPromiseType(tsType, context.typeChecker) !== undefined) { return new Err([`Promise types are not supported, but one was encountered in ${schema.typePathToString(typePath)}.`]); } @@ -320,15 +315,15 @@ function deriveSchemaTypeForTsType(tsType: ts.Type, typeSource: TypeSource, type const schemaTypeResult = deriveSchemaTypeIfTsUnknownOrAny(tsType, typeSource, typePath, allowRelaxedTypes, context) - ?? deriveSchemaTypeIfTsTupleType(tsType, typeSource, typePath, allowRelaxedTypes, context, recursionDepth) - ?? deriveSchemaTypeIfTsArrayType(tsType, typeSource, typePath, allowRelaxedTypes, context, recursionDepth) + ?? deriveSchemaTypeIfTsTupleType(tsType, typeSource, typePath, allowRelaxedTypes, context) + ?? deriveSchemaTypeIfTsArrayType(tsType, typeSource, typePath, allowRelaxedTypes, context) ?? deriveSchemaTypeIfBuiltInScalarType(tsType, context) - ?? deriveSchemaTypeIfNullableType(tsType, typeSource, typePath, allowRelaxedTypes, context, recursionDepth) + ?? deriveSchemaTypeIfNullableType(tsType, typeSource, typePath, allowRelaxedTypes, context) ?? deriveSchemaTypeIfEnumType(tsType, typeSource, typePath, allowRelaxedTypes, context) - ?? deriveSchemaTypeIfObjectType(tsType, typeSource, typePath, allowRelaxedTypes, context, recursionDepth) + ?? deriveSchemaTypeIfObjectType(tsType, typeSource, typePath, allowRelaxedTypes, context) ?? rejectIfClassType(tsType, typePath, context) // This needs to be done after scalars, because JSONValue is a class - ?? deriveSchemaTypeIfTsIndexSignatureType(tsType, typeSource, typePath, allowRelaxedTypes, context, recursionDepth) // This needs to be done after scalars and classes, etc because some of those types do have index signatures (eg. strings) - ?? deriveSchemaTypeIfTsUnionType(tsType, typeSource, typePath, allowRelaxedTypes, context, recursionDepth); // This needs to be done after nullable types, since nullable types use unions, this catches everything else + ?? deriveSchemaTypeIfTsIndexSignatureType(tsType, typeSource, typePath, allowRelaxedTypes, context) // This needs to be done after scalars and classes, etc because some of those types do have index signatures (eg. strings) + ?? deriveSchemaTypeIfTsUnionType(tsType, typeSource, typePath, allowRelaxedTypes, context); // This needs to be done after nullable types, since nullable types use unions, this catches everything else if (schemaTypeResult !== undefined) return schemaTypeResult; @@ -368,7 +363,7 @@ function deriveSchemaTypeIfTsUnknownOrAny(tsType: ts.Type, typeSource: TypeSourc } } -function deriveSchemaTypeIfTsTupleType(tsType: ts.Type, typeSource: TypeSource, typePath: schema.TypePathSegment[], allowRelaxedTypes: boolean, context: TypeDerivationContext, recursionDepth: number): Result | undefined { +function deriveSchemaTypeIfTsTupleType(tsType: ts.Type, typeSource: TypeSource, typePath: schema.TypePathSegment[], allowRelaxedTypes: boolean, context: TypeDerivationContext): Result | undefined { if (tsutils.isTupleTypeReference(tsType)) { const typeName = context.typeChecker.typeToString(tsType); @@ -376,7 +371,7 @@ function deriveSchemaTypeIfTsTupleType(tsType: ts.Type, typeSource: TypeSource, // Verify types in tuple are valid types const isolatedContext = cloneTypeDerivationContext(context); // Use an isolated context so we don't actually record any new scalar or object types while doing this, since this is going to end up as a relaxed type anyway const result = Result.traverseAndCollectErrors(tsType.typeArguments ?? [], (typeParameterTsType: ts.Type, index: number) => { - return deriveSchemaTypeForTsType(typeParameterTsType, typeSource, [...typePath, {segmentType: "TypeParameter", typeName, index}], allowRelaxedTypes, isolatedContext, recursionDepth + 1); + return deriveSchemaTypeForTsType(typeParameterTsType, typeSource, [...typePath, {segmentType: "TypeParameter", typeName, index}], allowRelaxedTypes, isolatedContext); }); if (result instanceof Err) return new Err(result.error); @@ -393,7 +388,7 @@ function rejectIfClassType(tsType: ts.Type, typePath: schema.TypePathSegment[], } // Types with index signatures: ie '[x: T]: Y' -function deriveSchemaTypeIfTsIndexSignatureType(tsType: ts.Type, typeSource: TypeSource, typePath: schema.TypePathSegment[], allowRelaxedTypes: boolean, context: TypeDerivationContext, recursionDepth: number): Result | undefined { +function deriveSchemaTypeIfTsIndexSignatureType(tsType: ts.Type, typeSource: TypeSource, typePath: schema.TypePathSegment[], allowRelaxedTypes: boolean, context: TypeDerivationContext): Result | undefined { const indexInfos = context.typeChecker.getIndexInfosOfType(tsType); if (indexInfos.length > 0) { const typeName = context.typeChecker.typeToString(tsType); @@ -406,7 +401,7 @@ function deriveSchemaTypeIfTsIndexSignatureType(tsType: ts.Type, typeSource: Typ [indexInfo.type, { segmentType: "IndexSignature", typeName, sigIndex, component: "value" }], ]); const result = Result.traverseAndCollectErrors(indexSignatureTypes, ([sigType, typePathSegment]) => { - return deriveSchemaTypeForTsType(sigType, typeSource, [...typePath, typePathSegment], allowRelaxedTypes, isolatedContext, recursionDepth + 1); + return deriveSchemaTypeForTsType(sigType, typeSource, [...typePath, typePathSegment], allowRelaxedTypes, isolatedContext); }); if (result instanceof Err) return new Err(result.error); @@ -416,7 +411,7 @@ function deriveSchemaTypeIfTsIndexSignatureType(tsType: ts.Type, typeSource: Typ } } -function deriveSchemaTypeIfTsUnionType(tsType: ts.Type, typeSource: TypeSource, typePath: schema.TypePathSegment[], allowRelaxedTypes: boolean, context: TypeDerivationContext, recursionDepth: number): Result | undefined { +function deriveSchemaTypeIfTsUnionType(tsType: ts.Type, typeSource: TypeSource, typePath: schema.TypePathSegment[], allowRelaxedTypes: boolean, context: TypeDerivationContext): Result | undefined { if (tsType.isUnion()) { const typeName = context.typeChecker.typeToString(tsType); @@ -424,7 +419,7 @@ function deriveSchemaTypeIfTsUnionType(tsType: ts.Type, typeSource: TypeSource, // Verify union options are valid types const isolatedContext = cloneTypeDerivationContext(context); // Use an isolated context so we don't actually record any new scalar or object types while doing this, since this is going to end up as a relaxed type anyway const result = Result.traverseAndCollectErrors(tsType.types, (memberTsType: ts.Type, memberIndex: number) => { - return deriveSchemaTypeForTsType(memberTsType, typeSource, [...typePath, {segmentType: "UnionMember", typeName, memberIndex}], allowRelaxedTypes, isolatedContext, recursionDepth + 1); + return deriveSchemaTypeForTsType(memberTsType, typeSource, [...typePath, {segmentType: "UnionMember", typeName, memberIndex}], allowRelaxedTypes, isolatedContext); }); if (result instanceof Err) return new Err(result.error); @@ -434,12 +429,12 @@ function deriveSchemaTypeIfTsUnionType(tsType: ts.Type, typeSource: TypeSource, } } -function deriveSchemaTypeIfTsArrayType(tsType: ts.Type, typeSource: TypeSource, typePath: schema.TypePathSegment[], allowRelaxedTypes: boolean, context: TypeDerivationContext, recursionDepth: number): Result | undefined { +function deriveSchemaTypeIfTsArrayType(tsType: ts.Type, typeSource: TypeSource, typePath: schema.TypePathSegment[], allowRelaxedTypes: boolean, context: TypeDerivationContext): Result | undefined { if (context.typeChecker.isArrayType(tsType) && tsutils.isTypeReference(tsType)) { const typeArgs = context.typeChecker.getTypeArguments(tsType) if (typeArgs.length === 1) { const innerType = typeArgs[0]!; - return deriveSchemaTypeForTsType(innerType, typeSource, [...typePath, {segmentType: "Array"}], allowRelaxedTypes, context, recursionDepth + 1) + return deriveSchemaTypeForTsType(innerType, typeSource, [...typePath, {segmentType: "Array"}], allowRelaxedTypes, context) .map(innerType => ({ type: "array", elementType: innerType })); } } @@ -556,16 +551,16 @@ function isJSONValueType(tsType: ts.Type, ndcLambdaSdkModule: ts.ResolvedModuleF return sourceFile.fileName.startsWith(sdkDirectory); } -function deriveSchemaTypeIfNullableType(tsType: ts.Type, typeSource: TypeSource, typePath: schema.TypePathSegment[], allowRelaxedTypes: boolean, context: TypeDerivationContext, recursionDepth: number): Result | undefined { +function deriveSchemaTypeIfNullableType(tsType: ts.Type, typeSource: TypeSource, typePath: schema.TypePathSegment[], allowRelaxedTypes: boolean, context: TypeDerivationContext): Result | undefined { const notNullableResult = unwrapNullableType(tsType, context.typeChecker); if (notNullableResult !== null) { const [notNullableType, nullOrUndefinability] = notNullableResult; - return deriveSchemaTypeForTsType(notNullableType, typeSource, typePath, allowRelaxedTypes, context, recursionDepth + 1) + return deriveSchemaTypeForTsType(notNullableType, typeSource, typePath, allowRelaxedTypes, context) .map(notNullableType => ({ type: "nullable", underlyingType: notNullableType, nullOrUndefinability })) } } -function deriveSchemaTypeIfObjectType(tsType: ts.Type, typeSource: TypeSource, typePath: schema.TypePathSegment[], allowRelaxedTypes: boolean, context: TypeDerivationContext, recursionDepth: number): Result | undefined { +function deriveSchemaTypeIfObjectType(tsType: ts.Type, typeSource: TypeSource, typePath: schema.TypePathSegment[], allowRelaxedTypes: boolean, context: TypeDerivationContext): Result | undefined { const info = getObjectTypeInfo(tsType, typeSource, typePath, context.typeChecker); if (info) { const makeRelaxedTypesError : () => Result = () => new Err([`The object type '${info.preferredTypeName}' uses relaxed types and can only be used by a function marked with @allowrelaxedtypes. It was encountered in ${schema.typePathToString(typePath)}`]); @@ -586,7 +581,7 @@ function deriveSchemaTypeIfObjectType(tsType: ts.Type, typeSource: TypeSource, t propertyInfo.tsType, { type: "Symbol", symbol: propertyInfo.symbol }, [...typePath, { segmentType: "ObjectProperty", typeName: context.typeChecker.typeToString(tsType), preferredTypeName: info.preferredTypeName, propertyName }], - allowRelaxedTypes, context, recursionDepth + 1 + allowRelaxedTypes, context ) .map(propertyType => ({ propertyName: propertyName, type: propertyType, description: propertyInfo.description })); }) diff --git a/yeoman-generator/package-lock.json b/yeoman-generator/package-lock.json index 0ec7a9a..cb0fb13 100644 --- a/yeoman-generator/package-lock.json +++ b/yeoman-generator/package-lock.json @@ -1,12 +1,12 @@ { "name": "generator-hasura-ndc-nodejs-lambda", - "version": "1.3.0", + "version": "1.4.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "generator-hasura-ndc-nodejs-lambda", - "version": "1.3.0", + "version": "1.4.0", "dependencies": { "pacote": "^17.0.5", "semver": "^7.5.4", diff --git a/yeoman-generator/package.json b/yeoman-generator/package.json index 88393a4..ce131eb 100644 --- a/yeoman-generator/package.json +++ b/yeoman-generator/package.json @@ -1,6 +1,6 @@ { "name": "generator-hasura-ndc-nodejs-lambda", - "version": "1.3.0", + "version": "1.4.0", "description": "Yeoman generator for Hasura DDN ndc-nodejs-lambda connectors", "files": [ "generators"