@jjrawlins/cdk-ami-builder 0.0.53 → 0.0.54

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.
Files changed (173) hide show
  1. package/.jsii +11 -11
  2. package/cdk-ami-builder/go.mod +1 -1
  3. package/cdk-ami-builder/jsii/jsii.go +2 -2
  4. package/cdk-ami-builder/version +1 -1
  5. package/lib/ImagePipeline/ImagePipeline.js +1 -1
  6. package/lib/Lambdas/CheckStateMachineStatus/CheckStateMachineStatus-function.js +1 -1
  7. package/lib/Lambdas/StartStateMachine/StartStateMachine-function.js +1 -1
  8. package/node_modules/@aws-sdk/client-ec2/README.md +8 -0
  9. package/node_modules/@aws-sdk/client-ec2/dist-cjs/index.js +175 -78
  10. package/node_modules/@aws-sdk/client-ec2/dist-es/EC2.js +2 -0
  11. package/node_modules/@aws-sdk/client-ec2/dist-es/commands/CopyVolumesCommand.js +22 -0
  12. package/node_modules/@aws-sdk/client-ec2/dist-es/commands/index.js +1 -0
  13. package/node_modules/@aws-sdk/client-ec2/dist-es/models/models_1.js +22 -9
  14. package/node_modules/@aws-sdk/client-ec2/dist-es/models/models_2.js +0 -20
  15. package/node_modules/@aws-sdk/client-ec2/dist-es/models/models_3.js +7 -4
  16. package/node_modules/@aws-sdk/client-ec2/dist-es/models/models_4.js +4 -4
  17. package/node_modules/@aws-sdk/client-ec2/dist-es/models/models_5.js +5 -5
  18. package/node_modules/@aws-sdk/client-ec2/dist-es/models/models_6.js +5 -0
  19. package/node_modules/@aws-sdk/client-ec2/dist-es/protocols/Aws_ec2.js +113 -36
  20. package/node_modules/@aws-sdk/client-ec2/dist-types/EC2.d.ts +7 -0
  21. package/node_modules/@aws-sdk/client-ec2/dist-types/EC2Client.d.ts +3 -2
  22. package/node_modules/@aws-sdk/client-ec2/dist-types/commands/CopyVolumesCommand.d.ts +137 -0
  23. package/node_modules/@aws-sdk/client-ec2/dist-types/commands/CreateVolumeCommand.d.ts +3 -1
  24. package/node_modules/@aws-sdk/client-ec2/dist-types/commands/DescribeCapacityReservationBillingRequestsCommand.d.ts +1 -2
  25. package/node_modules/@aws-sdk/client-ec2/dist-types/commands/DescribeVolumeStatusCommand.d.ts +3 -2
  26. package/node_modules/@aws-sdk/client-ec2/dist-types/commands/DescribeVolumesCommand.d.ts +1 -0
  27. package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetManagedPrefixListEntriesCommand.d.ts +2 -1
  28. package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetNetworkInsightsAccessScopeAnalysisFindingsCommand.d.ts +1 -2
  29. package/node_modules/@aws-sdk/client-ec2/dist-types/commands/ProvisionIpamByoasnCommand.d.ts +1 -1
  30. package/node_modules/@aws-sdk/client-ec2/dist-types/commands/index.d.ts +1 -0
  31. package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_1.d.ts +309 -115
  32. package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_2.d.ts +104 -227
  33. package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_3.d.ts +45 -83
  34. package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_4.d.ts +83 -30
  35. package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_5.d.ts +37 -32
  36. package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_6.d.ts +32 -46
  37. package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_7.d.ts +52 -43
  38. package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_8.d.ts +44 -7
  39. package/node_modules/@aws-sdk/client-ec2/dist-types/protocols/Aws_ec2.d.ts +9 -0
  40. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/EC2.d.ts +17 -0
  41. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/EC2Client.d.ts +6 -0
  42. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/CopyVolumesCommand.d.ts +47 -0
  43. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/CreateVolumeCommand.d.ts +2 -1
  44. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/DescribeCapacityReservationBillingRequestsCommand.d.ts +4 -2
  45. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/DescribeVolumeStatusCommand.d.ts +2 -4
  46. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/GetManagedPrefixListEntriesCommand.d.ts +2 -4
  47. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/GetNetworkInsightsAccessScopeAnalysisFindingsCommand.d.ts +4 -2
  48. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/ProvisionIpamByoasnCommand.d.ts +1 -1
  49. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/index.d.ts +1 -0
  50. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_1.d.ts +67 -31
  51. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_2.d.ts +18 -57
  52. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_3.d.ts +14 -15
  53. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_4.d.ts +13 -10
  54. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_5.d.ts +13 -14
  55. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_6.d.ts +13 -12
  56. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_7.d.ts +12 -11
  57. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_8.d.ts +12 -1
  58. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/protocols/Aws_ec2.d.ts +12 -0
  59. package/node_modules/@aws-sdk/client-ec2/package.json +35 -35
  60. package/node_modules/@aws-sdk/client-ecs/package.json +34 -34
  61. package/node_modules/@aws-sdk/client-kms/dist-types/models/models_0.d.ts +3 -3
  62. package/node_modules/@aws-sdk/client-kms/package.json +33 -33
  63. package/node_modules/@aws-sdk/client-s3/dist-types/models/models_0.d.ts +4 -4
  64. package/node_modules/@aws-sdk/client-s3/package.json +50 -50
  65. package/node_modules/@aws-sdk/client-secrets-manager/package.json +33 -33
  66. package/node_modules/@aws-sdk/client-sfn/package.json +33 -33
  67. package/node_modules/@aws-sdk/client-sns/package.json +33 -33
  68. package/node_modules/@aws-sdk/client-sqs/dist-types/models/models_0.d.ts +1 -1
  69. package/node_modules/@aws-sdk/client-sqs/package.json +35 -35
  70. package/node_modules/@aws-sdk/client-ssm/package.json +34 -34
  71. package/node_modules/@aws-sdk/client-sso/package.json +32 -32
  72. package/node_modules/@aws-sdk/core/dist-cjs/index.js +5 -5
  73. package/node_modules/@aws-sdk/core/dist-cjs/submodules/protocols/index.js +5 -5
  74. package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/cbor/AwsSmithyRpcV2CborProtocol.js +1 -1
  75. package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/AwsJsonRpcProtocol.js +1 -1
  76. package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/AwsRestJsonProtocol.js +1 -1
  77. package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/query/AwsQueryProtocol.js +1 -1
  78. package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/xml/AwsRestXmlProtocol.js +1 -1
  79. package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/ProtocolLib.d.ts +4 -4
  80. package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/ProtocolLib.d.ts +7 -7
  81. package/node_modules/@aws-sdk/core/package.json +11 -11
  82. package/node_modules/@aws-sdk/credential-provider-env/package.json +5 -5
  83. package/node_modules/@aws-sdk/credential-provider-http/package.json +10 -10
  84. package/node_modules/@aws-sdk/credential-provider-ini/package.json +13 -13
  85. package/node_modules/@aws-sdk/credential-provider-node/package.json +12 -12
  86. package/node_modules/@aws-sdk/credential-provider-process/package.json +6 -6
  87. package/node_modules/@aws-sdk/credential-provider-sso/package.json +8 -8
  88. package/node_modules/@aws-sdk/credential-provider-web-identity/package.json +7 -7
  89. package/node_modules/@aws-sdk/middleware-bucket-endpoint/dist-cjs/index.js +334 -450
  90. package/node_modules/@aws-sdk/middleware-bucket-endpoint/package.json +5 -5
  91. package/node_modules/@aws-sdk/middleware-expect-continue/dist-cjs/index.js +30 -60
  92. package/node_modules/@aws-sdk/middleware-expect-continue/package.json +4 -4
  93. package/node_modules/@aws-sdk/middleware-flexible-checksums/package.json +9 -9
  94. package/node_modules/@aws-sdk/middleware-host-header/dist-cjs/index.js +35 -63
  95. package/node_modules/@aws-sdk/middleware-host-header/package.json +4 -4
  96. package/node_modules/@aws-sdk/middleware-location-constraint/dist-cjs/index.js +26 -57
  97. package/node_modules/@aws-sdk/middleware-location-constraint/package.json +3 -3
  98. package/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js +44 -75
  99. package/node_modules/@aws-sdk/middleware-logger/package.json +3 -3
  100. package/node_modules/@aws-sdk/middleware-recursion-detection/dist-cjs/index.js +19 -48
  101. package/node_modules/@aws-sdk/middleware-recursion-detection/package.json +4 -4
  102. package/node_modules/@aws-sdk/middleware-sdk-ec2/package.json +8 -8
  103. package/node_modules/@aws-sdk/middleware-sdk-s3/package.json +11 -11
  104. package/node_modules/@aws-sdk/middleware-sdk-sqs/package.json +4 -4
  105. package/node_modules/@aws-sdk/middleware-ssec/dist-cjs/index.js +65 -92
  106. package/node_modules/@aws-sdk/middleware-ssec/package.json +3 -3
  107. package/node_modules/@aws-sdk/middleware-user-agent/package.json +7 -7
  108. package/node_modules/@aws-sdk/nested-clients/package.json +32 -32
  109. package/node_modules/@aws-sdk/region-config-resolver/dist-cjs/index.js +59 -95
  110. package/node_modules/@aws-sdk/region-config-resolver/package.json +5 -5
  111. package/node_modules/@aws-sdk/signature-v4-multi-region/package.json +6 -6
  112. package/node_modules/@aws-sdk/token-providers/package.json +7 -7
  113. package/node_modules/@aws-sdk/types/dist-cjs/index.js +18 -290
  114. package/node_modules/@aws-sdk/types/package.json +2 -2
  115. package/node_modules/@aws-sdk/util-endpoints/dist-cjs/index.js +395 -469
  116. package/node_modules/@aws-sdk/util-endpoints/package.json +5 -5
  117. package/node_modules/@aws-sdk/util-format-url/dist-cjs/index.js +30 -58
  118. package/node_modules/@aws-sdk/util-format-url/package.json +4 -4
  119. package/node_modules/@aws-sdk/util-user-agent-browser/package.json +3 -3
  120. package/node_modules/@aws-sdk/util-user-agent-node/package.json +5 -5
  121. package/node_modules/@aws-sdk/xml-builder/dist-cjs/index.js +106 -160
  122. package/node_modules/@aws-sdk/xml-builder/package.json +2 -2
  123. package/node_modules/@smithy/abort-controller/package.json +2 -2
  124. package/node_modules/@smithy/config-resolver/package.json +4 -4
  125. package/node_modules/@smithy/core/dist-cjs/submodules/schema/index.js +74 -61
  126. package/node_modules/@smithy/core/dist-es/submodules/schema/TypeRegistry.js +16 -9
  127. package/node_modules/@smithy/core/dist-es/submodules/schema/schemas/NormalizedSchema.js +2 -2
  128. package/node_modules/@smithy/core/dist-es/submodules/schema/schemas/Schema.js +0 -2
  129. package/node_modules/@smithy/core/dist-es/submodules/schema/schemas/SimpleSchema.js +6 -0
  130. package/node_modules/@smithy/core/dist-types/submodules/schema/TypeRegistry.d.ts +1 -2
  131. package/node_modules/@smithy/core/dist-types/submodules/schema/schemas/SimpleSchema.d.ts +5 -0
  132. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/schema/TypeRegistry.d.ts +1 -2
  133. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/schema/schemas/SimpleSchema.d.ts +5 -0
  134. package/node_modules/@smithy/core/package.json +7 -7
  135. package/node_modules/@smithy/credential-provider-imds/package.json +5 -5
  136. package/node_modules/@smithy/eventstream-codec/package.json +2 -2
  137. package/node_modules/@smithy/eventstream-serde-browser/package.json +3 -3
  138. package/node_modules/@smithy/eventstream-serde-config-resolver/package.json +2 -2
  139. package/node_modules/@smithy/eventstream-serde-node/package.json +3 -3
  140. package/node_modules/@smithy/eventstream-serde-universal/package.json +3 -3
  141. package/node_modules/@smithy/fetch-http-handler/package.json +5 -5
  142. package/node_modules/@smithy/hash-blob-browser/package.json +2 -2
  143. package/node_modules/@smithy/hash-node/package.json +2 -2
  144. package/node_modules/@smithy/hash-stream-node/package.json +2 -2
  145. package/node_modules/@smithy/invalid-dependency/package.json +2 -2
  146. package/node_modules/@smithy/md5-js/package.json +2 -2
  147. package/node_modules/@smithy/middleware-content-length/package.json +3 -3
  148. package/node_modules/@smithy/middleware-endpoint/package.json +8 -8
  149. package/node_modules/@smithy/middleware-retry/package.json +8 -8
  150. package/node_modules/@smithy/middleware-serde/package.json +3 -3
  151. package/node_modules/@smithy/middleware-stack/package.json +2 -2
  152. package/node_modules/@smithy/node-config-provider/package.json +4 -4
  153. package/node_modules/@smithy/node-http-handler/package.json +5 -5
  154. package/node_modules/@smithy/property-provider/package.json +2 -2
  155. package/node_modules/@smithy/protocol-http/package.json +2 -2
  156. package/node_modules/@smithy/querystring-builder/package.json +2 -2
  157. package/node_modules/@smithy/querystring-parser/package.json +2 -2
  158. package/node_modules/@smithy/service-error-classification/package.json +2 -2
  159. package/node_modules/@smithy/shared-ini-file-loader/package.json +2 -2
  160. package/node_modules/@smithy/signature-v4/package.json +4 -4
  161. package/node_modules/@smithy/smithy-client/package.json +7 -7
  162. package/node_modules/@smithy/types/dist-types/schema/static-schemas.d.ts +1 -1
  163. package/node_modules/@smithy/types/dist-types/ts3.4/schema/static-schemas.d.ts +2 -2
  164. package/node_modules/@smithy/types/package.json +1 -1
  165. package/node_modules/@smithy/url-parser/package.json +3 -3
  166. package/node_modules/@smithy/util-defaults-mode-browser/package.json +4 -4
  167. package/node_modules/@smithy/util-defaults-mode-node/package.json +7 -7
  168. package/node_modules/@smithy/util-endpoints/package.json +3 -3
  169. package/node_modules/@smithy/util-middleware/package.json +2 -2
  170. package/node_modules/@smithy/util-retry/package.json +3 -3
  171. package/node_modules/@smithy/util-stream/package.json +4 -4
  172. package/node_modules/@smithy/util-waiter/package.json +3 -3
  173. package/package.json +13 -13
@@ -10,72 +10,12 @@ const deref = (schemaRef) => {
10
10
  return schemaRef;
11
11
  };
12
12
 
13
- class TypeRegistry {
14
- namespace;
15
- schemas;
16
- exceptions;
17
- static registries = new Map();
18
- constructor(namespace, schemas = new Map(), exceptions = new Map()) {
19
- this.namespace = namespace;
20
- this.schemas = schemas;
21
- this.exceptions = exceptions;
22
- }
23
- static for(namespace) {
24
- if (!TypeRegistry.registries.has(namespace)) {
25
- TypeRegistry.registries.set(namespace, new TypeRegistry(namespace));
26
- }
27
- return TypeRegistry.registries.get(namespace);
28
- }
29
- register(shapeId, schema) {
30
- const qualifiedName = this.normalizeShapeId(shapeId);
31
- this.schemas.set(qualifiedName, schema);
32
- }
33
- getSchema(shapeId) {
34
- const id = this.normalizeShapeId(shapeId);
35
- if (!this.schemas.has(id)) {
36
- throw new Error(`@smithy/core/schema - schema not found for ${id}`);
37
- }
38
- return this.schemas.get(id);
39
- }
40
- registerError(es, ctor) {
41
- this.exceptions.set(es, ctor);
42
- }
43
- getErrorCtor(es) {
44
- return this.exceptions.get(es);
45
- }
46
- getBaseException() {
47
- for (const [id, schema] of this.schemas.entries()) {
48
- if (id.startsWith("smithy.ts.sdk.synthetic.") && id.endsWith("ServiceException")) {
49
- return schema;
50
- }
51
- }
52
- return undefined;
53
- }
54
- find(predicate) {
55
- return [...this.schemas.values()].find(predicate);
56
- }
57
- clear() {
58
- this.schemas.clear();
59
- this.exceptions.clear();
60
- }
61
- normalizeShapeId(shapeId) {
62
- if (shapeId.includes("#")) {
63
- return shapeId;
64
- }
65
- return this.namespace + "#" + shapeId;
66
- }
67
- getNamespace(shapeId) {
68
- return this.normalizeShapeId(shapeId).split("#")[0];
69
- }
70
- }
71
-
72
13
  class Schema {
73
14
  name;
74
15
  namespace;
75
16
  traits;
76
17
  static assign(instance, values) {
77
18
  const schema = Object.assign(instance, values);
78
- TypeRegistry.for(schema.namespace).register(schema.name, schema);
79
19
  return schema;
80
20
  }
81
21
  static [Symbol.hasInstance](lhs) {
@@ -180,6 +120,12 @@ const sim = (namespace, name, schemaRef, traits) => Schema.assign(new SimpleSche
180
120
  traits,
181
121
  schemaRef,
182
122
  });
123
+ const simAdapter = (namespace, name, traits, schemaRef) => Schema.assign(new SimpleSchema(), {
124
+ name,
125
+ namespace,
126
+ traits,
127
+ schemaRef,
128
+ });
183
129
 
184
130
  function translateTraits(indicator) {
185
131
  if (typeof indicator === "object") {
@@ -446,7 +392,7 @@ function member(memberSchema, memberName) {
446
392
  function hydrate(ss) {
447
393
  const [id, ...rest] = ss;
448
394
  return {
449
- [0]: sim,
395
+ [0]: simAdapter,
450
396
  [1]: list,
451
397
  [2]: map,
452
398
  [3]: struct,
@@ -577,6 +523,72 @@ const SCHEMA = {
577
523
  MAP_MODIFIER: 0b1000_0000,
578
524
  };
579
525
 
526
+ class TypeRegistry {
527
+ namespace;
528
+ schemas;
529
+ exceptions;
530
+ static registries = new Map();
531
+ constructor(namespace, schemas = new Map(), exceptions = new Map()) {
532
+ this.namespace = namespace;
533
+ this.schemas = schemas;
534
+ this.exceptions = exceptions;
535
+ }
536
+ static for(namespace) {
537
+ if (!TypeRegistry.registries.has(namespace)) {
538
+ TypeRegistry.registries.set(namespace, new TypeRegistry(namespace));
539
+ }
540
+ return TypeRegistry.registries.get(namespace);
541
+ }
542
+ register(shapeId, schema) {
543
+ const qualifiedName = this.normalizeShapeId(shapeId);
544
+ const registry = TypeRegistry.for(qualifiedName.split("#")[0]);
545
+ registry.schemas.set(qualifiedName, schema);
546
+ }
547
+ getSchema(shapeId) {
548
+ const id = this.normalizeShapeId(shapeId);
549
+ if (!this.schemas.has(id)) {
550
+ throw new Error(`@smithy/core/schema - schema not found for ${id}`);
551
+ }
552
+ return this.schemas.get(id);
553
+ }
554
+ registerError(es, ctor) {
555
+ const $error = es;
556
+ const registry = TypeRegistry.for($error[1]);
557
+ registry.schemas.set($error[1] + "#" + $error[2], $error);
558
+ registry.exceptions.set($error, ctor);
559
+ }
560
+ getErrorCtor(es) {
561
+ const $error = es;
562
+ const registry = TypeRegistry.for($error[1]);
563
+ return registry.exceptions.get(es);
564
+ }
565
+ getBaseException() {
566
+ for (const exceptionKey of this.exceptions.keys()) {
567
+ if (Array.isArray(exceptionKey)) {
568
+ const [, ns, name] = exceptionKey;
569
+ const id = ns + "#" + name;
570
+ if (id.startsWith("smithy.ts.sdk.synthetic.") && id.endsWith("ServiceException")) {
571
+ return exceptionKey;
572
+ }
573
+ }
574
+ }
575
+ return undefined;
576
+ }
577
+ find(predicate) {
578
+ return [...this.schemas.values()].find(predicate);
579
+ }
580
+ clear() {
581
+ this.schemas.clear();
582
+ this.exceptions.clear();
583
+ }
584
+ normalizeShapeId(shapeId) {
585
+ if (shapeId.includes("#")) {
586
+ return shapeId;
587
+ }
588
+ return this.namespace + "#" + shapeId;
589
+ }
590
+ }
591
+
580
592
  exports.ErrorSchema = ErrorSchema;
581
593
  exports.ListSchema = ListSchema;
582
594
  exports.MapSchema = MapSchema;
@@ -598,5 +610,6 @@ exports.map = map;
598
610
  exports.op = op;
599
611
  exports.serializerMiddlewareOption = serializerMiddlewareOption;
600
612
  exports.sim = sim;
613
+ exports.simAdapter = simAdapter;
601
614
  exports.struct = struct;
602
615
  exports.translateTraits = translateTraits;
@@ -16,7 +16,8 @@ export class TypeRegistry {
16
16
  }
17
17
  register(shapeId, schema) {
18
18
  const qualifiedName = this.normalizeShapeId(shapeId);
19
- this.schemas.set(qualifiedName, schema);
19
+ const registry = TypeRegistry.for(qualifiedName.split("#")[0]);
20
+ registry.schemas.set(qualifiedName, schema);
20
21
  }
21
22
  getSchema(shapeId) {
22
23
  const id = this.normalizeShapeId(shapeId);
@@ -26,15 +27,24 @@ export class TypeRegistry {
26
27
  return this.schemas.get(id);
27
28
  }
28
29
  registerError(es, ctor) {
29
- this.exceptions.set(es, ctor);
30
+ const $error = es;
31
+ const registry = TypeRegistry.for($error[1]);
32
+ registry.schemas.set($error[1] + "#" + $error[2], $error);
33
+ registry.exceptions.set($error, ctor);
30
34
  }
31
35
  getErrorCtor(es) {
32
- return this.exceptions.get(es);
36
+ const $error = es;
37
+ const registry = TypeRegistry.for($error[1]);
38
+ return registry.exceptions.get(es);
33
39
  }
34
40
  getBaseException() {
35
- for (const [id, schema] of this.schemas.entries()) {
36
- if (id.startsWith("smithy.ts.sdk.synthetic.") && id.endsWith("ServiceException")) {
37
- return schema;
41
+ for (const exceptionKey of this.exceptions.keys()) {
42
+ if (Array.isArray(exceptionKey)) {
43
+ const [, ns, name] = exceptionKey;
44
+ const id = ns + "#" + name;
45
+ if (id.startsWith("smithy.ts.sdk.synthetic.") && id.endsWith("ServiceException")) {
46
+ return exceptionKey;
47
+ }
38
48
  }
39
49
  }
40
50
  return undefined;
@@ -52,7 +62,4 @@ export class TypeRegistry {
52
62
  }
53
63
  return this.namespace + "#" + shapeId;
54
64
  }
55
- getNamespace(shapeId) {
56
- return this.normalizeShapeId(shapeId).split("#")[0];
57
- }
58
65
  }
@@ -4,7 +4,7 @@ import { list, ListSchema } from "./ListSchema";
4
4
  import { map, MapSchema } from "./MapSchema";
5
5
  import { op } from "./OperationSchema";
6
6
  import { Schema } from "./Schema";
7
- import { sim } from "./SimpleSchema";
7
+ import { simAdapter } from "./SimpleSchema";
8
8
  import { struct, StructureSchema } from "./StructureSchema";
9
9
  import { translateTraits } from "./translateTraits";
10
10
  export class NormalizedSchema {
@@ -249,7 +249,7 @@ function member(memberSchema, memberName) {
249
249
  export function hydrate(ss) {
250
250
  const [id, ...rest] = ss;
251
251
  return {
252
- [0]: sim,
252
+ [0]: simAdapter,
253
253
  [1]: list,
254
254
  [2]: map,
255
255
  [3]: struct,
@@ -1,11 +1,9 @@
1
- import { TypeRegistry } from "../TypeRegistry";
2
1
  export class Schema {
3
2
  name;
4
3
  namespace;
5
4
  traits;
6
5
  static assign(instance, values) {
7
6
  const schema = Object.assign(instance, values);
8
- TypeRegistry.for(schema.namespace).register(schema.name, schema);
9
7
  return schema;
10
8
  }
11
9
  static [Symbol.hasInstance](lhs) {
@@ -12,3 +12,9 @@ export const sim = (namespace, name, schemaRef, traits) => Schema.assign(new Sim
12
12
  traits,
13
13
  schemaRef,
14
14
  });
15
+ export const simAdapter = (namespace, name, traits, schemaRef) => Schema.assign(new SimpleSchema(), {
16
+ name,
17
+ namespace,
18
+ traits,
19
+ schemaRef,
20
+ });
@@ -50,7 +50,7 @@ export declare class TypeRegistry {
50
50
  *
51
51
  * @returns the synthetic base exception of the service namespace associated with this registry instance.
52
52
  */
53
- getBaseException(): ErrorSchema | undefined;
53
+ getBaseException(): StaticErrorSchema | undefined;
54
54
  /**
55
55
  * @param predicate - criterion.
56
56
  * @returns a schema in this registry matching the predicate.
@@ -61,5 +61,4 @@ export declare class TypeRegistry {
61
61
  */
62
62
  clear(): void;
63
63
  private normalizeShapeId;
64
- private getNamespace;
65
64
  }
@@ -19,3 +19,8 @@ export declare class SimpleSchema extends Schema implements TraitsSchema {
19
19
  * @internal
20
20
  */
21
21
  export declare const sim: (namespace: string, name: string, schemaRef: SchemaRef, traits: SchemaTraits) => SimpleSchema;
22
+ /**
23
+ * @internal
24
+ * @deprecated
25
+ */
26
+ export declare const simAdapter: (namespace: string, name: string, traits: SchemaTraits, schemaRef: SchemaRef) => SimpleSchema;
@@ -50,7 +50,7 @@ export declare class TypeRegistry {
50
50
  *
51
51
  * @returns the synthetic base exception of the service namespace associated with this registry instance.
52
52
  */
53
- getBaseException(): ErrorSchema | undefined;
53
+ getBaseException(): StaticErrorSchema | undefined;
54
54
  /**
55
55
  * @param predicate - criterion.
56
56
  * @returns a schema in this registry matching the predicate.
@@ -61,5 +61,4 @@ export declare class TypeRegistry {
61
61
  */
62
62
  clear(): void;
63
63
  private normalizeShapeId;
64
- private getNamespace;
65
64
  }
@@ -19,3 +19,8 @@ export declare class SimpleSchema extends Schema implements TraitsSchema {
19
19
  * @internal
20
20
  */
21
21
  export declare const sim: (namespace: string, name: string, schemaRef: SchemaRef, traits: SchemaTraits) => SimpleSchema;
22
+ /**
23
+ * @internal
24
+ * @deprecated
25
+ */
26
+ export declare const simAdapter: (namespace: string, name: string, traits: SchemaTraits, schemaRef: SchemaRef) => SimpleSchema;
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/core",
3
- "version": "3.16.0",
3
+ "version": "3.16.1",
4
4
  "scripts": {
5
5
  "build": "yarn lint && concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
6
6
  "build:cjs": "node ../../scripts/inline core",
@@ -77,13 +77,13 @@
77
77
  "license": "Apache-2.0",
78
78
  "sideEffects": false,
79
79
  "dependencies": {
80
- "@smithy/middleware-serde": "^4.2.1",
81
- "@smithy/protocol-http": "^5.3.1",
82
- "@smithy/types": "^4.7.0",
80
+ "@smithy/middleware-serde": "^4.2.2",
81
+ "@smithy/protocol-http": "^5.3.2",
82
+ "@smithy/types": "^4.7.1",
83
83
  "@smithy/util-base64": "^4.3.0",
84
84
  "@smithy/util-body-length-browser": "^4.2.0",
85
- "@smithy/util-middleware": "^4.2.1",
86
- "@smithy/util-stream": "^4.5.1",
85
+ "@smithy/util-middleware": "^4.2.2",
86
+ "@smithy/util-stream": "^4.5.2",
87
87
  "@smithy/util-utf8": "^4.2.0",
88
88
  "@smithy/uuid": "^1.1.0",
89
89
  "tslib": "^2.6.2"
@@ -118,7 +118,7 @@
118
118
  "directory": "packages/core"
119
119
  },
120
120
  "devDependencies": {
121
- "@smithy/eventstream-serde-node": "^4.2.1",
121
+ "@smithy/eventstream-serde-node": "^4.2.2",
122
122
  "@types/node": "^18.11.9",
123
123
  "concurrently": "7.0.0",
124
124
  "downlevel-dts": "0.10.1",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/credential-provider-imds",
3
- "version": "4.2.1",
3
+ "version": "4.2.2",
4
4
  "description": "AWS credential provider that sources credentials from the EC2 instance metadata service and ECS container metadata service",
5
5
  "main": "./dist-cjs/index.js",
6
6
  "module": "./dist-es/index.js",
@@ -28,10 +28,10 @@
28
28
  "license": "Apache-2.0",
29
29
  "sideEffects": false,
30
30
  "dependencies": {
31
- "@smithy/node-config-provider": "^4.3.1",
32
- "@smithy/property-provider": "^4.2.1",
33
- "@smithy/types": "^4.7.0",
34
- "@smithy/url-parser": "^4.2.1",
31
+ "@smithy/node-config-provider": "^4.3.2",
32
+ "@smithy/property-provider": "^4.2.2",
33
+ "@smithy/types": "^4.7.1",
34
+ "@smithy/url-parser": "^4.2.2",
35
35
  "tslib": "^2.6.2"
36
36
  },
37
37
  "devDependencies": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/eventstream-codec",
3
- "version": "4.2.1",
3
+ "version": "4.2.2",
4
4
  "scripts": {
5
5
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
6
6
  "build:cjs": "node ../../scripts/inline eventstream-codec",
@@ -25,7 +25,7 @@
25
25
  "sideEffects": false,
26
26
  "dependencies": {
27
27
  "@aws-crypto/crc32": "5.2.0",
28
- "@smithy/types": "^4.7.0",
28
+ "@smithy/types": "^4.7.1",
29
29
  "@smithy/util-hex-encoding": "^4.2.0",
30
30
  "tslib": "^2.6.2"
31
31
  },
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/eventstream-serde-browser",
3
- "version": "4.2.1",
3
+ "version": "4.2.2",
4
4
  "scripts": {
5
5
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
6
6
  "build:cjs": "node ../../scripts/inline eventstream-serde-browser",
@@ -23,8 +23,8 @@
23
23
  "license": "Apache-2.0",
24
24
  "sideEffects": false,
25
25
  "dependencies": {
26
- "@smithy/eventstream-serde-universal": "^4.2.1",
27
- "@smithy/types": "^4.7.0",
26
+ "@smithy/eventstream-serde-universal": "^4.2.2",
27
+ "@smithy/types": "^4.7.1",
28
28
  "tslib": "^2.6.2"
29
29
  },
30
30
  "engines": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/eventstream-serde-config-resolver",
3
- "version": "4.3.1",
3
+ "version": "4.3.2",
4
4
  "scripts": {
5
5
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
6
6
  "build:cjs": "node ../../scripts/inline eventstream-serde-config-resolver",
@@ -25,7 +25,7 @@
25
25
  "license": "Apache-2.0",
26
26
  "sideEffects": false,
27
27
  "dependencies": {
28
- "@smithy/types": "^4.7.0",
28
+ "@smithy/types": "^4.7.1",
29
29
  "tslib": "^2.6.2"
30
30
  },
31
31
  "engines": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/eventstream-serde-node",
3
- "version": "4.2.1",
3
+ "version": "4.2.2",
4
4
  "scripts": {
5
5
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
6
6
  "build:cjs": "node ../../scripts/inline eventstream-serde-node",
@@ -23,8 +23,8 @@
23
23
  "license": "Apache-2.0",
24
24
  "sideEffects": false,
25
25
  "dependencies": {
26
- "@smithy/eventstream-serde-universal": "^4.2.1",
27
- "@smithy/types": "^4.7.0",
26
+ "@smithy/eventstream-serde-universal": "^4.2.2",
27
+ "@smithy/types": "^4.7.1",
28
28
  "tslib": "^2.6.2"
29
29
  },
30
30
  "devDependencies": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/eventstream-serde-universal",
3
- "version": "4.2.1",
3
+ "version": "4.2.2",
4
4
  "scripts": {
5
5
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
6
6
  "build:cjs": "node ../../scripts/inline eventstream-serde-universal",
@@ -26,8 +26,8 @@
26
26
  "license": "Apache-2.0",
27
27
  "sideEffects": false,
28
28
  "dependencies": {
29
- "@smithy/eventstream-codec": "^4.2.1",
30
- "@smithy/types": "^4.7.0",
29
+ "@smithy/eventstream-codec": "^4.2.2",
30
+ "@smithy/types": "^4.7.1",
31
31
  "tslib": "^2.6.2"
32
32
  },
33
33
  "devDependencies": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/fetch-http-handler",
3
- "version": "5.3.2",
3
+ "version": "5.3.3",
4
4
  "description": "Provides a way to make requests",
5
5
  "scripts": {
6
6
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
@@ -28,14 +28,14 @@
28
28
  "module": "./dist-es/index.js",
29
29
  "types": "./dist-types/index.d.ts",
30
30
  "dependencies": {
31
- "@smithy/protocol-http": "^5.3.1",
32
- "@smithy/querystring-builder": "^4.2.1",
33
- "@smithy/types": "^4.7.0",
31
+ "@smithy/protocol-http": "^5.3.2",
32
+ "@smithy/querystring-builder": "^4.2.2",
33
+ "@smithy/types": "^4.7.1",
34
34
  "@smithy/util-base64": "^4.3.0",
35
35
  "tslib": "^2.6.2"
36
36
  },
37
37
  "devDependencies": {
38
- "@smithy/abort-controller": "^4.2.1",
38
+ "@smithy/abort-controller": "^4.2.2",
39
39
  "concurrently": "7.0.0",
40
40
  "downlevel-dts": "0.10.1",
41
41
  "rimraf": "3.0.2",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/hash-blob-browser",
3
- "version": "4.2.2",
3
+ "version": "4.2.3",
4
4
  "scripts": {
5
5
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
6
6
  "build:cjs": "node ../../scripts/inline hash-blob-browser",
@@ -26,7 +26,7 @@
26
26
  "dependencies": {
27
27
  "@smithy/chunked-blob-reader": "^5.2.0",
28
28
  "@smithy/chunked-blob-reader-native": "^4.2.1",
29
- "@smithy/types": "^4.7.0",
29
+ "@smithy/types": "^4.7.1",
30
30
  "tslib": "^2.6.2"
31
31
  },
32
32
  "devDependencies": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/hash-node",
3
- "version": "4.2.1",
3
+ "version": "4.2.2",
4
4
  "scripts": {
5
5
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
6
6
  "build:cjs": "node ../../scripts/inline hash-node",
@@ -32,7 +32,7 @@
32
32
  "typedoc": "0.23.23"
33
33
  },
34
34
  "dependencies": {
35
- "@smithy/types": "^4.7.0",
35
+ "@smithy/types": "^4.7.1",
36
36
  "@smithy/util-buffer-from": "^4.2.0",
37
37
  "@smithy/util-utf8": "^4.2.0",
38
38
  "tslib": "^2.6.2"
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/hash-stream-node",
3
- "version": "4.2.1",
3
+ "version": "4.2.2",
4
4
  "scripts": {
5
5
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
6
6
  "build:cjs": "node ../../scripts/inline hash-stream-node",
@@ -24,7 +24,7 @@
24
24
  "license": "Apache-2.0",
25
25
  "sideEffects": false,
26
26
  "dependencies": {
27
- "@smithy/types": "^4.7.0",
27
+ "@smithy/types": "^4.7.1",
28
28
  "@smithy/util-utf8": "^4.2.0",
29
29
  "tslib": "^2.6.2"
30
30
  },
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/invalid-dependency",
3
- "version": "4.2.1",
3
+ "version": "4.2.2",
4
4
  "scripts": {
5
5
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
6
6
  "build:cjs": "node ../../scripts/inline invalid-dependency",
@@ -24,7 +24,7 @@
24
24
  "license": "Apache-2.0",
25
25
  "sideEffects": false,
26
26
  "dependencies": {
27
- "@smithy/types": "^4.7.0",
27
+ "@smithy/types": "^4.7.1",
28
28
  "tslib": "^2.6.2"
29
29
  },
30
30
  "typesVersions": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/md5-js",
3
- "version": "4.2.1",
3
+ "version": "4.2.2",
4
4
  "scripts": {
5
5
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
6
6
  "build:cjs": "node ../../scripts/inline md5-js",
@@ -34,7 +34,7 @@
34
34
  "typedoc": "0.23.23"
35
35
  },
36
36
  "dependencies": {
37
- "@smithy/types": "^4.7.0",
37
+ "@smithy/types": "^4.7.1",
38
38
  "@smithy/util-utf8": "^4.2.0",
39
39
  "tslib": "^2.6.2"
40
40
  },
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/middleware-content-length",
3
- "version": "4.2.1",
3
+ "version": "4.2.2",
4
4
  "scripts": {
5
5
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
6
6
  "build:cjs": "node ../../scripts/inline middleware-content-length",
@@ -25,8 +25,8 @@
25
25
  "license": "Apache-2.0",
26
26
  "sideEffects": false,
27
27
  "dependencies": {
28
- "@smithy/protocol-http": "^5.3.1",
29
- "@smithy/types": "^4.7.0",
28
+ "@smithy/protocol-http": "^5.3.2",
29
+ "@smithy/types": "^4.7.1",
30
30
  "tslib": "^2.6.2"
31
31
  },
32
32
  "engines": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/middleware-endpoint",
3
- "version": "4.3.2",
3
+ "version": "4.3.3",
4
4
  "scripts": {
5
5
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
6
6
  "build:cjs": "node ../../scripts/inline middleware-endpoint",
@@ -25,13 +25,13 @@
25
25
  "license": "Apache-2.0",
26
26
  "sideEffects": false,
27
27
  "dependencies": {
28
- "@smithy/core": "^3.16.0",
29
- "@smithy/middleware-serde": "^4.2.1",
30
- "@smithy/node-config-provider": "^4.3.1",
31
- "@smithy/shared-ini-file-loader": "^4.3.1",
32
- "@smithy/types": "^4.7.0",
33
- "@smithy/url-parser": "^4.2.1",
34
- "@smithy/util-middleware": "^4.2.1",
28
+ "@smithy/core": "^3.16.1",
29
+ "@smithy/middleware-serde": "^4.2.2",
30
+ "@smithy/node-config-provider": "^4.3.2",
31
+ "@smithy/shared-ini-file-loader": "^4.3.2",
32
+ "@smithy/types": "^4.7.1",
33
+ "@smithy/url-parser": "^4.2.2",
34
+ "@smithy/util-middleware": "^4.2.2",
35
35
  "tslib": "^2.6.2"
36
36
  },
37
37
  "devDependencies": {