@aws-sdk/config-resolver
Advanced tools
Comparing version 0.1.0-preview.7 to 1.0.0-alpha.1
@@ -1,5 +0,3 @@ | ||
import { ConfigurationDefinition, MiddlewareStack } from "@aws-sdk/types"; | ||
export declare type IndexedObject = { | ||
[key: string]: any; | ||
}; | ||
export declare function resolveConfiguration<T extends IndexedObject, R extends T, Input extends object, Output extends object, Stream = Uint8Array>(providedConfiguration: T, configurationDefinition: ConfigurationDefinition<T, R>, middlewareStack: MiddlewareStack<Input, Output, Stream>): R; | ||
export * from "./EndpointsConfig"; | ||
export * from "./RegionConfig"; | ||
export * from "./HandlerConfig"; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var tslib_1 = require("tslib"); | ||
function resolveConfiguration(providedConfiguration, configurationDefinition, middlewareStack) { | ||
var e_1, _a; | ||
var out = {}; | ||
var applicators = []; | ||
try { | ||
// Iterate over the definitions own keys, using getOwnPropertyNames to | ||
// guarantee insertion order is preserved. | ||
// @see https://www.ecma-international.org/ecma-262/6.0/#sec-ordinary-object-internal-methods-and-internal-slots-ownpropertykeys | ||
for (var _b = tslib_1.__values(Object.getOwnPropertyNames(configurationDefinition)), _c = _b.next(); !_c.done; _c = _b.next()) { | ||
var property = _c.value; | ||
var _d = configurationDefinition[property], required = _d.required, defaultValue = _d.defaultValue, defaultProvider = _d.defaultProvider, normalize = _d.normalize, apply = _d.apply; | ||
var input = providedConfiguration[property]; | ||
if (input === undefined) { | ||
if (defaultValue !== undefined) { | ||
input = defaultValue; | ||
} | ||
else if (defaultProvider) { | ||
input = defaultProvider(out); | ||
} | ||
else if (required) { | ||
throw new Error("No input provided for required configuration parameter: " + property); | ||
} | ||
} | ||
else if (normalize) { | ||
input = normalize(input, out); | ||
} | ||
out[property] = input; | ||
if (apply) { | ||
applicators.push(apply); | ||
} | ||
} | ||
} | ||
catch (e_1_1) { e_1 = { error: e_1_1 }; } | ||
finally { | ||
try { | ||
if (_c && !_c.done && (_a = _b.return)) _a.call(_b); | ||
} | ||
finally { if (e_1) throw e_1.error; } | ||
} | ||
applicators.forEach(function (func) { return func(out, middlewareStack); }); | ||
return out; | ||
} | ||
exports.resolveConfiguration = resolveConfiguration; | ||
//# sourceMappingURL=index.js.map | ||
tslib_1.__exportStar(require("./EndpointsConfig"), exports); | ||
tslib_1.__exportStar(require("./RegionConfig"), exports); | ||
tslib_1.__exportStar(require("./HandlerConfig"), exports); | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi9zcmMvaW5kZXgudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7O0FBQUEsNERBQWtDO0FBQ2xDLHlEQUErQjtBQUMvQiwwREFBZ0MiLCJzb3VyY2VzQ29udGVudCI6WyJleHBvcnQgKiBmcm9tIFwiLi9FbmRwb2ludHNDb25maWdcIjtcbmV4cG9ydCAqIGZyb20gXCIuL1JlZ2lvbkNvbmZpZ1wiO1xuZXhwb3J0ICogZnJvbSBcIi4vSGFuZGxlckNvbmZpZ1wiO1xuIl19 |
@@ -6,2 +6,49 @@ # Change Log | ||
# [1.0.0-alpha.1](https://github.com/aws/aws-sdk-js-v3/compare/@aws-sdk/config-resolver@0.1.0-preview.2...@aws-sdk/config-resolver@1.0.0-alpha.1) (2020-01-08) | ||
### Bug Fixes | ||
* parseurl in Node returns only pathname when protocol not specified ([#566](https://github.com/aws/aws-sdk-js-v3/issues/566)) ([0454dd6](https://github.com/aws/aws-sdk-js-v3/commit/0454dd6)) | ||
* update input and resolved naming ([#444](https://github.com/aws/aws-sdk-js-v3/issues/444)) ([4235b6c](https://github.com/aws/aws-sdk-js-v3/commit/4235b6c)) | ||
### Features | ||
* add pluggable runtime specific config ([#404](https://github.com/aws/aws-sdk-js-v3/issues/404)) ([8be08fc](https://github.com/aws/aws-sdk-js-v3/commit/8be08fc)) | ||
* remove protocol rest json class ([#438](https://github.com/aws/aws-sdk-js-v3/issues/438)) ([7ec275a](https://github.com/aws/aws-sdk-js-v3/commit/7ec275a)) | ||
* standardize plugins ([#422](https://github.com/aws/aws-sdk-js-v3/issues/422)) ([09112e5](https://github.com/aws/aws-sdk-js-v3/commit/09112e5)) | ||
* start endpoint resolver generation ([#472](https://github.com/aws/aws-sdk-js-v3/issues/472)) ([d0f9250](https://github.com/aws/aws-sdk-js-v3/commit/d0f9250)) | ||
# 0.6.0 (2019-10-30) | ||
# 0.3.0 (2019-09-09) | ||
### Features | ||
* commit all clients ([#324](https://github.com/aws/aws-sdk-js-v3/issues/324)) ([cb268ed](https://github.com/aws/aws-sdk-js-v3/commit/cb268ed)) | ||
# 0.2.0 (2019-07-12) | ||
### Features | ||
* add npm badges for individual packages ([#251](https://github.com/aws/aws-sdk-js-v3/issues/251)) ([8adc10c](https://github.com/aws/aws-sdk-js-v3/commit/8adc10c)) | ||
* update jest v20 to v24 ([#243](https://github.com/aws/aws-sdk-js-v3/issues/243)) ([1e156ab](https://github.com/aws/aws-sdk-js-v3/commit/1e156ab)) | ||
# 0.1.0 (2019-04-19) | ||
# [0.1.0-preview.7](https://github.com/aws/aws-sdk-js-v3/compare/@aws-sdk/config-resolver@0.1.0-preview.2...@aws-sdk/config-resolver@0.1.0-preview.7) (2019-10-30) | ||
@@ -8,0 +55,0 @@ |
{ | ||
"name": "@aws-sdk/config-resolver", | ||
"version": "0.1.0-preview.7", | ||
"version": "1.0.0-alpha.1", | ||
"scripts": { | ||
@@ -23,5 +23,6 @@ "prepublishOnly": "tsc", | ||
"dependencies": { | ||
"@aws-sdk/types": "^0.1.0-preview.7", | ||
"@aws-sdk/signature-v4": "^1.0.0-alpha.1", | ||
"@aws-sdk/types": "^1.0.0-alpha.1", | ||
"tslib": "^1.8.0" | ||
} | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
30028
14
139
3
+ Added@aws-sdk/is-array-buffer@1.0.0-rc.8(transitive)
+ Added@aws-sdk/signature-v4@1.0.0-rc.10(transitive)
+ Added@aws-sdk/types@1.0.0-rc.10(transitive)
+ Added@aws-sdk/util-hex-encoding@1.0.0-rc.8(transitive)
+ Added@aws-sdk/util-uri-escape@1.0.0-rc.8(transitive)
- Removed@aws-sdk/types@0.1.0-preview.7(transitive)