@aws-sdk/middleware-endpoint-discovery 3.32.0 → 3.36.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.
- package/CHANGELOG.md +38 -0
- package/dist-cjs/configurations.js +30 -0
- package/dist-cjs/endpointDiscoveryMiddleware.js +48 -0
- package/dist-cjs/getCacheKey.js +17 -0
- package/dist-cjs/getEndpointDiscoveryPlugin.js +28 -0
- package/dist-cjs/index.js +6 -0
- package/dist-cjs/resolveEndpointDiscoveryConfig.js +17 -0
- package/dist-cjs/updateDiscoveredEndpointInCache.js +64 -0
- package/dist-es/configurations.js +27 -0
- package/dist-es/endpointDiscoveryMiddleware.js +54 -0
- package/dist-es/getCacheKey.js +22 -0
- package/dist-es/getEndpointDiscoveryPlugin.js +23 -0
- package/{dist/types/index.d.ts → dist-es/index.js} +0 -0
- package/dist-es/resolveEndpointDiscoveryConfig.js +9 -0
- package/dist-es/updateDiscoveredEndpointInCache.js +67 -0
- package/{dist/types → dist-types}/configurations.d.ts +0 -0
- package/{dist/types → dist-types}/endpointDiscoveryMiddleware.d.ts +0 -0
- package/{dist/types → dist-types}/getCacheKey.d.ts +0 -0
- package/{dist/types → dist-types}/getEndpointDiscoveryPlugin.d.ts +0 -0
- package/{src/index.ts → dist-types/index.d.ts} +0 -0
- package/{dist/types → dist-types}/resolveEndpointDiscoveryConfig.d.ts +0 -0
- package/{dist/types → dist-types}/ts3.4/configurations.d.ts +0 -0
- package/{dist/types → dist-types}/ts3.4/endpointDiscoveryMiddleware.d.ts +0 -0
- package/{dist/types → dist-types}/ts3.4/getCacheKey.d.ts +0 -0
- package/{dist/types → dist-types}/ts3.4/getEndpointDiscoveryPlugin.d.ts +0 -0
- package/{dist/types → dist-types}/ts3.4/index.d.ts +0 -0
- package/{dist/types → dist-types}/ts3.4/resolveEndpointDiscoveryConfig.d.ts +0 -0
- package/{dist/types → dist-types}/ts3.4/updateDiscoveredEndpointInCache.d.ts +0 -0
- package/{dist/types → dist-types}/updateDiscoveredEndpointInCache.d.ts +0 -0
- package/package.json +17 -13
- package/dist/cjs/configurations.js +0 -32
- package/dist/cjs/endpointDiscoveryMiddleware.js +0 -55
- package/dist/cjs/getCacheKey.js +0 -21
- package/dist/cjs/getEndpointDiscoveryPlugin.js +0 -35
- package/dist/cjs/index.js +0 -7
- package/dist/cjs/resolveEndpointDiscoveryConfig.js +0 -18
- package/dist/cjs/updateDiscoveredEndpointInCache.js +0 -74
- package/dist/es/configurations.js +0 -29
- package/dist/es/endpointDiscoveryMiddleware.js +0 -63
- package/dist/es/getCacheKey.js +0 -26
- package/dist/es/getEndpointDiscoveryPlugin.js +0 -30
- package/dist/es/index.js +0 -4
- package/dist/es/resolveEndpointDiscoveryConfig.js +0 -10
- package/dist/es/updateDiscoveredEndpointInCache.js +0 -77
- package/dist/tsconfig.cjs.tsbuildinfo +0 -1
- package/dist/tsconfig.es.tsbuildinfo +0 -1
- package/jest.config.js +0 -5
- package/src/configurations.spec.ts +0 -85
- package/src/configurations.ts +0 -32
- package/src/endpointDiscoveryMiddleware.spec.ts +0 -145
- package/src/endpointDiscoveryMiddleware.ts +0 -72
- package/src/getCacheKey.spec.ts +0 -32
- package/src/getCacheKey.ts +0 -24
- package/src/getEndpointDiscoveryPlugin.spec.ts +0 -32
- package/src/getEndpointDiscoveryPlugin.ts +0 -57
- package/src/resolveEndpointDiscoveryConfig.spec.ts +0 -63
- package/src/resolveEndpointDiscoveryConfig.ts +0 -73
- package/src/updateDiscoveredEndpointInCache.spec.ts +0 -172
- package/src/updateDiscoveredEndpointInCache.ts +0 -88
- package/tsconfig.cjs.json +0 -10
- package/tsconfig.es.json +0 -11
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"program":{"fileNames":["../../../node_modules/typescript/lib/lib.es5.d.ts","../../../node_modules/typescript/lib/lib.es2015.d.ts","../../../node_modules/typescript/lib/lib.es2016.d.ts","../../../node_modules/typescript/lib/lib.es2017.d.ts","../../../node_modules/typescript/lib/lib.es2018.d.ts","../../../node_modules/typescript/lib/lib.dom.d.ts","../../../node_modules/typescript/lib/lib.es2015.core.d.ts","../../../node_modules/typescript/lib/lib.es2015.collection.d.ts","../../../node_modules/typescript/lib/lib.es2015.generator.d.ts","../../../node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../../node_modules/typescript/lib/lib.es2015.promise.d.ts","../../../node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../../node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../../node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../../node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../../node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../../node_modules/typescript/lib/lib.es2017.object.d.ts","../../../node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../../node_modules/typescript/lib/lib.es2017.string.d.ts","../../../node_modules/typescript/lib/lib.es2017.intl.d.ts","../../../node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../../node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../../node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../../node_modules/typescript/lib/lib.es2018.intl.d.ts","../../../node_modules/typescript/lib/lib.es2018.promise.d.ts","../../../node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../../node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../../node_modules/typescript/lib/lib.esnext.intl.d.ts","../../../node_modules/tslib/tslib.d.ts","../../types/dist/types/abort.d.ts","../../types/dist/types/logger.d.ts","../../types/dist/types/http.d.ts","../../types/dist/types/response.d.ts","../../types/dist/types/util.d.ts","../../types/dist/types/middleware.d.ts","../../types/dist/types/command.d.ts","../../types/dist/types/client.d.ts","../../types/dist/types/credentials.d.ts","../../types/dist/types/crypto.d.ts","../../types/dist/types/eventStream.d.ts","../../types/dist/types/pagination.d.ts","../../types/dist/types/transfer.d.ts","../../types/dist/types/serde.d.ts","../../types/dist/types/shapes.d.ts","../../types/dist/types/signature.d.ts","../../types/dist/types/waiter.d.ts","../../types/dist/types/index.d.ts","../../../node_modules/@types/node/globals.d.ts","../../../node_modules/@types/node/async_hooks.d.ts","../../../node_modules/@types/node/buffer.d.ts","../../../node_modules/@types/node/child_process.d.ts","../../../node_modules/@types/node/cluster.d.ts","../../../node_modules/@types/node/console.d.ts","../../../node_modules/@types/node/constants.d.ts","../../../node_modules/@types/node/crypto.d.ts","../../../node_modules/@types/node/dgram.d.ts","../../../node_modules/@types/node/dns.d.ts","../../../node_modules/@types/node/domain.d.ts","../../../node_modules/@types/node/events.d.ts","../../../node_modules/@types/node/fs.d.ts","../../../node_modules/@types/node/http.d.ts","../../../node_modules/@types/node/http2.d.ts","../../../node_modules/@types/node/https.d.ts","../../../node_modules/@types/node/inspector.d.ts","../../../node_modules/@types/node/module.d.ts","../../../node_modules/@types/node/net.d.ts","../../../node_modules/@types/node/os.d.ts","../../../node_modules/@types/node/path.d.ts","../../../node_modules/@types/node/perf_hooks.d.ts","../../../node_modules/@types/node/process.d.ts","../../../node_modules/@types/node/punycode.d.ts","../../../node_modules/@types/node/querystring.d.ts","../../../node_modules/@types/node/readline.d.ts","../../../node_modules/@types/node/repl.d.ts","../../../node_modules/@types/node/stream.d.ts","../../../node_modules/@types/node/string_decoder.d.ts","../../../node_modules/@types/node/timers.d.ts","../../../node_modules/@types/node/tls.d.ts","../../../node_modules/@types/node/trace_events.d.ts","../../../node_modules/@types/node/tty.d.ts","../../../node_modules/@types/node/url.d.ts","../../../node_modules/@types/node/util.d.ts","../../../node_modules/@types/node/v8.d.ts","../../../node_modules/@types/node/vm.d.ts","../../../node_modules/@types/node/worker_threads.d.ts","../../../node_modules/@types/node/zlib.d.ts","../../../node_modules/@types/node/globals.global.d.ts","../../../node_modules/@types/node/wasi.d.ts","../../../node_modules/@types/node/ts3.6/base.d.ts","../../../node_modules/@types/node/assert.d.ts","../../../node_modules/@types/node/base.d.ts","../../../node_modules/@types/node/index.d.ts","../../node-config-provider/dist/types/fromEnv.d.ts","../../shared-ini-file-loader/dist/types/index.d.ts","../../node-config-provider/dist/types/fromSharedConfigFiles.d.ts","../../node-config-provider/dist/types/fromStatic.d.ts","../../node-config-provider/dist/types/configLoader.d.ts","../../node-config-provider/dist/types/index.d.ts","../src/configurations.ts","../../protocol-http/dist/types/httpResponse.d.ts","../../protocol-http/dist/types/httpRequest.d.ts","../../protocol-http/dist/types/httpHandler.d.ts","../../protocol-http/dist/types/isValidHostname.d.ts","../../protocol-http/dist/types/index.d.ts","../src/getCacheKey.ts","../../endpoint-cache/dist/types/Endpoint.d.ts","../../endpoint-cache/dist/types/EndpointCache.d.ts","../../endpoint-cache/dist/types/index.d.ts","../src/resolveEndpointDiscoveryConfig.ts","../src/getEndpointDiscoveryPlugin.ts","../src/updateDiscoveredEndpointInCache.ts","../src/endpointDiscoveryMiddleware.ts","../src/index.ts","../../../node_modules/@babel/types/lib/index.d.ts","../../../node_modules/@types/babel__generator/index.d.ts","../../../node_modules/@babel/parser/typings/babel-parser.d.ts","../../../node_modules/@types/babel__template/index.d.ts","../../../node_modules/@types/babel__traverse/index.d.ts","../../../node_modules/@types/babel__core/index.d.ts","../../../node_modules/@types/chai/index.d.ts","../../../node_modules/@types/chai-as-promised/index.d.ts","../../../node_modules/@types/fs-extra/index.d.ts","../../../node_modules/@types/minimatch/index.d.ts","../../../node_modules/@types/glob/index.d.ts","../../../node_modules/@types/graceful-fs/index.d.ts","../../../node_modules/@types/istanbul-lib-coverage/index.d.ts","../../../node_modules/@types/istanbul-lib-report/index.d.ts","../../../node_modules/@types/istanbul-reports/index.d.ts","../../../node_modules/jest-diff/build/cleanupSemantic.d.ts","../../../node_modules/jest-diff/build/types.d.ts","../../../node_modules/jest-diff/build/diffLines.d.ts","../../../node_modules/jest-diff/build/printDiffs.d.ts","../../../node_modules/jest-diff/build/index.d.ts","../../../node_modules/pretty-format/build/types.d.ts","../../../node_modules/pretty-format/build/index.d.ts","../../../node_modules/@types/jest/index.d.ts","../../../node_modules/@types/json-schema/index.d.ts","../../../node_modules/@types/minimist/index.d.ts","../../../node_modules/@types/normalize-package-data/index.d.ts","../../../node_modules/@types/parse-json/index.d.ts","../../../node_modules/@types/prettier/index.d.ts","../../../node_modules/@types/stack-utils/index.d.ts","../../../node_modules/@types/uuid/index.d.ts","../../../node_modules/@types/yargs-parser/index.d.ts","../../../node_modules/@types/yargs/index.d.ts","../../../node_modules/@types/yauzl/index.d.ts"],"fileInfos":[{"version":"ac3a8c4040e183ce38da69d23b96939112457d1936198e6542672b7963cf0fce","affectsGlobalScope":true},"dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6","7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467","8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9","5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06",{"version":"1dad4fe1561d99dfd6709127608b99a76e5c2643626c800434f99c48038567ee","affectsGlobalScope":true},{"version":"cce43d02223f8049864f8568bed322c39424013275cd3bcc3f51492d8b546cb3","affectsGlobalScope":true},{"version":"43fb1d932e4966a39a41b464a12a81899d9ae5f2c829063f5571b6b87e6d2f9c","affectsGlobalScope":true},{"version":"cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a","affectsGlobalScope":true},{"version":"8dff1b4c2df638fcd976cbb0e636f23ab5968e836cd45084cc31d47d1ab19c49","affectsGlobalScope":true},{"version":"2bb4b3927299434052b37851a47bf5c39764f2ba88a888a107b32262e9292b7c","affectsGlobalScope":true},{"version":"810627a82ac06fb5166da5ada4159c4ec11978dfbb0805fe804c86406dab8357","affectsGlobalScope":true},{"version":"62d80405c46c3f4c527ee657ae9d43fda65a0bf582292429aea1e69144a522a6","affectsGlobalScope":true},{"version":"3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93","affectsGlobalScope":true},{"version":"8f4c9f651c8294a2eb1cbd12581fe25bfb901ab1d474bb93cd38c7e2f4be7a30","affectsGlobalScope":true},{"version":"3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006","affectsGlobalScope":true},{"version":"17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a","affectsGlobalScope":true},{"version":"7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98","affectsGlobalScope":true},{"version":"6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577","affectsGlobalScope":true},{"version":"12a310447c5d23c7d0d5ca2af606e3bd08afda69100166730ab92c62999ebb9d","affectsGlobalScope":true},{"version":"b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e","affectsGlobalScope":true},{"version":"0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a","affectsGlobalScope":true},{"version":"da233fc1c8a377ba9e0bed690a73c290d843c2c3d23a7bd7ec5cd3d7d73ba1e0","affectsGlobalScope":true},{"version":"df9c8a72ca8b0ed62f5470b41208a0587f0f73f0a7db28e5a1272cf92537518e","affectsGlobalScope":true},{"version":"bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c","affectsGlobalScope":true},{"version":"c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8","affectsGlobalScope":true},{"version":"60761e6ea886034af0f294f025a7199360ce4e2c8ba4ec6408bc049cf9b89799","affectsGlobalScope":true},{"version":"506b80b9951c9381dc5f11897b31fca5e2a65731d96ddefa19687fbc26b23c6e","affectsGlobalScope":true},"12f4cfe2fe60b810c3174537bc2ddb20c1067b7768643d12cb1266fd183afb75","4f1034eac6404cb69bedb8bb04cf246871d1aaebbb99d5617be54f54323464c7","724eb35fdcfa2ad686611b3a8a9d704ad0d478539a8cf0089176e0b8047f7190","d71be3ec7ca8cf9aaf6a8b68653dd3b7d988678edc120a640fc0307967486cc5","2e04271499caec54dea75e7061de06b2549efbe1d652b9bdab2f74fd2572f61f","40b990c27c58cf6d4473c9cdc65daf0428cbfca5cf4b072c73a4ad5a4055ea7f","0b2fe702dda65d25d5e00ec95fc8952036e7e75870c376abeb2cd2150b0a3bed","a9367ec48d3b67800c69c890e616337935df67caad5bff99383949af561042a8","5c1a8d6754a7cceee2135728e8ce6a4f984966a2d16ff1cbed879f7527d55864","a99add785a8a06f19582501ca19e92949f6b840b3f91d880e73582c5efacccde","5a7bb8afd0a22b7754275793f5ca5aeea379a2aad6153a6d68af49a60a899f69","a604c1ae24a48ccdb36396f49a20677d32722f8fd461dfb47186a5b12fd88d60","259c58ced9d80f66a61362a8768529a2746a2bc80183cdb04726f610913bb5d5","b14456a54e15ce24ff9e5ad3b70675b104a36eb35886e3ffaae614292c0908c4","ed01aa50ff4fdbf0f6857596fc385587d87da4896c7980ea75527e098031c488","9e5aef3efc63316ce7aa61b137d354449f792ab92885d03c8894b239db75d90a","8a6c15bfa2a0a9e68005a53fb71b60f3769af0da81001b95e4861310e260b788","aaffeca0d82a3d862c5186af3ca707801e45cc8b2e7d31e430eb715648ffa839","aedcac717f286d9925f0c52aa6165f4e91a2ed05ad9c1e2a8cc91eca18b8eb2b",{"version":"f7be6b47e03c43fa3ad1224b4fd995f3fd35bb29f0c2da5843c9dc04f4162fb3","affectsGlobalScope":true},"0829c48316ebcd238419d1ba2f142c866fe064a2452b449197dc85a9f43a3612","e63d5487b6d47f8abcbfdc3af9450d56118041805dd043febd249af0502dc9b1","5f505b075956d1c7db95d14e2e7a27d4e4a9d1ffc34b83b8273c51b074d575bd","458d55b08da524f900192dafb5837fcc2471cb59c0c149eea4754c180f943473","65409a1cc0ce6d0e4bc9a4dfd35e7df27b8b2646c9055230fdbb03f694b0cc88","e9339a66a8c672260b9c6b727f6d818c42a8d13bade07dfaf907103928e3c456","51d9197446e865a6919a2f217f4d0ad19f77483e5c7f2ebc520de4dc416dc5a3","b39ae9f0d9d0bdcde86891b047ac912602a59fa188c1d2c4bc201fc7c86cfaa9","f8a7a6d7af6267022984c5604ec31c4539fea5cb749e63ff3a0cf8a42fd19603","6570493ff2552919da1e6480f20d0b623b8007343a777922fca7788b6ce85ea1","d42d0bfd355a4f9f247789676137aec627d0b23122452c388a6c1a83105ae811","5efce49fe6c5e6c7211f4cfb93724adc1cf5783c63d608dca8cb61bfcbee29e6","bb05e8566a80f6e42df974e7523744b0af66aa9fafc721022156b202276c480e","9771ae64c7390ee98639ac79e9fb37b87a17de52b4bb705d48c9fc67af429e64","1939c52bd6e3fe0c5beacd7f5762f9847e86861059685fbdf471bd8afaf87944","d4fa2c2de99b1f4ff83aba4732c33fff918bf5869c04674aa2bfe927adfbd386","9cd5d57333119af9861227e2415a944d23ae7fa67706ac60a4c9a5cfde0a5a05","cf36f4557f363a203e39329aba07cc2f916ae181b4f71c61814db2e9ca6ca30c","b0d1073a8fbdd7b36fd048d82b1f148ce161ed54569a4b4b43007733ee643fff","311f6a6b6c05d334c29eb795d765bfbb596bb43a78fcb72bc23a6121eefb3924","b76f9cfe8fdfe10bb5ab1b540ea866771b89bb0e0acafbe119c9c8cbe398c092",{"version":"7e56a8722b9aeae9496e1278539f1b7da4651614b487346e225beba1c7b29fb5","affectsGlobalScope":true},"a7b43c69f9602d198825e403ee34e5d64f83c48b391b2897e8c0e6f72bca35f8","c567c7d3038a689bd3274285c3a421eaabc3289d38e8441e686a91db97a3d663","ae0784437911149dabe5cd245e5858305ebf2c30d44a80a037aa990b8500c5f3","133c3fe00db1cce01ae605753f88e29aa707c9a22c5f25c48d9d6e2ee6dab0c7","fe7b61b633d3c7ec4ebd8039f40e650adbe7ce872239de15da90d2452849c060","05af2a124f5a9113e7503539a3f1e1c72e92d9c756a2e5ad2e5afab11e0325d7","2f9c94d2805d249de1ed836937ce1c62dd051bae445661e62ecf238b69893b29","c1e031196368cb57b219684032865182384fcd3d60027783a42449f6e0a580d1","0b7733d83619ac4e3963e2a9f7c75dc1e9af6850cb2354c9554977813092c10a","3ce933f0c3955f67f67eb7d6b5c83c2c54a18472c1d6f2bb651e51dd40c84837","911690e5b1cdb5516785d9f811b5f9679fae1a2a1df5fad1f001e8d167c7fd98","bd180a2d4ada8a0e92ad33333933e2c96646ea94837bf80f68ec7f95e79b5e12","121cfafda904699b1abc90b7894128a78692a877380d70a9eca2e2b79207076a","8ef3d66d40dd2b5332b4e84bf591219a04d41a7fdb5237d470f7b2002557e427","e959c2855e83468c9b9f2bb73860f718dd80cc82a6d9b8793b81dedf7b1aa249","ce67e3dcf0f09888d0059fc61017ea22a7e5ac9112c727159fbff7937498e8dd",{"version":"2708349d5a11a5c2e5f3a0765259ebe7ee00cdcc8161cb9990cb4910328442a1","affectsGlobalScope":true},"2580346168c485710cca0ae724e081c715dafaba9ee1f735aceecc2432427027","483b37cab381fe1a5c118f86ac931aebc4e1ad76f8867dc60c0f10c5c6a9305c","8ea1394bb5549f22e31c1896fb14d943185b72b14db2f39c8fc00e64e8b67361","e61a21e9418f279bc480394a94d1581b2dee73747adcbdef999b6737e34d721b","23dca7e2d421cdf16f12144497b3da31302dfbe88d648eff16bf37944483f3bd","559c8c6979e9c6d649b26a0f56f0b6f1080606a0e8ea537a0099537c6b10584c","3b1c4e120e1050d6a4203fcdd82b561d9ce6cbf45d48d3837450a7b78919fd59","667c77aa756d8e4547eb170ccc0f2cb39852130c94eb299491b45008210ae681","126c87faf0c84b1326c3863ce2235b6a47dc2e548c3aba754c2d3eed16d7eee8","a63605647d8d06e31298d7e04ede8e4775f9b10c51955de611e7207681a39012","a11288edc8161f664148ea7d56101517e380335f5fa1a94408db86efce025bba","3d3c8cf9262ffe218c09c05dcb96832f81c189335a9d600642c49a1f05db40bc","dd5bab97b9f2d5dec2796fa4ff1b6db7221dfc9158f4e81cf9bcef8750dc32ba","f10a176bcf3a0320f5137c6fc1da2d9b7347f8e2852a0ca5802a0ea9aac2df4c","1c33a2766d210aa58703a1fb9d51c0c49fb0f98495974847870f2f090df9e52a","d1f8a829c5e90734bb47a1d1941b8819aeee6e81a2a772c3c0f70b30e3693fa9","413cb528dd3ba14550e9c10c3f87190aeb9a2359d4a2538972648ee285356af6","c3af56254d446bd82dfce2c64332ad737a32ba3d36c6aaab10e4556936aaf086","17c846b03d5877499082fba19e05d7e7f743402e4227640dbc8381ae24f6a83b","248635dc39ffd890d8a4bf8548dc7ba42a980e448f23847b6f125d6683541d3b","360133226431f8678b893d4d8f599b7d7edae4f07c8f5548964f5f2f4140fb68","502908f97b699fd309472908eb0a1378a66ee66e040a8ec7c428a4a0a4f5f278","aff2ce6bb4d9dd023c27f2fbacb51fd22ed7e07d3527da656739359508e3156f","a1274a49fdcdedfc138e81b307ceaa15ec0bf270f55b1dee51df8f29f1fff03b","a40c24317de6bfca7e3746d02c14b4da39f52d3b65223b8defa567711b76060d","0ca62963192a317daa21cd8f940ae301040d77ffa91cae99a7dca7fbc91267e9","b668b7fb7c52a05fb9233a27ba5099a73cd8e157b037d67399336635495ab483","b25c5f2970d06c729f464c0aeaa64b1a5b5f1355aa93554bb5f9c199b8624b1e","069733dc220affbe58d9c1d1a93af3707bc515aaed761701d8741b57da4cb964","3051751533eee92572241b3cef28333212401408c4e7aa21718714b793c0f4ed","691aea9772797ca98334eb743e7686e29325b02c6931391bcee4cc7bf27a9f3b","6f1d39d26959517da3bd105c552eded4c34702705c64d75b03f54d864b6e41c2",{"version":"e9cf450600c496a87ab96d288157b79be6c193e8623bd93553d5d64755940dea","affectsGlobalScope":true},{"version":"c8a2f72f046b5efb790cc37cfe79dcf11ce8e35e7e7d9430e10e53e0aa05c7a2","affectsGlobalScope":true},"5171627120eeb3a7e8afb8ed04ea9be7f0b53ba09bb1fc95172483e0fbb0740c","95c22bc19835e28e2e524a4bb8898eb5f2107b640d7279a6d3aade261916bbf2","393137c76bd922ba70a2f8bf1ade4f59a16171a02fb25918c168d48875b0cfb0","3ebae8c00411116a66fca65b08228ea0cf0b72724701f9b854442100aab55aba","de18acda71730bac52f4b256ce7511bb56cc21f6f114c59c46782eff2f632857","7eb06594824ada538b1d8b48c3925a83e7db792f47a081a62cf3e5c4e23cf0ee","905c3e8f7ddaa6c391b60c05b2f4c3931d7127ad717a080359db3df510b7bdab","d8aab31ba8e618cc3eea10b0945de81cb93b7e8150a013a482332263b9305322","69da61a7b5093dac77fa3bec8be95dcf9a74c95a0e9161edb98bb24e30e439d2","561eca7a381b96d6ccac6e4061e6d2ae53f5bc44203f3fd9f5b26864c32ae6e9","62ea38627e3ebab429f7616812a9394d327c2bc271003dfba985de9b4137369f","b4439890c168d646357928431100daac5cbdee1d345a34e6bf6eca9f3abe22bc","5d72971a459517c44c1379dab9ed248e87a61ba0a1e0f25c9d67e1e640cd9a09","02d734976af36f4273d930bea88b3e62adf6b078cf120c1c63d49aa8d8427c5c",{"version":"ce2169125f42515a26fa60977b6d56ae407f3462e28832fbf6a9013f6a828bab","affectsGlobalScope":true},"0359682c54e487c4cab2b53b2b4d35cc8dea4d9914bc6abcdb5701f8b8e745a4","e437d83044ba17246a861aa9691aa14223ff4a9d6f338ab1269c41c758586a88","c9ad058b2cc9ce6dc2ed92960d6d009e8c04bef46d3f5312283debca6869f613","2b8264b2fefd7367e0f20e2c04eed5d3038831fe00f5efbc110ff0131aab899b","08b428a44bc98005536a12456518797e9afe2a08e8b5d9785641713a54475881","c6c4fea9acc55d5e38ff2b70d57ab0b5cdbd08f8bc5d7a226e322cea128c5b57","96b49a9de749afcf92b5bce1d8cc42cfae6816cdf5ea36584fd9256b8b2e5292","3bdd93ec24853e61bfa4c63ebaa425ff3e474156e87a47d90122e1d8cc717c1f","5a2a25feca554a8f289ed62114771b8c63d89f2b58325e2f8b7043e4e0160d11","3845d3b64286c12c60d39fc90ac1cc5e47cbc951530658d2567d578b2faa1f26"],"options":{"declaration":true,"declarationDir":"./types","downlevelIteration":true,"esModuleInterop":true,"experimentalDecorators":true,"importHelpers":true,"inlineSourceMap":true,"inlineSources":true,"module":1,"noEmitHelpers":true,"noFallthroughCasesInSwitch":true,"noUnusedParameters":false,"outDir":"./cjs","preserveConstEnums":true,"removeComments":false,"rootDir":"../src","sourceMap":false,"strict":true,"target":5},"fileIdsList":[[114],[114,115,116,117,118],[114,116],[120],[60,92],[59,92,123],[126],[127],[133,135],[90],[49],[89,90],[50],[51,59,66,75],[51,52,59,66],[54],[55,75],[56,57,59,66],[57],[58,59],[59],[59,60,75,81],[61,66,75,81],[59,60,61,62,66,75,78,81],[61,63,78,81],[91],[59,64],[57,59,66,75],[67],[68],[49,69],[80],[71],[72],[59,73],[73,74,82,84],[59,75],[76],[77],[66,78],[79],[48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88],[66,80],[72,81],[82],[75,83],[84],[88],[59,60,75,84,85],[75,86],[144],[59,75,92],[129,130],[129,130,131,132],[134],[106],[106,107],[29,98],[29,47,104,105,109,110,111],[29,47],[29,47,109,112],[29,99,109,110],[29,47,108],[29,109,110],[47,93,95,96],[47,92],[47,94],[47],[97],[47,100,101],[100,101,102,103],[33,35,36],[33,35],[34],[32,33,35],[30],[30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],[31,34],[37],[32,34,42],[33],[32]],"referencedMap":[[116,1],[119,2],[115,1],[117,3],[118,1],[121,4],[122,5],[124,6],[125,5],[127,7],[128,8],[136,9],[90,10],[49,11],[91,12],[50,13],[51,14],[52,15],[54,16],[55,17],[56,18],[57,19],[58,20],[59,21],[60,22],[61,23],[62,24],[63,25],[92,26],[64,27],[66,28],[67,29],[68,30],[69,31],[70,32],[71,33],[72,34],[73,35],[74,36],[75,37],[76,38],[77,39],[78,40],[79,41],[89,42],[80,43],[81,44],[82,45],[83,46],[84,47],[88,48],[85,49],[86,50],[145,51],[146,52],[131,53],[133,54],[132,53],[135,55],[107,56],[108,57],[99,58],[112,59],[105,60],[110,61],[113,62],[109,63],[111,64],[97,65],[93,66],[95,67],[96,68],[98,69],[102,70],[101,68],[100,68],[104,71],[37,72],[36,73],[38,74],[40,75],[32,76],[47,77],[35,78],[41,79],[43,80],[44,81],[45,82],[34,75],[46,76]],"exportedModulesMap":[[116,1],[119,2],[115,1],[117,3],[118,1],[121,4],[122,5],[124,6],[125,5],[127,7],[128,8],[136,9],[90,10],[49,11],[91,12],[50,13],[51,14],[52,15],[54,16],[55,17],[56,18],[57,19],[58,20],[59,21],[60,22],[61,23],[62,24],[63,25],[92,26],[64,27],[66,28],[67,29],[68,30],[69,31],[70,32],[71,33],[72,34],[73,35],[74,36],[75,37],[76,38],[77,39],[78,40],[79,41],[89,42],[80,43],[81,44],[82,45],[83,46],[84,47],[88,48],[85,49],[86,50],[145,51],[146,52],[131,53],[133,54],[132,53],[135,55],[107,56],[108,57],[99,58],[112,59],[105,60],[110,61],[113,62],[109,63],[111,64],[97,65],[93,66],[95,67],[96,68],[98,69],[102,70],[101,68],[100,68],[104,71],[37,72],[36,73],[38,74],[40,75],[32,76],[47,77],[35,78],[41,79],[43,80],[44,81],[45,82],[34,75],[46,76]],"semanticDiagnosticsPerFile":[116,114,119,115,117,118,121,120,122,124,125,126,127,128,136,137,123,138,90,49,91,50,51,52,53,54,55,56,57,58,59,60,48,87,61,62,63,92,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,89,80,81,82,83,84,88,85,86,139,140,141,142,143,144,145,146,129,131,133,132,130,135,134,29,6,8,7,2,9,10,11,12,13,14,15,16,3,4,20,17,18,19,21,22,23,5,24,25,26,27,1,28,106,107,108,99,112,105,110,113,109,111,97,93,95,96,98,102,101,100,104,103,94,30,37,36,38,39,40,32,47,31,35,41,33,43,44,45,42,34,46]},"version":"4.3.5"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"program":{"fileNames":["../../../node_modules/typescript/lib/lib.es5.d.ts","../../../node_modules/typescript/lib/lib.es2015.d.ts","../../../node_modules/typescript/lib/lib.es2016.d.ts","../../../node_modules/typescript/lib/lib.es2017.d.ts","../../../node_modules/typescript/lib/lib.es2018.d.ts","../../../node_modules/typescript/lib/lib.es2015.core.d.ts","../../../node_modules/typescript/lib/lib.es2015.collection.d.ts","../../../node_modules/typescript/lib/lib.es2015.generator.d.ts","../../../node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../../node_modules/typescript/lib/lib.es2015.promise.d.ts","../../../node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../../node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../../node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../../node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../../node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../../node_modules/typescript/lib/lib.es2017.object.d.ts","../../../node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../../node_modules/typescript/lib/lib.es2017.string.d.ts","../../../node_modules/typescript/lib/lib.es2017.intl.d.ts","../../../node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../../node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../../node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../../node_modules/typescript/lib/lib.es2018.intl.d.ts","../../../node_modules/typescript/lib/lib.es2018.promise.d.ts","../../../node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../../node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../../node_modules/typescript/lib/lib.esnext.intl.d.ts","../../../node_modules/tslib/tslib.d.ts","../../types/dist/types/abort.d.ts","../../types/dist/types/logger.d.ts","../../types/dist/types/http.d.ts","../../types/dist/types/response.d.ts","../../types/dist/types/util.d.ts","../../types/dist/types/middleware.d.ts","../../types/dist/types/command.d.ts","../../types/dist/types/client.d.ts","../../types/dist/types/credentials.d.ts","../../types/dist/types/crypto.d.ts","../../types/dist/types/eventStream.d.ts","../../types/dist/types/pagination.d.ts","../../types/dist/types/transfer.d.ts","../../types/dist/types/serde.d.ts","../../types/dist/types/shapes.d.ts","../../types/dist/types/signature.d.ts","../../types/dist/types/waiter.d.ts","../../types/dist/types/index.d.ts","../../../node_modules/@types/node/globals.d.ts","../../../node_modules/@types/node/async_hooks.d.ts","../../../node_modules/@types/node/buffer.d.ts","../../../node_modules/@types/node/child_process.d.ts","../../../node_modules/@types/node/cluster.d.ts","../../../node_modules/@types/node/console.d.ts","../../../node_modules/@types/node/constants.d.ts","../../../node_modules/@types/node/crypto.d.ts","../../../node_modules/@types/node/dgram.d.ts","../../../node_modules/@types/node/dns.d.ts","../../../node_modules/@types/node/domain.d.ts","../../../node_modules/@types/node/events.d.ts","../../../node_modules/@types/node/fs.d.ts","../../../node_modules/@types/node/http.d.ts","../../../node_modules/@types/node/http2.d.ts","../../../node_modules/@types/node/https.d.ts","../../../node_modules/@types/node/inspector.d.ts","../../../node_modules/@types/node/module.d.ts","../../../node_modules/@types/node/net.d.ts","../../../node_modules/@types/node/os.d.ts","../../../node_modules/@types/node/path.d.ts","../../../node_modules/@types/node/perf_hooks.d.ts","../../../node_modules/@types/node/process.d.ts","../../../node_modules/@types/node/punycode.d.ts","../../../node_modules/@types/node/querystring.d.ts","../../../node_modules/@types/node/readline.d.ts","../../../node_modules/@types/node/repl.d.ts","../../../node_modules/@types/node/stream.d.ts","../../../node_modules/@types/node/string_decoder.d.ts","../../../node_modules/@types/node/timers.d.ts","../../../node_modules/@types/node/tls.d.ts","../../../node_modules/@types/node/trace_events.d.ts","../../../node_modules/@types/node/tty.d.ts","../../../node_modules/@types/node/url.d.ts","../../../node_modules/@types/node/util.d.ts","../../../node_modules/@types/node/v8.d.ts","../../../node_modules/@types/node/vm.d.ts","../../../node_modules/@types/node/worker_threads.d.ts","../../../node_modules/@types/node/zlib.d.ts","../../../node_modules/@types/node/globals.global.d.ts","../../../node_modules/@types/node/wasi.d.ts","../../../node_modules/@types/node/ts3.6/base.d.ts","../../../node_modules/@types/node/assert.d.ts","../../../node_modules/@types/node/base.d.ts","../../../node_modules/@types/node/index.d.ts","../../node-config-provider/dist/types/fromEnv.d.ts","../../shared-ini-file-loader/dist/types/index.d.ts","../../node-config-provider/dist/types/fromSharedConfigFiles.d.ts","../../node-config-provider/dist/types/fromStatic.d.ts","../../node-config-provider/dist/types/configLoader.d.ts","../../node-config-provider/dist/types/index.d.ts","../src/configurations.ts","../../protocol-http/dist/types/httpResponse.d.ts","../../protocol-http/dist/types/httpRequest.d.ts","../../protocol-http/dist/types/httpHandler.d.ts","../../protocol-http/dist/types/isValidHostname.d.ts","../../protocol-http/dist/types/index.d.ts","../src/getCacheKey.ts","../../endpoint-cache/dist/types/Endpoint.d.ts","../../endpoint-cache/dist/types/EndpointCache.d.ts","../../endpoint-cache/dist/types/index.d.ts","../src/resolveEndpointDiscoveryConfig.ts","../src/getEndpointDiscoveryPlugin.ts","../src/updateDiscoveredEndpointInCache.ts","../src/endpointDiscoveryMiddleware.ts","../src/index.ts","../../../node_modules/@babel/types/lib/index.d.ts","../../../node_modules/@types/babel__generator/index.d.ts","../../../node_modules/@babel/parser/typings/babel-parser.d.ts","../../../node_modules/@types/babel__template/index.d.ts","../../../node_modules/@types/babel__traverse/index.d.ts","../../../node_modules/@types/babel__core/index.d.ts","../../../node_modules/@types/chai/index.d.ts","../../../node_modules/@types/chai-as-promised/index.d.ts","../../../node_modules/@types/fs-extra/index.d.ts","../../../node_modules/@types/minimatch/index.d.ts","../../../node_modules/@types/glob/index.d.ts","../../../node_modules/@types/graceful-fs/index.d.ts","../../../node_modules/@types/istanbul-lib-coverage/index.d.ts","../../../node_modules/@types/istanbul-lib-report/index.d.ts","../../../node_modules/@types/istanbul-reports/index.d.ts","../../../node_modules/jest-diff/build/cleanupSemantic.d.ts","../../../node_modules/jest-diff/build/types.d.ts","../../../node_modules/jest-diff/build/diffLines.d.ts","../../../node_modules/jest-diff/build/printDiffs.d.ts","../../../node_modules/jest-diff/build/index.d.ts","../../../node_modules/pretty-format/build/types.d.ts","../../../node_modules/pretty-format/build/index.d.ts","../../../node_modules/@types/jest/index.d.ts","../../../node_modules/@types/json-schema/index.d.ts","../../../node_modules/@types/minimist/index.d.ts","../../../node_modules/@types/normalize-package-data/index.d.ts","../../../node_modules/@types/parse-json/index.d.ts","../../../node_modules/@types/prettier/index.d.ts","../../../node_modules/@types/stack-utils/index.d.ts","../../../node_modules/@types/uuid/index.d.ts","../../../node_modules/@types/yargs-parser/index.d.ts","../../../node_modules/@types/yargs/index.d.ts","../../../node_modules/@types/yauzl/index.d.ts"],"fileInfos":[{"version":"ac3a8c4040e183ce38da69d23b96939112457d1936198e6542672b7963cf0fce","affectsGlobalScope":true},"dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6","7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467","8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9","5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06",{"version":"cce43d02223f8049864f8568bed322c39424013275cd3bcc3f51492d8b546cb3","affectsGlobalScope":true},{"version":"43fb1d932e4966a39a41b464a12a81899d9ae5f2c829063f5571b6b87e6d2f9c","affectsGlobalScope":true},{"version":"cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a","affectsGlobalScope":true},{"version":"8dff1b4c2df638fcd976cbb0e636f23ab5968e836cd45084cc31d47d1ab19c49","affectsGlobalScope":true},{"version":"2bb4b3927299434052b37851a47bf5c39764f2ba88a888a107b32262e9292b7c","affectsGlobalScope":true},{"version":"810627a82ac06fb5166da5ada4159c4ec11978dfbb0805fe804c86406dab8357","affectsGlobalScope":true},{"version":"62d80405c46c3f4c527ee657ae9d43fda65a0bf582292429aea1e69144a522a6","affectsGlobalScope":true},{"version":"3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93","affectsGlobalScope":true},{"version":"8f4c9f651c8294a2eb1cbd12581fe25bfb901ab1d474bb93cd38c7e2f4be7a30","affectsGlobalScope":true},{"version":"3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006","affectsGlobalScope":true},{"version":"17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a","affectsGlobalScope":true},{"version":"7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98","affectsGlobalScope":true},{"version":"6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577","affectsGlobalScope":true},{"version":"12a310447c5d23c7d0d5ca2af606e3bd08afda69100166730ab92c62999ebb9d","affectsGlobalScope":true},{"version":"b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e","affectsGlobalScope":true},{"version":"0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a","affectsGlobalScope":true},{"version":"da233fc1c8a377ba9e0bed690a73c290d843c2c3d23a7bd7ec5cd3d7d73ba1e0","affectsGlobalScope":true},{"version":"df9c8a72ca8b0ed62f5470b41208a0587f0f73f0a7db28e5a1272cf92537518e","affectsGlobalScope":true},{"version":"bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c","affectsGlobalScope":true},{"version":"c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8","affectsGlobalScope":true},{"version":"60761e6ea886034af0f294f025a7199360ce4e2c8ba4ec6408bc049cf9b89799","affectsGlobalScope":true},{"version":"506b80b9951c9381dc5f11897b31fca5e2a65731d96ddefa19687fbc26b23c6e","affectsGlobalScope":true},"12f4cfe2fe60b810c3174537bc2ddb20c1067b7768643d12cb1266fd183afb75","4f1034eac6404cb69bedb8bb04cf246871d1aaebbb99d5617be54f54323464c7","724eb35fdcfa2ad686611b3a8a9d704ad0d478539a8cf0089176e0b8047f7190","d71be3ec7ca8cf9aaf6a8b68653dd3b7d988678edc120a640fc0307967486cc5","2e04271499caec54dea75e7061de06b2549efbe1d652b9bdab2f74fd2572f61f","40b990c27c58cf6d4473c9cdc65daf0428cbfca5cf4b072c73a4ad5a4055ea7f","0b2fe702dda65d25d5e00ec95fc8952036e7e75870c376abeb2cd2150b0a3bed","a9367ec48d3b67800c69c890e616337935df67caad5bff99383949af561042a8","5c1a8d6754a7cceee2135728e8ce6a4f984966a2d16ff1cbed879f7527d55864","a99add785a8a06f19582501ca19e92949f6b840b3f91d880e73582c5efacccde","5a7bb8afd0a22b7754275793f5ca5aeea379a2aad6153a6d68af49a60a899f69","a604c1ae24a48ccdb36396f49a20677d32722f8fd461dfb47186a5b12fd88d60","259c58ced9d80f66a61362a8768529a2746a2bc80183cdb04726f610913bb5d5","b14456a54e15ce24ff9e5ad3b70675b104a36eb35886e3ffaae614292c0908c4","ed01aa50ff4fdbf0f6857596fc385587d87da4896c7980ea75527e098031c488","9e5aef3efc63316ce7aa61b137d354449f792ab92885d03c8894b239db75d90a","8a6c15bfa2a0a9e68005a53fb71b60f3769af0da81001b95e4861310e260b788","aaffeca0d82a3d862c5186af3ca707801e45cc8b2e7d31e430eb715648ffa839","aedcac717f286d9925f0c52aa6165f4e91a2ed05ad9c1e2a8cc91eca18b8eb2b",{"version":"f7be6b47e03c43fa3ad1224b4fd995f3fd35bb29f0c2da5843c9dc04f4162fb3","affectsGlobalScope":true},"0829c48316ebcd238419d1ba2f142c866fe064a2452b449197dc85a9f43a3612","e63d5487b6d47f8abcbfdc3af9450d56118041805dd043febd249af0502dc9b1","5f505b075956d1c7db95d14e2e7a27d4e4a9d1ffc34b83b8273c51b074d575bd","458d55b08da524f900192dafb5837fcc2471cb59c0c149eea4754c180f943473","65409a1cc0ce6d0e4bc9a4dfd35e7df27b8b2646c9055230fdbb03f694b0cc88","e9339a66a8c672260b9c6b727f6d818c42a8d13bade07dfaf907103928e3c456","51d9197446e865a6919a2f217f4d0ad19f77483e5c7f2ebc520de4dc416dc5a3","b39ae9f0d9d0bdcde86891b047ac912602a59fa188c1d2c4bc201fc7c86cfaa9","f8a7a6d7af6267022984c5604ec31c4539fea5cb749e63ff3a0cf8a42fd19603","6570493ff2552919da1e6480f20d0b623b8007343a777922fca7788b6ce85ea1","d42d0bfd355a4f9f247789676137aec627d0b23122452c388a6c1a83105ae811","5efce49fe6c5e6c7211f4cfb93724adc1cf5783c63d608dca8cb61bfcbee29e6","bb05e8566a80f6e42df974e7523744b0af66aa9fafc721022156b202276c480e","9771ae64c7390ee98639ac79e9fb37b87a17de52b4bb705d48c9fc67af429e64","1939c52bd6e3fe0c5beacd7f5762f9847e86861059685fbdf471bd8afaf87944","d4fa2c2de99b1f4ff83aba4732c33fff918bf5869c04674aa2bfe927adfbd386","9cd5d57333119af9861227e2415a944d23ae7fa67706ac60a4c9a5cfde0a5a05","cf36f4557f363a203e39329aba07cc2f916ae181b4f71c61814db2e9ca6ca30c","b0d1073a8fbdd7b36fd048d82b1f148ce161ed54569a4b4b43007733ee643fff","311f6a6b6c05d334c29eb795d765bfbb596bb43a78fcb72bc23a6121eefb3924","b76f9cfe8fdfe10bb5ab1b540ea866771b89bb0e0acafbe119c9c8cbe398c092",{"version":"7e56a8722b9aeae9496e1278539f1b7da4651614b487346e225beba1c7b29fb5","affectsGlobalScope":true},"a7b43c69f9602d198825e403ee34e5d64f83c48b391b2897e8c0e6f72bca35f8","c567c7d3038a689bd3274285c3a421eaabc3289d38e8441e686a91db97a3d663","ae0784437911149dabe5cd245e5858305ebf2c30d44a80a037aa990b8500c5f3","133c3fe00db1cce01ae605753f88e29aa707c9a22c5f25c48d9d6e2ee6dab0c7","fe7b61b633d3c7ec4ebd8039f40e650adbe7ce872239de15da90d2452849c060","05af2a124f5a9113e7503539a3f1e1c72e92d9c756a2e5ad2e5afab11e0325d7","2f9c94d2805d249de1ed836937ce1c62dd051bae445661e62ecf238b69893b29","c1e031196368cb57b219684032865182384fcd3d60027783a42449f6e0a580d1","0b7733d83619ac4e3963e2a9f7c75dc1e9af6850cb2354c9554977813092c10a","3ce933f0c3955f67f67eb7d6b5c83c2c54a18472c1d6f2bb651e51dd40c84837","911690e5b1cdb5516785d9f811b5f9679fae1a2a1df5fad1f001e8d167c7fd98","bd180a2d4ada8a0e92ad33333933e2c96646ea94837bf80f68ec7f95e79b5e12","121cfafda904699b1abc90b7894128a78692a877380d70a9eca2e2b79207076a","8ef3d66d40dd2b5332b4e84bf591219a04d41a7fdb5237d470f7b2002557e427","e959c2855e83468c9b9f2bb73860f718dd80cc82a6d9b8793b81dedf7b1aa249","ce67e3dcf0f09888d0059fc61017ea22a7e5ac9112c727159fbff7937498e8dd",{"version":"2708349d5a11a5c2e5f3a0765259ebe7ee00cdcc8161cb9990cb4910328442a1","affectsGlobalScope":true},"2580346168c485710cca0ae724e081c715dafaba9ee1f735aceecc2432427027","483b37cab381fe1a5c118f86ac931aebc4e1ad76f8867dc60c0f10c5c6a9305c","8ea1394bb5549f22e31c1896fb14d943185b72b14db2f39c8fc00e64e8b67361","e61a21e9418f279bc480394a94d1581b2dee73747adcbdef999b6737e34d721b","23dca7e2d421cdf16f12144497b3da31302dfbe88d648eff16bf37944483f3bd","559c8c6979e9c6d649b26a0f56f0b6f1080606a0e8ea537a0099537c6b10584c","3b1c4e120e1050d6a4203fcdd82b561d9ce6cbf45d48d3837450a7b78919fd59","667c77aa756d8e4547eb170ccc0f2cb39852130c94eb299491b45008210ae681","126c87faf0c84b1326c3863ce2235b6a47dc2e548c3aba754c2d3eed16d7eee8","a63605647d8d06e31298d7e04ede8e4775f9b10c51955de611e7207681a39012","a11288edc8161f664148ea7d56101517e380335f5fa1a94408db86efce025bba","3d3c8cf9262ffe218c09c05dcb96832f81c189335a9d600642c49a1f05db40bc","dd5bab97b9f2d5dec2796fa4ff1b6db7221dfc9158f4e81cf9bcef8750dc32ba","f10a176bcf3a0320f5137c6fc1da2d9b7347f8e2852a0ca5802a0ea9aac2df4c","1c33a2766d210aa58703a1fb9d51c0c49fb0f98495974847870f2f090df9e52a","d1f8a829c5e90734bb47a1d1941b8819aeee6e81a2a772c3c0f70b30e3693fa9","413cb528dd3ba14550e9c10c3f87190aeb9a2359d4a2538972648ee285356af6","c3af56254d446bd82dfce2c64332ad737a32ba3d36c6aaab10e4556936aaf086","17c846b03d5877499082fba19e05d7e7f743402e4227640dbc8381ae24f6a83b","248635dc39ffd890d8a4bf8548dc7ba42a980e448f23847b6f125d6683541d3b","360133226431f8678b893d4d8f599b7d7edae4f07c8f5548964f5f2f4140fb68","502908f97b699fd309472908eb0a1378a66ee66e040a8ec7c428a4a0a4f5f278","aff2ce6bb4d9dd023c27f2fbacb51fd22ed7e07d3527da656739359508e3156f","a1274a49fdcdedfc138e81b307ceaa15ec0bf270f55b1dee51df8f29f1fff03b","a40c24317de6bfca7e3746d02c14b4da39f52d3b65223b8defa567711b76060d","0ca62963192a317daa21cd8f940ae301040d77ffa91cae99a7dca7fbc91267e9","b668b7fb7c52a05fb9233a27ba5099a73cd8e157b037d67399336635495ab483","b25c5f2970d06c729f464c0aeaa64b1a5b5f1355aa93554bb5f9c199b8624b1e","069733dc220affbe58d9c1d1a93af3707bc515aaed761701d8741b57da4cb964","3051751533eee92572241b3cef28333212401408c4e7aa21718714b793c0f4ed","691aea9772797ca98334eb743e7686e29325b02c6931391bcee4cc7bf27a9f3b","6f1d39d26959517da3bd105c552eded4c34702705c64d75b03f54d864b6e41c2",{"version":"e9cf450600c496a87ab96d288157b79be6c193e8623bd93553d5d64755940dea","affectsGlobalScope":true},{"version":"c8a2f72f046b5efb790cc37cfe79dcf11ce8e35e7e7d9430e10e53e0aa05c7a2","affectsGlobalScope":true},"5171627120eeb3a7e8afb8ed04ea9be7f0b53ba09bb1fc95172483e0fbb0740c","95c22bc19835e28e2e524a4bb8898eb5f2107b640d7279a6d3aade261916bbf2","393137c76bd922ba70a2f8bf1ade4f59a16171a02fb25918c168d48875b0cfb0","3ebae8c00411116a66fca65b08228ea0cf0b72724701f9b854442100aab55aba","de18acda71730bac52f4b256ce7511bb56cc21f6f114c59c46782eff2f632857","7eb06594824ada538b1d8b48c3925a83e7db792f47a081a62cf3e5c4e23cf0ee","905c3e8f7ddaa6c391b60c05b2f4c3931d7127ad717a080359db3df510b7bdab","d8aab31ba8e618cc3eea10b0945de81cb93b7e8150a013a482332263b9305322","69da61a7b5093dac77fa3bec8be95dcf9a74c95a0e9161edb98bb24e30e439d2","561eca7a381b96d6ccac6e4061e6d2ae53f5bc44203f3fd9f5b26864c32ae6e9","62ea38627e3ebab429f7616812a9394d327c2bc271003dfba985de9b4137369f","b4439890c168d646357928431100daac5cbdee1d345a34e6bf6eca9f3abe22bc","5d72971a459517c44c1379dab9ed248e87a61ba0a1e0f25c9d67e1e640cd9a09","02d734976af36f4273d930bea88b3e62adf6b078cf120c1c63d49aa8d8427c5c",{"version":"ce2169125f42515a26fa60977b6d56ae407f3462e28832fbf6a9013f6a828bab","affectsGlobalScope":true},"0359682c54e487c4cab2b53b2b4d35cc8dea4d9914bc6abcdb5701f8b8e745a4","e437d83044ba17246a861aa9691aa14223ff4a9d6f338ab1269c41c758586a88","c9ad058b2cc9ce6dc2ed92960d6d009e8c04bef46d3f5312283debca6869f613","2b8264b2fefd7367e0f20e2c04eed5d3038831fe00f5efbc110ff0131aab899b","08b428a44bc98005536a12456518797e9afe2a08e8b5d9785641713a54475881","c6c4fea9acc55d5e38ff2b70d57ab0b5cdbd08f8bc5d7a226e322cea128c5b57","96b49a9de749afcf92b5bce1d8cc42cfae6816cdf5ea36584fd9256b8b2e5292","3bdd93ec24853e61bfa4c63ebaa425ff3e474156e87a47d90122e1d8cc717c1f","5a2a25feca554a8f289ed62114771b8c63d89f2b58325e2f8b7043e4e0160d11","3845d3b64286c12c60d39fc90ac1cc5e47cbc951530658d2567d578b2faa1f26"],"options":{"declaration":true,"declarationDir":"./types","downlevelIteration":true,"esModuleInterop":true,"experimentalDecorators":true,"importHelpers":true,"inlineSourceMap":true,"inlineSources":true,"module":99,"noEmitHelpers":true,"noFallthroughCasesInSwitch":true,"noUnusedParameters":false,"outDir":"./es","preserveConstEnums":true,"removeComments":false,"rootDir":"../src","sourceMap":false,"strict":true,"target":1},"fileIdsList":[[113],[113,114,115,116,117],[113,115],[119],[59,91],[58,91,122],[125],[126],[132,134],[89],[48],[88,89],[49],[50,58,65,74],[50,51,58,65],[53],[54,74],[55,56,58,65],[56],[57,58],[58],[58,59,74,80],[60,65,74,80],[58,59,60,61,65,74,77,80],[60,62,77,80],[90],[58,63],[56,58,65,74],[66],[67],[48,68],[79],[70],[71],[58,72],[72,73,81,83],[58,74],[75],[76],[65,77],[78],[47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87],[65,79],[71,80],[81],[74,82],[83],[87],[58,59,74,83,84],[74,85],[143],[58,74,91],[128,129],[128,129,130,131],[133],[105],[105,106],[28,97],[28,46,103,104,108,109,110],[28,46],[28,46,108,111],[28,98,108,109],[28,46,107],[28,108,109],[46,92,94,95],[46,91],[46,93],[46],[96],[46,99,100],[99,100,101,102],[32,34,35],[32,34],[33],[31,32,34],[29],[29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45],[30,33],[36],[31,33,41],[32],[31]],"referencedMap":[[115,1],[118,2],[114,1],[116,3],[117,1],[120,4],[121,5],[123,6],[124,5],[126,7],[127,8],[135,9],[89,10],[48,11],[90,12],[49,13],[50,14],[51,15],[53,16],[54,17],[55,18],[56,19],[57,20],[58,21],[59,22],[60,23],[61,24],[62,25],[91,26],[63,27],[65,28],[66,29],[67,30],[68,31],[69,32],[70,33],[71,34],[72,35],[73,36],[74,37],[75,38],[76,39],[77,40],[78,41],[88,42],[79,43],[80,44],[81,45],[82,46],[83,47],[87,48],[84,49],[85,50],[144,51],[145,52],[130,53],[132,54],[131,53],[134,55],[106,56],[107,57],[98,58],[111,59],[104,60],[109,61],[112,62],[108,63],[110,64],[96,65],[92,66],[94,67],[95,68],[97,69],[101,70],[100,68],[99,68],[103,71],[36,72],[35,73],[37,74],[39,75],[31,76],[46,77],[34,78],[40,79],[42,80],[43,81],[44,82],[33,75],[45,76]],"exportedModulesMap":[[115,1],[118,2],[114,1],[116,3],[117,1],[120,4],[121,5],[123,6],[124,5],[126,7],[127,8],[135,9],[89,10],[48,11],[90,12],[49,13],[50,14],[51,15],[53,16],[54,17],[55,18],[56,19],[57,20],[58,21],[59,22],[60,23],[61,24],[62,25],[91,26],[63,27],[65,28],[66,29],[67,30],[68,31],[69,32],[70,33],[71,34],[72,35],[73,36],[74,37],[75,38],[76,39],[77,40],[78,41],[88,42],[79,43],[80,44],[81,45],[82,46],[83,47],[87,48],[84,49],[85,50],[144,51],[145,52],[130,53],[132,54],[131,53],[134,55],[106,56],[107,57],[98,58],[111,59],[104,60],[109,61],[112,62],[108,63],[110,64],[96,65],[92,66],[94,67],[95,68],[97,69],[101,70],[100,68],[99,68],[103,71],[36,72],[35,73],[37,74],[39,75],[31,76],[46,77],[34,78],[40,79],[42,80],[43,81],[44,82],[33,75],[45,76]],"semanticDiagnosticsPerFile":[115,113,118,114,116,117,120,119,121,123,124,125,126,127,135,136,122,137,89,48,90,49,50,51,52,53,54,55,56,57,58,59,47,86,60,61,62,91,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,88,79,80,81,82,83,87,84,85,138,139,140,141,142,143,144,145,128,130,132,131,129,134,133,28,7,6,2,8,9,10,11,12,13,14,15,3,4,19,16,17,18,20,21,22,5,23,24,25,26,1,27,105,106,107,98,111,104,109,112,108,110,96,92,94,95,97,101,100,99,103,102,93,29,36,35,37,38,39,31,46,30,34,40,32,42,43,44,41,33,45]},"version":"4.3.5"}
|
package/jest.config.js
DELETED
|
@@ -1,85 +0,0 @@
|
|
|
1
|
-
import { NODE_ENDPOINT_DISCOVERY_CONFIG_OPTIONS } from "./configurations";
|
|
2
|
-
|
|
3
|
-
const {
|
|
4
|
-
environmentVariableSelector,
|
|
5
|
-
configFileSelector,
|
|
6
|
-
default: defaultSelector,
|
|
7
|
-
} = NODE_ENDPOINT_DISCOVERY_CONFIG_OPTIONS;
|
|
8
|
-
|
|
9
|
-
describe("NODE_ENDPOINT_DISCOVERY_CONFIG_OPTIONS", () => {
|
|
10
|
-
describe("environmentVariableSelector", () => {
|
|
11
|
-
const ENV_ENDPOINT_DISCOVERY = ["AWS_ENABLE_ENDPOINT_DISCOVERY", "AWS_ENDPOINT_DISCOVERY_ENABLED"];
|
|
12
|
-
describe.each(ENV_ENDPOINT_DISCOVERY)("env key: %p", (envKey) => {
|
|
13
|
-
const envValues = {};
|
|
14
|
-
|
|
15
|
-
beforeEach(() => {
|
|
16
|
-
ENV_ENDPOINT_DISCOVERY.forEach((envKey) => {
|
|
17
|
-
envValues[envKey] = process.env[envKey];
|
|
18
|
-
delete process.env[envKey];
|
|
19
|
-
});
|
|
20
|
-
});
|
|
21
|
-
|
|
22
|
-
afterEach(() => {
|
|
23
|
-
ENV_ENDPOINT_DISCOVERY.forEach((envKey) => {
|
|
24
|
-
process.env[envKey] = envValues[envKey];
|
|
25
|
-
delete envValues[envKey];
|
|
26
|
-
});
|
|
27
|
-
});
|
|
28
|
-
|
|
29
|
-
describe(`returns false`, () => {
|
|
30
|
-
it.each(["false", "0"])("if value stored is %s", (falsyValue) => {
|
|
31
|
-
process.env[envKey] = falsyValue;
|
|
32
|
-
expect(environmentVariableSelector(process.env)).toEqual(false);
|
|
33
|
-
});
|
|
34
|
-
});
|
|
35
|
-
|
|
36
|
-
describe(`returns true`, () => {
|
|
37
|
-
it.each(["true", "1", "non-empty-value"])("if value stored is %s", (truthyValue) => {
|
|
38
|
-
process.env[envKey] = truthyValue;
|
|
39
|
-
expect(environmentVariableSelector(process.env)).toEqual(true);
|
|
40
|
-
});
|
|
41
|
-
});
|
|
42
|
-
|
|
43
|
-
it(`returns undefined if value is not stored`, () => {
|
|
44
|
-
expect(environmentVariableSelector(process.env)).not.toBeDefined();
|
|
45
|
-
});
|
|
46
|
-
|
|
47
|
-
it(`throws error if value stored is empty`, () => {
|
|
48
|
-
process.env[envKey] = "";
|
|
49
|
-
expect(() => {
|
|
50
|
-
environmentVariableSelector(process.env);
|
|
51
|
-
}).toThrow();
|
|
52
|
-
});
|
|
53
|
-
});
|
|
54
|
-
});
|
|
55
|
-
|
|
56
|
-
describe("configFileSelector", () => {
|
|
57
|
-
const CONFIG_ENDPOINT_DISCOVERY = "endpoint_discovery_enabled";
|
|
58
|
-
|
|
59
|
-
describe(`returns false`, () => {
|
|
60
|
-
it.each(["false", "0"])("if value stored is %s", (falsyValue) => {
|
|
61
|
-
expect(configFileSelector({ [CONFIG_ENDPOINT_DISCOVERY]: falsyValue })).toEqual(false);
|
|
62
|
-
});
|
|
63
|
-
});
|
|
64
|
-
|
|
65
|
-
describe(`returns true`, () => {
|
|
66
|
-
it.each(["true", "1", "non-empty-value"])("if value stored is %s", (truthyValue) => {
|
|
67
|
-
expect(configFileSelector({ [CONFIG_ENDPOINT_DISCOVERY]: truthyValue })).toEqual(true);
|
|
68
|
-
});
|
|
69
|
-
});
|
|
70
|
-
|
|
71
|
-
it(`returns undefined if value is not available`, () => {
|
|
72
|
-
expect(configFileSelector({})).not.toBeDefined();
|
|
73
|
-
});
|
|
74
|
-
|
|
75
|
-
it(`throws if value stored is undefined`, () => {
|
|
76
|
-
expect(() => {
|
|
77
|
-
configFileSelector({ [CONFIG_ENDPOINT_DISCOVERY]: undefined });
|
|
78
|
-
}).toThrow();
|
|
79
|
-
});
|
|
80
|
-
});
|
|
81
|
-
|
|
82
|
-
it("defaultSelector returns undefined", () => {
|
|
83
|
-
expect(defaultSelector).toBeUndefined();
|
|
84
|
-
});
|
|
85
|
-
});
|
package/src/configurations.ts
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import { LoadedConfigSelectors } from "@aws-sdk/node-config-provider";
|
|
2
|
-
|
|
3
|
-
const ENV_ENDPOINT_DISCOVERY = ["AWS_ENABLE_ENDPOINT_DISCOVERY", "AWS_ENDPOINT_DISCOVERY_ENABLED"];
|
|
4
|
-
const CONFIG_ENDPOINT_DISCOVERY = "endpoint_discovery_enabled";
|
|
5
|
-
|
|
6
|
-
const isFalsy = (value: string) => ["false", "0"].indexOf(value) >= 0;
|
|
7
|
-
|
|
8
|
-
export const NODE_ENDPOINT_DISCOVERY_CONFIG_OPTIONS: LoadedConfigSelectors<boolean | undefined> = {
|
|
9
|
-
environmentVariableSelector: (env) => {
|
|
10
|
-
for (let i = 0; i < ENV_ENDPOINT_DISCOVERY.length; i++) {
|
|
11
|
-
const envKey = ENV_ENDPOINT_DISCOVERY[i];
|
|
12
|
-
if (envKey in env) {
|
|
13
|
-
const value = env[envKey];
|
|
14
|
-
if (value === "") {
|
|
15
|
-
throw Error(`Environment variable ${envKey} can't be empty of undefined, got "${value}"`);
|
|
16
|
-
}
|
|
17
|
-
// @ts-ignore Argument of type 'string | undefined' is not assignable to parameter of type 'string'
|
|
18
|
-
return !isFalsy(value);
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
},
|
|
22
|
-
configFileSelector: (profile) => {
|
|
23
|
-
if (CONFIG_ENDPOINT_DISCOVERY in profile) {
|
|
24
|
-
const value = profile[CONFIG_ENDPOINT_DISCOVERY];
|
|
25
|
-
if (value === undefined) {
|
|
26
|
-
throw Error(`Shared config entry ${CONFIG_ENDPOINT_DISCOVERY} can't be undefined, got "${value}"`);
|
|
27
|
-
}
|
|
28
|
-
return !isFalsy(value);
|
|
29
|
-
}
|
|
30
|
-
},
|
|
31
|
-
default: undefined,
|
|
32
|
-
};
|
|
@@ -1,145 +0,0 @@
|
|
|
1
|
-
import { EndpointCache } from "@aws-sdk/endpoint-cache";
|
|
2
|
-
import { HttpRequest } from "@aws-sdk/protocol-http";
|
|
3
|
-
import { BuildHandlerArguments, MiddlewareStack } from "@aws-sdk/types";
|
|
4
|
-
|
|
5
|
-
import { endpointDiscoveryMiddleware } from "./endpointDiscoveryMiddleware";
|
|
6
|
-
import { getCacheKey } from "./getCacheKey";
|
|
7
|
-
import { updateDiscoveredEndpointInCache } from "./updateDiscoveredEndpointInCache";
|
|
8
|
-
|
|
9
|
-
jest.mock("./updateDiscoveredEndpointInCache");
|
|
10
|
-
jest.mock("./getCacheKey");
|
|
11
|
-
jest.mock("@aws-sdk/protocol-http");
|
|
12
|
-
|
|
13
|
-
describe(endpointDiscoveryMiddleware.name, () => {
|
|
14
|
-
const cacheKey = "cacheKey";
|
|
15
|
-
const endpoint = "endpoint";
|
|
16
|
-
const getEndpoint = jest.fn().mockReturnValue(endpoint);
|
|
17
|
-
const mockConfig = {
|
|
18
|
-
credentials: jest.fn(),
|
|
19
|
-
endpointCache: {
|
|
20
|
-
getEndpoint,
|
|
21
|
-
} as unknown as EndpointCache,
|
|
22
|
-
endpointDiscoveryEnabled: jest.fn().mockResolvedValue(undefined),
|
|
23
|
-
endpointDiscoveryEnabledProvider: jest.fn(),
|
|
24
|
-
endpointDiscoveryCommandCtor: jest.fn(),
|
|
25
|
-
isCustomEndpoint: false,
|
|
26
|
-
isClientEndpointDiscoveryEnabled: false,
|
|
27
|
-
};
|
|
28
|
-
|
|
29
|
-
const mockMiddlewareConfig = {
|
|
30
|
-
isDiscoveredEndpointRequired: false,
|
|
31
|
-
clientStack: {} as MiddlewareStack<any, any>,
|
|
32
|
-
};
|
|
33
|
-
|
|
34
|
-
const mockNext = jest.fn();
|
|
35
|
-
const mockContext = {
|
|
36
|
-
clientName: "ExampleClient",
|
|
37
|
-
commandName: "ExampleCommand",
|
|
38
|
-
};
|
|
39
|
-
const mockArgs = { request: {} };
|
|
40
|
-
|
|
41
|
-
beforeEach(() => {
|
|
42
|
-
(getCacheKey as jest.Mock).mockResolvedValue(cacheKey);
|
|
43
|
-
(updateDiscoveredEndpointInCache as jest.Mock).mockResolvedValue(undefined);
|
|
44
|
-
const { isInstance } = HttpRequest;
|
|
45
|
-
(isInstance as unknown as jest.Mock).mockReturnValue(true);
|
|
46
|
-
});
|
|
47
|
-
|
|
48
|
-
afterEach(() => {
|
|
49
|
-
jest.clearAllMocks();
|
|
50
|
-
});
|
|
51
|
-
|
|
52
|
-
describe(`isCustomEndpoint=true`, () => {
|
|
53
|
-
it(`throw error if isClientEndpointDiscoveryEnabled`, async () => {
|
|
54
|
-
try {
|
|
55
|
-
await endpointDiscoveryMiddleware(
|
|
56
|
-
{ ...mockConfig, isCustomEndpoint: true, isClientEndpointDiscoveryEnabled: true },
|
|
57
|
-
mockMiddlewareConfig
|
|
58
|
-
)(
|
|
59
|
-
mockNext,
|
|
60
|
-
mockContext
|
|
61
|
-
)(mockArgs as BuildHandlerArguments<any>);
|
|
62
|
-
fail("should throw error when isCustomEndpoint=true and isClientEndpointDiscoveryEnabled=true");
|
|
63
|
-
} catch (error) {
|
|
64
|
-
expect(error).toStrictEqual(
|
|
65
|
-
new Error(`Custom endpoint is supplied; endpointDiscoveryEnabled must not be true.`)
|
|
66
|
-
);
|
|
67
|
-
}
|
|
68
|
-
expect(mockNext).not.toHaveBeenCalled();
|
|
69
|
-
expect(updateDiscoveredEndpointInCache).not.toHaveBeenCalled();
|
|
70
|
-
});
|
|
71
|
-
|
|
72
|
-
it(`returns without endpoint discovery`, async () => {
|
|
73
|
-
await endpointDiscoveryMiddleware({ ...mockConfig, isCustomEndpoint: true }, mockMiddlewareConfig)(
|
|
74
|
-
mockNext,
|
|
75
|
-
mockContext
|
|
76
|
-
)(mockArgs as BuildHandlerArguments<any>);
|
|
77
|
-
expect(mockNext).toHaveBeenCalledWith(mockArgs);
|
|
78
|
-
expect(updateDiscoveredEndpointInCache as jest.Mock).not.toHaveBeenCalled();
|
|
79
|
-
});
|
|
80
|
-
});
|
|
81
|
-
|
|
82
|
-
describe(`isDiscoveredEndpointRequired=true`, () => {
|
|
83
|
-
it(`throws error when isEndpointDiscoveryEnabled=false`, async () => {
|
|
84
|
-
mockConfig.endpointDiscoveryEnabled.mockResolvedValueOnce(false);
|
|
85
|
-
try {
|
|
86
|
-
await endpointDiscoveryMiddleware(mockConfig, { ...mockMiddlewareConfig, isDiscoveredEndpointRequired: true })(
|
|
87
|
-
mockNext,
|
|
88
|
-
mockContext
|
|
89
|
-
)(mockArgs as BuildHandlerArguments<any>);
|
|
90
|
-
fail("should throw error when isDiscoveredEndpointRequired=true and isEndpointDiscoveryEnabled=false");
|
|
91
|
-
} catch (error) {
|
|
92
|
-
expect(error).toStrictEqual(
|
|
93
|
-
new Error(
|
|
94
|
-
`Endpoint Discovery is disabled but ${mockContext.commandName} on ${mockContext.clientName} requires it.` +
|
|
95
|
-
` Please check your configurations.`
|
|
96
|
-
)
|
|
97
|
-
);
|
|
98
|
-
}
|
|
99
|
-
expect(mockNext).not.toHaveBeenCalled();
|
|
100
|
-
expect(updateDiscoveredEndpointInCache).not.toHaveBeenCalled();
|
|
101
|
-
});
|
|
102
|
-
|
|
103
|
-
describe(`calls updateDiscoveredEndpointInCache`, () => {
|
|
104
|
-
it(`when isEndpointDiscoveryEnabled=undefined`, async () => {
|
|
105
|
-
await endpointDiscoveryMiddleware(mockConfig, { ...mockMiddlewareConfig, isDiscoveredEndpointRequired: true })(
|
|
106
|
-
mockNext,
|
|
107
|
-
mockContext
|
|
108
|
-
)(mockArgs as BuildHandlerArguments<any>);
|
|
109
|
-
expect(mockNext).toHaveBeenCalledWith(mockArgs);
|
|
110
|
-
expect(mockNext).toHaveBeenCalledWith({ request: { hostname: endpoint } });
|
|
111
|
-
expect(updateDiscoveredEndpointInCache).toHaveBeenCalled();
|
|
112
|
-
});
|
|
113
|
-
|
|
114
|
-
it(`when isEndpointDiscoveryEnabled=true`, async () => {
|
|
115
|
-
mockConfig.endpointDiscoveryEnabled.mockResolvedValueOnce(true);
|
|
116
|
-
await endpointDiscoveryMiddleware(mockConfig, { ...mockMiddlewareConfig, isDiscoveredEndpointRequired: true })(
|
|
117
|
-
mockNext,
|
|
118
|
-
mockContext
|
|
119
|
-
)(mockArgs as BuildHandlerArguments<any>);
|
|
120
|
-
expect(mockNext).toHaveBeenCalledWith(mockArgs);
|
|
121
|
-
expect(mockNext).toHaveBeenCalledWith({ request: { hostname: endpoint } });
|
|
122
|
-
expect(updateDiscoveredEndpointInCache).toHaveBeenCalled();
|
|
123
|
-
});
|
|
124
|
-
});
|
|
125
|
-
|
|
126
|
-
describe(`isDiscoveredEndpointRequired=false`, () => {
|
|
127
|
-
it(`calls updateDiscoveredEndpointInCache when isEndpointDiscoveryEnabled=true`, async () => {
|
|
128
|
-
mockConfig.endpointDiscoveryEnabled.mockResolvedValueOnce(true);
|
|
129
|
-
await endpointDiscoveryMiddleware(mockConfig, mockMiddlewareConfig)(mockNext, mockContext)(
|
|
130
|
-
mockArgs as BuildHandlerArguments<any>
|
|
131
|
-
);
|
|
132
|
-
expect(mockNext).toHaveBeenCalledWith(mockArgs);
|
|
133
|
-
expect(updateDiscoveredEndpointInCache).toHaveBeenCalled();
|
|
134
|
-
});
|
|
135
|
-
|
|
136
|
-
it(`does not call updateDiscoveredEndpointInCache when isEndpointDiscoveryEnabled=false`, async () => {
|
|
137
|
-
await endpointDiscoveryMiddleware(mockConfig, mockMiddlewareConfig)(mockNext, mockContext)(
|
|
138
|
-
mockArgs as BuildHandlerArguments<any>
|
|
139
|
-
);
|
|
140
|
-
expect(mockNext).toHaveBeenCalledWith(mockArgs);
|
|
141
|
-
expect(updateDiscoveredEndpointInCache).not.toHaveBeenCalled();
|
|
142
|
-
});
|
|
143
|
-
});
|
|
144
|
-
});
|
|
145
|
-
});
|
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
import { HttpRequest } from "@aws-sdk/protocol-http";
|
|
2
|
-
import {
|
|
3
|
-
BuildHandler,
|
|
4
|
-
BuildHandlerArguments,
|
|
5
|
-
BuildHandlerOutput,
|
|
6
|
-
HandlerExecutionContext,
|
|
7
|
-
MetadataBearer,
|
|
8
|
-
} from "@aws-sdk/types";
|
|
9
|
-
|
|
10
|
-
import { getCacheKey } from "./getCacheKey";
|
|
11
|
-
import { EndpointDiscoveryMiddlewareConfig } from "./getEndpointDiscoveryPlugin";
|
|
12
|
-
import { EndpointDiscoveryResolvedConfig, PreviouslyResolved } from "./resolveEndpointDiscoveryConfig";
|
|
13
|
-
import { updateDiscoveredEndpointInCache } from "./updateDiscoveredEndpointInCache";
|
|
14
|
-
|
|
15
|
-
export const endpointDiscoveryMiddleware =
|
|
16
|
-
(config: EndpointDiscoveryResolvedConfig & PreviouslyResolved, middlewareConfig: EndpointDiscoveryMiddlewareConfig) =>
|
|
17
|
-
<Output extends MetadataBearer = MetadataBearer>(
|
|
18
|
-
next: BuildHandler<any, Output>,
|
|
19
|
-
context: HandlerExecutionContext
|
|
20
|
-
): BuildHandler<any, Output> =>
|
|
21
|
-
async (args: BuildHandlerArguments<any>): Promise<BuildHandlerOutput<Output>> => {
|
|
22
|
-
if (config.isCustomEndpoint) {
|
|
23
|
-
if (config.isClientEndpointDiscoveryEnabled) {
|
|
24
|
-
throw new Error(`Custom endpoint is supplied; endpointDiscoveryEnabled must not be true.`);
|
|
25
|
-
}
|
|
26
|
-
return next(args);
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
const { endpointDiscoveryCommandCtor } = config;
|
|
30
|
-
const { isDiscoveredEndpointRequired, identifiers } = middlewareConfig;
|
|
31
|
-
const { clientName, commandName } = context;
|
|
32
|
-
const isEndpointDiscoveryEnabled = await config.endpointDiscoveryEnabled();
|
|
33
|
-
const cacheKey = await getCacheKey(commandName, config, { identifiers });
|
|
34
|
-
|
|
35
|
-
if (isDiscoveredEndpointRequired) {
|
|
36
|
-
// throw error if endpoint discovery is required, and it's explicitly disabled.
|
|
37
|
-
if (isEndpointDiscoveryEnabled === false) {
|
|
38
|
-
throw new Error(
|
|
39
|
-
`Endpoint Discovery is disabled but ${commandName} on ${clientName} requires it.` +
|
|
40
|
-
` Please check your configurations.`
|
|
41
|
-
);
|
|
42
|
-
}
|
|
43
|
-
// call await on Endpoint Discovery API utility so that function blocks
|
|
44
|
-
// till discovered endpoint is updated in cache
|
|
45
|
-
await updateDiscoveredEndpointInCache(config, {
|
|
46
|
-
...middlewareConfig,
|
|
47
|
-
commandName,
|
|
48
|
-
cacheKey,
|
|
49
|
-
endpointDiscoveryCommandCtor,
|
|
50
|
-
});
|
|
51
|
-
} else if (isEndpointDiscoveryEnabled) {
|
|
52
|
-
// Discover endpoints only if endpoint discovery is explicitly enabled.
|
|
53
|
-
// Do not call await await on Endpoint Discovery API utility so that function
|
|
54
|
-
// does not block, the command will use discovered endpoint, if available.
|
|
55
|
-
updateDiscoveredEndpointInCache(config, {
|
|
56
|
-
...middlewareConfig,
|
|
57
|
-
commandName,
|
|
58
|
-
cacheKey,
|
|
59
|
-
endpointDiscoveryCommandCtor,
|
|
60
|
-
});
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
const { request } = args;
|
|
64
|
-
if (cacheKey && HttpRequest.isInstance(request)) {
|
|
65
|
-
const endpoint = config.endpointCache.getEndpoint(cacheKey);
|
|
66
|
-
if (endpoint) {
|
|
67
|
-
request.hostname = endpoint;
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
return next(args);
|
|
72
|
-
};
|
package/src/getCacheKey.spec.ts
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import { getCacheKey } from "./getCacheKey";
|
|
2
|
-
|
|
3
|
-
describe(getCacheKey.name, () => {
|
|
4
|
-
const commandName = "commandName";
|
|
5
|
-
const mockCredentials = {
|
|
6
|
-
accessKeyId: "accessKeyId",
|
|
7
|
-
secretAccessKey: "secretAccessKey",
|
|
8
|
-
};
|
|
9
|
-
|
|
10
|
-
const config = {
|
|
11
|
-
credentials: () => Promise.resolve(mockCredentials),
|
|
12
|
-
};
|
|
13
|
-
|
|
14
|
-
it("returns accessKeyId in cacheKey", async () => {
|
|
15
|
-
const cacheKey = await getCacheKey(commandName, config, {});
|
|
16
|
-
expect(cacheKey).toEqual(JSON.stringify({ accessKeyId: mockCredentials.accessKeyId }));
|
|
17
|
-
});
|
|
18
|
-
|
|
19
|
-
it("returns commandName and identifiers if passed", async () => {
|
|
20
|
-
const identifiers = { key: "value" };
|
|
21
|
-
const cacheKey = await getCacheKey(commandName, config, { identifiers });
|
|
22
|
-
expect(cacheKey).toEqual(JSON.stringify({ accessKeyId: mockCredentials.accessKeyId, commandName, identifiers }));
|
|
23
|
-
});
|
|
24
|
-
|
|
25
|
-
it("returns same cache key irrespective of key order in identifiers", async () => {
|
|
26
|
-
const identifiers1 = { key1: "value1", key2: "value2" };
|
|
27
|
-
const cacheKey1 = await getCacheKey(commandName, config, { identifiers: identifiers1 });
|
|
28
|
-
const identifiers2 = { key2: "value2", key1: "value1" };
|
|
29
|
-
const cacheKey2 = await getCacheKey(commandName, config, { identifiers: identifiers2 });
|
|
30
|
-
expect(cacheKey1).toStrictEqual(cacheKey2);
|
|
31
|
-
});
|
|
32
|
-
});
|
package/src/getCacheKey.ts
DELETED
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { Credentials, Provider } from "@aws-sdk/types";
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Generate key to index the endpoints in the cache
|
|
5
|
-
*/
|
|
6
|
-
export const getCacheKey = async (
|
|
7
|
-
commandName: string,
|
|
8
|
-
config: { credentials: Provider<Credentials> },
|
|
9
|
-
options: {
|
|
10
|
-
identifiers?: { [key: string]: string };
|
|
11
|
-
}
|
|
12
|
-
) => {
|
|
13
|
-
const { accessKeyId } = await config.credentials();
|
|
14
|
-
const { identifiers } = options;
|
|
15
|
-
return JSON.stringify({
|
|
16
|
-
...(accessKeyId && { accessKeyId }),
|
|
17
|
-
...(identifiers && {
|
|
18
|
-
commandName,
|
|
19
|
-
identifiers: Object.entries(identifiers)
|
|
20
|
-
.sort()
|
|
21
|
-
.reduce((acc, [key, value]) => ({ ...acc, [key]: value }), {}),
|
|
22
|
-
}),
|
|
23
|
-
});
|
|
24
|
-
};
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import { endpointDiscoveryMiddleware } from "./endpointDiscoveryMiddleware";
|
|
2
|
-
import { endpointDiscoveryMiddlewareOptions, getEndpointDiscoveryPlugin } from "./getEndpointDiscoveryPlugin";
|
|
3
|
-
|
|
4
|
-
jest.mock("./endpointDiscoveryMiddleware");
|
|
5
|
-
|
|
6
|
-
describe(getEndpointDiscoveryPlugin.name, () => {
|
|
7
|
-
const pluginConfig = {
|
|
8
|
-
isCustomEndpoint: false,
|
|
9
|
-
endpointCache: jest.fn(),
|
|
10
|
-
endpointDiscoveryEnabled: jest.fn(),
|
|
11
|
-
isClientEndpointDiscoveryEnabled: false,
|
|
12
|
-
};
|
|
13
|
-
const middlewareConfig = {
|
|
14
|
-
isDiscoveredEndpointRequired: false,
|
|
15
|
-
};
|
|
16
|
-
|
|
17
|
-
it(`applyToStack function adds endpoint discovery middleware`, () => {
|
|
18
|
-
const middlewareReturn = {};
|
|
19
|
-
(endpointDiscoveryMiddleware as jest.Mock).mockReturnValueOnce(middlewareReturn);
|
|
20
|
-
|
|
21
|
-
// @ts-ignore
|
|
22
|
-
const plugin = getEndpointDiscoveryPlugin(pluginConfig, middlewareConfig);
|
|
23
|
-
const commandStack = { add: jest.fn() };
|
|
24
|
-
|
|
25
|
-
// @ts-ignore
|
|
26
|
-
plugin.applyToStack(commandStack);
|
|
27
|
-
expect(commandStack.add).toHaveBeenCalled();
|
|
28
|
-
expect(commandStack.add).toHaveBeenCalledWith(middlewareReturn, endpointDiscoveryMiddlewareOptions);
|
|
29
|
-
expect(endpointDiscoveryMiddleware).toHaveBeenCalled();
|
|
30
|
-
expect(endpointDiscoveryMiddleware).toHaveBeenCalledWith(pluginConfig, middlewareConfig);
|
|
31
|
-
});
|
|
32
|
-
});
|
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
import { BuildHandlerOptions, HttpHandlerOptions, MiddlewareStack, Pluggable } from "@aws-sdk/types";
|
|
2
|
-
|
|
3
|
-
import { endpointDiscoveryMiddleware } from "./endpointDiscoveryMiddleware";
|
|
4
|
-
import { EndpointDiscoveryResolvedConfig, PreviouslyResolved } from "./resolveEndpointDiscoveryConfig";
|
|
5
|
-
|
|
6
|
-
export const endpointDiscoveryMiddlewareOptions: BuildHandlerOptions = {
|
|
7
|
-
name: "endpointDiscoveryMiddleware",
|
|
8
|
-
step: "build",
|
|
9
|
-
tags: ["ENDPOINT_DISCOVERY"],
|
|
10
|
-
override: true,
|
|
11
|
-
};
|
|
12
|
-
|
|
13
|
-
export interface EndpointDiscoveryMiddlewareConfig {
|
|
14
|
-
isDiscoveredEndpointRequired: boolean;
|
|
15
|
-
clientStack: MiddlewareStack<any, any>;
|
|
16
|
-
options?: HttpHandlerOptions;
|
|
17
|
-
identifiers?: { [key: string]: string };
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
export const getEndpointDiscoveryPlugin = (
|
|
21
|
-
pluginConfig: EndpointDiscoveryResolvedConfig & PreviouslyResolved,
|
|
22
|
-
middlewareConfig: EndpointDiscoveryMiddlewareConfig
|
|
23
|
-
): Pluggable<any, any> => ({
|
|
24
|
-
applyToStack: (commandStack) => {
|
|
25
|
-
commandStack.add(endpointDiscoveryMiddleware(pluginConfig, middlewareConfig), endpointDiscoveryMiddlewareOptions);
|
|
26
|
-
},
|
|
27
|
-
});
|
|
28
|
-
|
|
29
|
-
/**
|
|
30
|
-
* @deprecated Use getEndpointDiscoveryPlugin
|
|
31
|
-
*/
|
|
32
|
-
export const getEndpointDiscoveryRequiredPlugin = (
|
|
33
|
-
pluginConfig: EndpointDiscoveryResolvedConfig & PreviouslyResolved,
|
|
34
|
-
middlewareConfig: Omit<EndpointDiscoveryMiddlewareConfig, "isDiscoveredEndpointRequired">
|
|
35
|
-
): Pluggable<any, any> => ({
|
|
36
|
-
applyToStack: (commandStack) => {
|
|
37
|
-
commandStack.add(
|
|
38
|
-
endpointDiscoveryMiddleware(pluginConfig, { ...middlewareConfig, isDiscoveredEndpointRequired: true }),
|
|
39
|
-
endpointDiscoveryMiddlewareOptions
|
|
40
|
-
);
|
|
41
|
-
},
|
|
42
|
-
});
|
|
43
|
-
|
|
44
|
-
/**
|
|
45
|
-
* @deprecated Use getEndpointDiscoveryPlugin
|
|
46
|
-
*/
|
|
47
|
-
export const getEndpointDiscoveryOptionalPlugin = (
|
|
48
|
-
pluginConfig: EndpointDiscoveryResolvedConfig & PreviouslyResolved,
|
|
49
|
-
middlewareConfig: Omit<EndpointDiscoveryMiddlewareConfig, "isDiscoveredEndpointRequired">
|
|
50
|
-
): Pluggable<any, any> => ({
|
|
51
|
-
applyToStack: (commandStack) => {
|
|
52
|
-
commandStack.add(
|
|
53
|
-
endpointDiscoveryMiddleware(pluginConfig, { ...middlewareConfig, isDiscoveredEndpointRequired: false }),
|
|
54
|
-
endpointDiscoveryMiddlewareOptions
|
|
55
|
-
);
|
|
56
|
-
},
|
|
57
|
-
});
|