@kensio/yulin 1.20.4 → 1.20.5

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 (203) hide show
  1. package/dist/service/cloudformation/resource/cfn/logs/sim-logs-cfn-value-adapter.d.ts.map +1 -1
  2. package/dist/service/cloudformation/resource/cfn/logs/sim-logs-cfn-value-adapter.js +22 -3
  3. package/dist/service/cloudformation/resource/cfn/logs/sim-logs-cfn-value-adapter.js.map +1 -1
  4. package/dist/service/cloudformation/resource/cfn/logs/sim-logs-delivery-cfn.d.ts +31 -0
  5. package/dist/service/cloudformation/resource/cfn/logs/sim-logs-delivery-cfn.d.ts.map +1 -0
  6. package/dist/service/cloudformation/resource/cfn/logs/sim-logs-delivery-cfn.js +43 -0
  7. package/dist/service/cloudformation/resource/cfn/logs/sim-logs-delivery-cfn.js.map +1 -0
  8. package/dist/service/cloudformation/resource/cfn/logs/sim-logs-delivery-destination-cfn.d.ts +32 -0
  9. package/dist/service/cloudformation/resource/cfn/logs/sim-logs-delivery-destination-cfn.d.ts.map +1 -0
  10. package/dist/service/cloudformation/resource/cfn/logs/sim-logs-delivery-destination-cfn.js +34 -0
  11. package/dist/service/cloudformation/resource/cfn/logs/sim-logs-delivery-destination-cfn.js.map +1 -0
  12. package/dist/service/cloudformation/resource/cfn/logs/sim-logs-delivery-source-cfn.d.ts +27 -0
  13. package/dist/service/cloudformation/resource/cfn/logs/sim-logs-delivery-source-cfn.d.ts.map +1 -0
  14. package/dist/service/cloudformation/resource/cfn/logs/sim-logs-delivery-source-cfn.js +39 -0
  15. package/dist/service/cloudformation/resource/cfn/logs/sim-logs-delivery-source-cfn.js.map +1 -0
  16. package/dist/service/cloudfront/cfn/distro/sim-cfn-cf-distro-creator.d.ts +6 -5
  17. package/dist/service/cloudfront/cfn/distro/sim-cfn-cf-distro-creator.d.ts.map +1 -1
  18. package/dist/service/cloudfront/cfn/distro/sim-cfn-cf-distro-creator.js +10 -8
  19. package/dist/service/cloudfront/cfn/distro/sim-cfn-cf-distro-creator.js.map +1 -1
  20. package/dist/service/cloudfront/cfn/distro/sim-cfn-cf-distro-response-headers-policy.d.ts +24 -0
  21. package/dist/service/cloudfront/cfn/distro/sim-cfn-cf-distro-response-headers-policy.d.ts.map +1 -0
  22. package/dist/service/cloudfront/cfn/distro/sim-cfn-cf-distro-response-headers-policy.js +94 -0
  23. package/dist/service/cloudfront/cfn/distro/sim-cfn-cf-distro-response-headers-policy.js.map +1 -0
  24. package/dist/service/cloudfront/controller/response-headers/sim-cf-response-headers-applicator.d.ts.map +1 -1
  25. package/dist/service/cloudfront/controller/response-headers/sim-cf-response-headers-applicator.js +4 -4
  26. package/dist/service/cloudfront/controller/response-headers/sim-cf-response-headers-applicator.js.map +1 -1
  27. package/dist/service/cloudfront/distribution/configurator/sim-cf-behavior-response-headers-policy.d.ts.map +1 -1
  28. package/dist/service/cloudfront/distribution/configurator/sim-cf-behavior-response-headers-policy.js +3 -4
  29. package/dist/service/cloudfront/distribution/configurator/sim-cf-behavior-response-headers-policy.js.map +1 -1
  30. package/dist/service/cloudfront/response-headers-policy/sim-cf-managed-response-headers-policies.d.ts +27 -0
  31. package/dist/service/cloudfront/response-headers-policy/sim-cf-managed-response-headers-policies.d.ts.map +1 -0
  32. package/dist/service/cloudfront/response-headers-policy/sim-cf-managed-response-headers-policies.js +119 -0
  33. package/dist/service/cloudfront/response-headers-policy/sim-cf-managed-response-headers-policies.js.map +1 -0
  34. package/dist/service/cloudfront/response-headers-policy/sim-cf-response-headers-policy-cors.d.ts +18 -3
  35. package/dist/service/cloudfront/response-headers-policy/sim-cf-response-headers-policy-cors.d.ts.map +1 -1
  36. package/dist/service/cloudfront/response-headers-policy/sim-cf-response-headers-policy-cors.js +28 -5
  37. package/dist/service/cloudfront/response-headers-policy/sim-cf-response-headers-policy-cors.js.map +1 -1
  38. package/dist/service/cloudfront/response-headers-policy/sim-cf-response-headers-policy-registry.d.ts +14 -4
  39. package/dist/service/cloudfront/response-headers-policy/sim-cf-response-headers-policy-registry.d.ts.map +1 -1
  40. package/dist/service/cloudfront/response-headers-policy/sim-cf-response-headers-policy-registry.js +17 -5
  41. package/dist/service/cloudfront/response-headers-policy/sim-cf-response-headers-policy-registry.js.map +1 -1
  42. package/dist/service/cloudfront/response-headers-policy/sim-cf-response-headers-policy.d.ts +6 -2
  43. package/dist/service/cloudfront/response-headers-policy/sim-cf-response-headers-policy.d.ts.map +1 -1
  44. package/dist/service/cloudfront/response-headers-policy/sim-cf-response-headers-policy.js +7 -3
  45. package/dist/service/cloudfront/response-headers-policy/sim-cf-response-headers-policy.js.map +1 -1
  46. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-creator.d.ts +28 -0
  47. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-creator.d.ts.map +1 -0
  48. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-creator.js +52 -0
  49. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-creator.js.map +1 -0
  50. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-destination-creator.d.ts +30 -0
  51. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-destination-creator.d.ts.map +1 -0
  52. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-destination-creator.js +59 -0
  53. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-destination-creator.js.map +1 -0
  54. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-input.d.ts +12 -0
  55. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-input.d.ts.map +1 -0
  56. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-input.js +23 -0
  57. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-input.js.map +1 -0
  58. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-properties.d.ts +50 -0
  59. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-properties.d.ts.map +1 -0
  60. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-properties.js +107 -0
  61. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-properties.js.map +1 -0
  62. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-source-creator.d.ts +29 -0
  63. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-source-creator.d.ts.map +1 -0
  64. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-source-creator.js +50 -0
  65. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-source-creator.js.map +1 -0
  66. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-unsimulated-properties.d.ts +16 -0
  67. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-unsimulated-properties.d.ts.map +1 -0
  68. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-unsimulated-properties.js +39 -0
  69. package/dist/service/logs/cfn/delivery/sim-cfn-delivery-unsimulated-properties.js.map +1 -0
  70. package/dist/service/logs/cfn/sim-logs-cfn-resource-deleter.d.ts +27 -0
  71. package/dist/service/logs/cfn/sim-logs-cfn-resource-deleter.d.ts.map +1 -0
  72. package/dist/service/logs/cfn/sim-logs-cfn-resource-deleter.js +49 -0
  73. package/dist/service/logs/cfn/sim-logs-cfn-resource-deleter.js.map +1 -0
  74. package/dist/service/logs/cfn/sim-logs-cfn-resource-factory.d.ts +8 -3
  75. package/dist/service/logs/cfn/sim-logs-cfn-resource-factory.d.ts.map +1 -1
  76. package/dist/service/logs/cfn/sim-logs-cfn-resource-factory.js +48 -23
  77. package/dist/service/logs/cfn/sim-logs-cfn-resource-factory.js.map +1 -1
  78. package/dist/service/logs/cfn/sim-logs-cfn-unsupported-resource.d.ts +10 -0
  79. package/dist/service/logs/cfn/sim-logs-cfn-unsupported-resource.d.ts.map +1 -0
  80. package/dist/service/logs/cfn/sim-logs-cfn-unsupported-resource.js +13 -0
  81. package/dist/service/logs/cfn/sim-logs-cfn-unsupported-resource.js.map +1 -0
  82. package/dist/service/logs/command/authorize/sim-logs-authorizer.d.ts +9 -1
  83. package/dist/service/logs/command/authorize/sim-logs-authorizer.d.ts.map +1 -1
  84. package/dist/service/logs/command/authorize/sim-logs-authorizer.js +8 -0
  85. package/dist/service/logs/command/authorize/sim-logs-authorizer.js.map +1 -1
  86. package/dist/service/logs/command/delivery/delivery-destination.command.d.ts +67 -0
  87. package/dist/service/logs/command/delivery/delivery-destination.command.d.ts.map +1 -0
  88. package/dist/service/logs/command/delivery/delivery-destination.command.js +2 -0
  89. package/dist/service/logs/command/delivery/delivery-destination.command.js.map +1 -0
  90. package/dist/service/logs/command/delivery/delivery-source.command.d.ts +61 -0
  91. package/dist/service/logs/command/delivery/delivery-source.command.d.ts.map +1 -0
  92. package/dist/service/logs/command/delivery/delivery-source.command.js +2 -0
  93. package/dist/service/logs/command/delivery/delivery-source.command.js.map +1 -0
  94. package/dist/service/logs/command/delivery/delivery.command.d.ts +73 -0
  95. package/dist/service/logs/command/delivery/delivery.command.d.ts.map +1 -0
  96. package/dist/service/logs/command/delivery/delivery.command.js +2 -0
  97. package/dist/service/logs/command/delivery/delivery.command.js.map +1 -0
  98. package/dist/service/logs/command/delivery/sim-logs-created-delivery.d.ts +21 -0
  99. package/dist/service/logs/command/delivery/sim-logs-created-delivery.d.ts.map +1 -0
  100. package/dist/service/logs/command/delivery/sim-logs-created-delivery.js +41 -0
  101. package/dist/service/logs/command/delivery/sim-logs-created-delivery.js.map +1 -0
  102. package/dist/service/logs/command/delivery/sim-logs-delivery-commands.d.ts +38 -0
  103. package/dist/service/logs/command/delivery/sim-logs-delivery-commands.d.ts.map +1 -0
  104. package/dist/service/logs/command/delivery/sim-logs-delivery-commands.js +77 -0
  105. package/dist/service/logs/command/delivery/sim-logs-delivery-commands.js.map +1 -0
  106. package/dist/service/logs/command/delivery/sim-logs-delivery-destination-commands.d.ts +38 -0
  107. package/dist/service/logs/command/delivery/sim-logs-delivery-destination-commands.d.ts.map +1 -0
  108. package/dist/service/logs/command/delivery/sim-logs-delivery-destination-commands.js +82 -0
  109. package/dist/service/logs/command/delivery/sim-logs-delivery-destination-commands.js.map +1 -0
  110. package/dist/service/logs/command/delivery/sim-logs-delivery-detail.d.ts +19 -0
  111. package/dist/service/logs/command/delivery/sim-logs-delivery-detail.d.ts.map +1 -0
  112. package/dist/service/logs/command/delivery/sim-logs-delivery-detail.js +57 -0
  113. package/dist/service/logs/command/delivery/sim-logs-delivery-detail.js.map +1 -0
  114. package/dist/service/logs/command/delivery/sim-logs-delivery-in-use.d.ts +15 -0
  115. package/dist/service/logs/command/delivery/sim-logs-delivery-in-use.d.ts.map +1 -0
  116. package/dist/service/logs/command/delivery/sim-logs-delivery-in-use.js +26 -0
  117. package/dist/service/logs/command/delivery/sim-logs-delivery-in-use.js.map +1 -0
  118. package/dist/service/logs/command/delivery/sim-logs-delivery-input.d.ts +16 -0
  119. package/dist/service/logs/command/delivery/sim-logs-delivery-input.d.ts.map +1 -0
  120. package/dist/service/logs/command/delivery/sim-logs-delivery-input.js +28 -0
  121. package/dist/service/logs/command/delivery/sim-logs-delivery-input.js.map +1 -0
  122. package/dist/service/logs/command/delivery/sim-logs-delivery-source-commands.d.ts +37 -0
  123. package/dist/service/logs/command/delivery/sim-logs-delivery-source-commands.d.ts.map +1 -0
  124. package/dist/service/logs/command/delivery/sim-logs-delivery-source-commands.js +86 -0
  125. package/dist/service/logs/command/delivery/sim-logs-delivery-source-commands.js.map +1 -0
  126. package/dist/service/logs/command/sim-logs-command.types.d.ts +3 -0
  127. package/dist/service/logs/command/sim-logs-command.types.d.ts.map +1 -1
  128. package/dist/service/logs/delivery/sim-logs-delivery-arn.d.ts +30 -0
  129. package/dist/service/logs/delivery/sim-logs-delivery-arn.d.ts.map +1 -0
  130. package/dist/service/logs/delivery/sim-logs-delivery-arn.js +42 -0
  131. package/dist/service/logs/delivery/sim-logs-delivery-arn.js.map +1 -0
  132. package/dist/service/logs/delivery/sim-logs-delivery-destination-store.d.ts +41 -0
  133. package/dist/service/logs/delivery/sim-logs-delivery-destination-store.d.ts.map +1 -0
  134. package/dist/service/logs/delivery/sim-logs-delivery-destination-store.js +69 -0
  135. package/dist/service/logs/delivery/sim-logs-delivery-destination-store.js.map +1 -0
  136. package/dist/service/logs/delivery/sim-logs-delivery-destination-type.d.ts +16 -0
  137. package/dist/service/logs/delivery/sim-logs-delivery-destination-type.d.ts.map +1 -0
  138. package/dist/service/logs/delivery/sim-logs-delivery-destination-type.js +48 -0
  139. package/dist/service/logs/delivery/sim-logs-delivery-destination-type.js.map +1 -0
  140. package/dist/service/logs/delivery/sim-logs-delivery-destination.d.ts +27 -0
  141. package/dist/service/logs/delivery/sim-logs-delivery-destination.d.ts.map +1 -0
  142. package/dist/service/logs/delivery/sim-logs-delivery-destination.js +23 -0
  143. package/dist/service/logs/delivery/sim-logs-delivery-destination.js.map +1 -0
  144. package/dist/service/logs/delivery/sim-logs-delivery-ids.d.ts +16 -0
  145. package/dist/service/logs/delivery/sim-logs-delivery-ids.d.ts.map +1 -0
  146. package/dist/service/logs/delivery/sim-logs-delivery-ids.js +20 -0
  147. package/dist/service/logs/delivery/sim-logs-delivery-ids.js.map +1 -0
  148. package/dist/service/logs/delivery/sim-logs-delivery-output-format.d.ts +24 -0
  149. package/dist/service/logs/delivery/sim-logs-delivery-output-format.d.ts.map +1 -0
  150. package/dist/service/logs/delivery/sim-logs-delivery-output-format.js +36 -0
  151. package/dist/service/logs/delivery/sim-logs-delivery-output-format.js.map +1 -0
  152. package/dist/service/logs/delivery/sim-logs-delivery-s3-configuration.d.ts +35 -0
  153. package/dist/service/logs/delivery/sim-logs-delivery-s3-configuration.d.ts.map +1 -0
  154. package/dist/service/logs/delivery/sim-logs-delivery-s3-configuration.js +66 -0
  155. package/dist/service/logs/delivery/sim-logs-delivery-s3-configuration.js.map +1 -0
  156. package/dist/service/logs/delivery/sim-logs-delivery-source-service.d.ts +48 -0
  157. package/dist/service/logs/delivery/sim-logs-delivery-source-service.d.ts.map +1 -0
  158. package/dist/service/logs/delivery/sim-logs-delivery-source-service.js +71 -0
  159. package/dist/service/logs/delivery/sim-logs-delivery-source-service.js.map +1 -0
  160. package/dist/service/logs/delivery/sim-logs-delivery-source-store.d.ts +42 -0
  161. package/dist/service/logs/delivery/sim-logs-delivery-source-store.d.ts.map +1 -0
  162. package/dist/service/logs/delivery/sim-logs-delivery-source-store.js +64 -0
  163. package/dist/service/logs/delivery/sim-logs-delivery-source-store.js.map +1 -0
  164. package/dist/service/logs/delivery/sim-logs-delivery-source.d.ts +29 -0
  165. package/dist/service/logs/delivery/sim-logs-delivery-source.d.ts.map +1 -0
  166. package/dist/service/logs/delivery/sim-logs-delivery-source.js +29 -0
  167. package/dist/service/logs/delivery/sim-logs-delivery-source.js.map +1 -0
  168. package/dist/service/logs/delivery/sim-logs-delivery-store.d.ts +32 -0
  169. package/dist/service/logs/delivery/sim-logs-delivery-store.d.ts.map +1 -0
  170. package/dist/service/logs/delivery/sim-logs-delivery-store.js +53 -0
  171. package/dist/service/logs/delivery/sim-logs-delivery-store.js.map +1 -0
  172. package/dist/service/logs/delivery/sim-logs-delivery.d.ts +33 -0
  173. package/dist/service/logs/delivery/sim-logs-delivery.d.ts.map +1 -0
  174. package/dist/service/logs/delivery/sim-logs-delivery.js +34 -0
  175. package/dist/service/logs/delivery/sim-logs-delivery.js.map +1 -0
  176. package/dist/service/logs/error/sim-logs.error.d.ts +23 -0
  177. package/dist/service/logs/error/sim-logs.error.d.ts.map +1 -1
  178. package/dist/service/logs/error/sim-logs.error.js +27 -0
  179. package/dist/service/logs/error/sim-logs.error.js.map +1 -1
  180. package/dist/service/logs/index.d.ts +10 -1
  181. package/dist/service/logs/index.d.ts.map +1 -1
  182. package/dist/service/logs/index.js +9 -1
  183. package/dist/service/logs/index.js.map +1 -1
  184. package/dist/service/logs/sdk/sim-logs-sdk-command-router.d.ts.map +1 -1
  185. package/dist/service/logs/sdk/sim-logs-sdk-command-router.js +36 -0
  186. package/dist/service/logs/sdk/sim-logs-sdk-command-router.js.map +1 -1
  187. package/dist/service/logs/sim-logs-commands.d.ts +12 -0
  188. package/dist/service/logs/sim-logs-commands.d.ts.map +1 -1
  189. package/dist/service/logs/sim-logs-commands.js +37 -0
  190. package/dist/service/logs/sim-logs-commands.js.map +1 -1
  191. package/dist/service/logs/sim-logs-delivery-inspection.d.ts +28 -0
  192. package/dist/service/logs/sim-logs-delivery-inspection.d.ts.map +1 -0
  193. package/dist/service/logs/sim-logs-delivery-inspection.js +35 -0
  194. package/dist/service/logs/sim-logs-delivery-inspection.js.map +1 -0
  195. package/dist/service/logs/sim-logs-delivery-operations.d.ts +35 -0
  196. package/dist/service/logs/sim-logs-delivery-operations.d.ts.map +1 -0
  197. package/dist/service/logs/sim-logs-delivery-operations.js +58 -0
  198. package/dist/service/logs/sim-logs-delivery-operations.js.map +1 -0
  199. package/dist/service/logs/sim-logs.d.ts +8 -2
  200. package/dist/service/logs/sim-logs.d.ts.map +1 -1
  201. package/dist/service/logs/sim-logs.js +39 -33
  202. package/dist/service/logs/sim-logs.js.map +1 -1
  203. package/package.json +1 -1
@@ -0,0 +1,19 @@
1
+ import type { SimLogsDeliveryDestination } from "../../delivery/sim-logs-delivery-destination.js";
2
+ import type { SimLogsDeliverySource } from "../../delivery/sim-logs-delivery-source.js";
3
+ import type { SimLogsDelivery } from "../../delivery/sim-logs-delivery.js";
4
+ import type { SimLogsDeliveryDestinationDetail } from "./delivery-destination.command.js";
5
+ import type { SimLogsDeliverySourceDetail } from "./delivery-source.command.js";
6
+ import type { SimLogsDeliveryDetail } from "./delivery.command.js";
7
+ /**
8
+ * What DescribeDeliverySources reports about one delivery source.
9
+ */
10
+ export declare function simLogsDeliverySourceDetail(source: SimLogsDeliverySource): SimLogsDeliverySourceDetail;
11
+ /**
12
+ * What DescribeDeliveryDestinations reports about one delivery destination.
13
+ */
14
+ export declare function simLogsDeliveryDestinationDetail(destination: SimLogsDeliveryDestination): SimLogsDeliveryDestinationDetail;
15
+ /**
16
+ * What DescribeDeliveries reports about one delivery.
17
+ */
18
+ export declare function simLogsDeliveryDetail(delivery: SimLogsDelivery): SimLogsDeliveryDetail;
19
+ //# sourceMappingURL=sim-logs-delivery-detail.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sim-logs-delivery-detail.d.ts","sourceRoot":"","sources":["../../../../../src/service/logs/command/delivery/sim-logs-delivery-detail.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,iDAAiD,CAAC;AAClG,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,4CAA4C,CAAC;AACxF,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,qCAAqC,CAAC;AAC3E,OAAO,KAAK,EAAE,gCAAgC,EAAE,MAAM,mCAAmC,CAAC;AAC1F,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,8BAA8B,CAAC;AAChF,OAAO,KAAK,EACV,qBAAqB,EAEtB,MAAM,uBAAuB,CAAC;AAE/B;;GAEG;AACH,wBAAgB,2BAA2B,CACzC,MAAM,EAAE,qBAAqB,GAC5B,2BAA2B,CAQ7B;AAED;;GAEG;AACH,wBAAgB,gCAAgC,CAC9C,WAAW,EAAE,0BAA0B,GACtC,gCAAgC,CAUlC;AAED;;GAEG;AACH,wBAAgB,qBAAqB,CACnC,QAAQ,EAAE,eAAe,GACxB,qBAAqB,CAiBvB"}
@@ -0,0 +1,57 @@
1
+ /**
2
+ * What DescribeDeliverySources reports about one delivery source.
3
+ */
4
+ export function simLogsDeliverySourceDetail(source) {
5
+ return {
6
+ name: source.name,
7
+ arn: source.arn,
8
+ resourceArns: source.resourceArns,
9
+ service: source.service,
10
+ logType: source.logType,
11
+ };
12
+ }
13
+ /**
14
+ * What DescribeDeliveryDestinations reports about one delivery destination.
15
+ */
16
+ export function simLogsDeliveryDestinationDetail(destination) {
17
+ return {
18
+ name: destination.name,
19
+ arn: destination.arn,
20
+ deliveryDestinationType: destination.destinationType,
21
+ outputFormat: destination.outputFormat,
22
+ deliveryDestinationConfiguration: {
23
+ destinationResourceArn: destination.destinationResourceArn,
24
+ },
25
+ };
26
+ }
27
+ /**
28
+ * What DescribeDeliveries reports about one delivery.
29
+ */
30
+ export function simLogsDeliveryDetail(delivery) {
31
+ return {
32
+ id: delivery.id,
33
+ arn: delivery.arn,
34
+ deliverySourceName: delivery.deliverySourceName,
35
+ deliveryDestinationArn: delivery.deliveryDestinationArn,
36
+ deliveryDestinationType: delivery.deliveryDestinationType,
37
+ // Copied, as it is on the way in. The delivery holds this list for the
38
+ // rest of the simulation's life and a caller is free to change what a
39
+ // command answered with.
40
+ recordFields: delivery.recordFields === undefined
41
+ ? undefined
42
+ : [...delivery.recordFields],
43
+ fieldDelimiter: delivery.fieldDelimiter,
44
+ s3DeliveryConfiguration: s3DeliveryConfigurationDetail(delivery),
45
+ };
46
+ }
47
+ function s3DeliveryConfigurationDetail(delivery) {
48
+ const configuration = delivery.s3DeliveryConfiguration;
49
+ if (configuration === undefined) {
50
+ return undefined;
51
+ }
52
+ return {
53
+ suffixPath: configuration.suffixPath,
54
+ enableHiveCompatiblePath: configuration.enableHiveCompatiblePath,
55
+ };
56
+ }
57
+ //# sourceMappingURL=sim-logs-delivery-detail.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sim-logs-delivery-detail.js","sourceRoot":"","sources":["../../../../../src/service/logs/command/delivery/sim-logs-delivery-detail.ts"],"names":[],"mappings":"AAUA;;GAEG;AACH,MAAM,UAAU,2BAA2B,CACzC,MAA6B;IAE7B,OAAO;QACL,IAAI,EAAE,MAAM,CAAC,IAAI;QACjB,GAAG,EAAE,MAAM,CAAC,GAAG;QACf,YAAY,EAAE,MAAM,CAAC,YAAY;QACjC,OAAO,EAAE,MAAM,CAAC,OAAO;QACvB,OAAO,EAAE,MAAM,CAAC,OAAO;KACxB,CAAC;AACJ,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,gCAAgC,CAC9C,WAAuC;IAEvC,OAAO;QACL,IAAI,EAAE,WAAW,CAAC,IAAI;QACtB,GAAG,EAAE,WAAW,CAAC,GAAG;QACpB,uBAAuB,EAAE,WAAW,CAAC,eAAe;QACpD,YAAY,EAAE,WAAW,CAAC,YAAY;QACtC,gCAAgC,EAAE;YAChC,sBAAsB,EAAE,WAAW,CAAC,sBAAsB;SAC3D;KACF,CAAC;AACJ,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,qBAAqB,CACnC,QAAyB;IAEzB,OAAO;QACL,EAAE,EAAE,QAAQ,CAAC,EAAE;QACf,GAAG,EAAE,QAAQ,CAAC,GAAG;QACjB,kBAAkB,EAAE,QAAQ,CAAC,kBAAkB;QAC/C,sBAAsB,EAAE,QAAQ,CAAC,sBAAsB;QACvD,uBAAuB,EAAE,QAAQ,CAAC,uBAAuB;QACzD,uEAAuE;QACvE,sEAAsE;QACtE,yBAAyB;QACzB,YAAY,EACV,QAAQ,CAAC,YAAY,KAAK,SAAS;YACjC,CAAC,CAAC,SAAS;YACX,CAAC,CAAC,CAAC,GAAG,QAAQ,CAAC,YAAY,CAAC;QAChC,cAAc,EAAE,QAAQ,CAAC,cAAc;QACvC,uBAAuB,EAAE,6BAA6B,CAAC,QAAQ,CAAC;KACjE,CAAC;AACJ,CAAC;AAED,SAAS,6BAA6B,CACpC,QAAyB;IAEzB,MAAM,aAAa,GAAG,QAAQ,CAAC,uBAAuB,CAAC;IAEvD,IAAI,aAAa,KAAK,SAAS,EAAE,CAAC;QAChC,OAAO,SAAS,CAAC;IACnB,CAAC;IAED,OAAO;QACL,UAAU,EAAE,aAAa,CAAC,UAAU;QACpC,wBAAwB,EAAE,aAAa,CAAC,wBAAwB;KACjE,CAAC;AACJ,CAAC"}
@@ -0,0 +1,15 @@
1
+ import type { SimLogsDeliveryDestination } from "../../delivery/sim-logs-delivery-destination.js";
2
+ import type { SimLogsDeliveryStore } from "../../delivery/sim-logs-delivery-store.js";
3
+ /**
4
+ * Refuse deleting a delivery source a delivery still carries logs from.
5
+ *
6
+ * Real CloudWatch Logs refuses the same, and points a caller at
7
+ * `DescribeDeliveries` to find out which delivery is holding on to it. The
8
+ * delivery goes first, and in a template CloudFormation orders that itself.
9
+ */
10
+ export declare function refuseSimLogsDeliverySourceInUse(deliveries: SimLogsDeliveryStore, name: string): void;
11
+ /**
12
+ * Refuse deleting a delivery destination a delivery still writes to.
13
+ */
14
+ export declare function refuseSimLogsDeliveryDestinationInUse(deliveries: SimLogsDeliveryStore, destination: SimLogsDeliveryDestination): void;
15
+ //# sourceMappingURL=sim-logs-delivery-in-use.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sim-logs-delivery-in-use.d.ts","sourceRoot":"","sources":["../../../../../src/service/logs/command/delivery/sim-logs-delivery-in-use.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,iDAAiD,CAAC;AAClG,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,2CAA2C,CAAC;AAGtF;;;;;;GAMG;AACH,wBAAgB,gCAAgC,CAC9C,UAAU,EAAE,oBAAoB,EAChC,IAAI,EAAE,MAAM,GACX,IAAI,CAWN;AAED;;GAEG;AACH,wBAAgB,qCAAqC,CACnD,UAAU,EAAE,oBAAoB,EAChC,WAAW,EAAE,0BAA0B,GACtC,IAAI,CAWN"}
@@ -0,0 +1,26 @@
1
+ import { SimLogsConflictException } from "../../error/sim-logs.error.js";
2
+ /**
3
+ * Refuse deleting a delivery source a delivery still carries logs from.
4
+ *
5
+ * Real CloudWatch Logs refuses the same, and points a caller at
6
+ * `DescribeDeliveries` to find out which delivery is holding on to it. The
7
+ * delivery goes first, and in a template CloudFormation orders that itself.
8
+ */
9
+ export function refuseSimLogsDeliverySourceInUse(deliveries, name) {
10
+ const held = deliveries.all.some((delivery) => delivery.deliverySourceName === name);
11
+ if (held) {
12
+ throw new SimLogsConflictException(`Delivery source '${name}' cannot be deleted while a delivery is ` +
13
+ `associated with it`);
14
+ }
15
+ }
16
+ /**
17
+ * Refuse deleting a delivery destination a delivery still writes to.
18
+ */
19
+ export function refuseSimLogsDeliveryDestinationInUse(deliveries, destination) {
20
+ const held = deliveries.all.some((delivery) => delivery.deliveryDestinationArn === destination.arn);
21
+ if (held) {
22
+ throw new SimLogsConflictException(`Delivery destination '${destination.name}' cannot be deleted while a ` +
23
+ `delivery is associated with it`);
24
+ }
25
+ }
26
+ //# sourceMappingURL=sim-logs-delivery-in-use.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sim-logs-delivery-in-use.js","sourceRoot":"","sources":["../../../../../src/service/logs/command/delivery/sim-logs-delivery-in-use.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,wBAAwB,EAAE,MAAM,+BAA+B,CAAC;AAEzE;;;;;;GAMG;AACH,MAAM,UAAU,gCAAgC,CAC9C,UAAgC,EAChC,IAAY;IAEZ,MAAM,IAAI,GAAG,UAAU,CAAC,GAAG,CAAC,IAAI,CAC9B,CAAC,QAAQ,EAAE,EAAE,CAAC,QAAQ,CAAC,kBAAkB,KAAK,IAAI,CACnD,CAAC;IAEF,IAAI,IAAI,EAAE,CAAC;QACT,MAAM,IAAI,wBAAwB,CAChC,oBAAoB,IAAI,0CAA0C;YAChE,oBAAoB,CACvB,CAAC;IACJ,CAAC;AACH,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,qCAAqC,CACnD,UAAgC,EAChC,WAAuC;IAEvC,MAAM,IAAI,GAAG,UAAU,CAAC,GAAG,CAAC,IAAI,CAC9B,CAAC,QAAQ,EAAE,EAAE,CAAC,QAAQ,CAAC,sBAAsB,KAAK,WAAW,CAAC,GAAG,CAClE,CAAC;IAEF,IAAI,IAAI,EAAE,CAAC;QACT,MAAM,IAAI,wBAAwB,CAChC,yBAAyB,WAAW,CAAC,IAAI,8BAA8B;YACrE,gCAAgC,CACnC,CAAC;IACJ,CAAC;AACH,CAAC"}
@@ -0,0 +1,16 @@
1
+ /**
2
+ * Read a value a delivery operation requires.
3
+ *
4
+ * The delivery operations report a missing field as a `ValidationException`
5
+ * rather than the `InvalidParameterException` the log group operations use,
6
+ * which is why this exists beside the readers those share.
7
+ */
8
+ export declare function requiredSimLogsDeliveryValue(value: string | undefined, field: string): string;
9
+ /**
10
+ * Refuse tags on a delivery resource.
11
+ *
12
+ * Nothing reads a tag back here, so a resource created with them would look
13
+ * tagged to the request that made it and untagged to everything else.
14
+ */
15
+ export declare function refuseUnsimulatedDeliveryTags(tags: Record<string, string> | undefined, operation: string): void;
16
+ //# sourceMappingURL=sim-logs-delivery-input.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sim-logs-delivery-input.d.ts","sourceRoot":"","sources":["../../../../../src/service/logs/command/delivery/sim-logs-delivery-input.ts"],"names":[],"mappings":"AAKA;;;;;;GAMG;AACH,wBAAgB,4BAA4B,CAC1C,KAAK,EAAE,MAAM,GAAG,SAAS,EACzB,KAAK,EAAE,MAAM,GACZ,MAAM,CASR;AAED;;;;;GAKG;AACH,wBAAgB,6BAA6B,CAC3C,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,SAAS,EACxC,SAAS,EAAE,MAAM,GAChB,IAAI,CAON"}
@@ -0,0 +1,28 @@
1
+ import { SimLogsUnsupportedOperationException, SimLogsValidationException, } from "../../error/sim-logs.error.js";
2
+ /**
3
+ * Read a value a delivery operation requires.
4
+ *
5
+ * The delivery operations report a missing field as a `ValidationException`
6
+ * rather than the `InvalidParameterException` the log group operations use,
7
+ * which is why this exists beside the readers those share.
8
+ */
9
+ export function requiredSimLogsDeliveryValue(value, field) {
10
+ if (value === undefined || value.length === 0) {
11
+ throw new SimLogsValidationException(`1 validation error detected: Value at '${field}' failed to satisfy ` +
12
+ `constraint: Member must not be null`);
13
+ }
14
+ return value;
15
+ }
16
+ /**
17
+ * Refuse tags on a delivery resource.
18
+ *
19
+ * Nothing reads a tag back here, so a resource created with them would look
20
+ * tagged to the request that made it and untagged to everything else.
21
+ */
22
+ export function refuseUnsimulatedDeliveryTags(tags, operation) {
23
+ if (tags !== undefined) {
24
+ throw new SimLogsUnsupportedOperationException(`Delivery resource tags are not simulated, so ${operation} refuses ` +
25
+ `them rather than dropping them`);
26
+ }
27
+ }
28
+ //# sourceMappingURL=sim-logs-delivery-input.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sim-logs-delivery-input.js","sourceRoot":"","sources":["../../../../../src/service/logs/command/delivery/sim-logs-delivery-input.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,oCAAoC,EACpC,0BAA0B,GAC3B,MAAM,+BAA+B,CAAC;AAEvC;;;;;;GAMG;AACH,MAAM,UAAU,4BAA4B,CAC1C,KAAyB,EACzB,KAAa;IAEb,IAAI,KAAK,KAAK,SAAS,IAAI,KAAK,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QAC9C,MAAM,IAAI,0BAA0B,CAClC,0CAA0C,KAAK,sBAAsB;YACnE,qCAAqC,CACxC,CAAC;IACJ,CAAC;IAED,OAAO,KAAK,CAAC;AACf,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,6BAA6B,CAC3C,IAAwC,EACxC,SAAiB;IAEjB,IAAI,IAAI,KAAK,SAAS,EAAE,CAAC;QACvB,MAAM,IAAI,oCAAoC,CAC5C,gDAAgD,SAAS,WAAW;YAClE,gCAAgC,CACnC,CAAC;IACJ,CAAC;AACH,CAAC"}
@@ -0,0 +1,37 @@
1
+ import type { SimAwsAccountRegionScope } from "../../../aws/sim-aws-account-region-scope.js";
2
+ import type { SimLogsDeliverySourceStore } from "../../delivery/sim-logs-delivery-source-store.js";
3
+ import type { SimLogsDeliveryStore } from "../../delivery/sim-logs-delivery-store.js";
4
+ import type { SimLogsAuthorizer } from "../authorize/sim-logs-authorizer.js";
5
+ import type { SimLogsRequestOptions } from "../sim-logs-request-options.js";
6
+ import type { SimDeleteDeliverySourceCommand, SimDeleteDeliverySourceCommandOutput, SimDescribeDeliverySourcesCommand, SimDescribeDeliverySourcesCommandOutput, SimPutDeliverySourceCommand, SimPutDeliverySourceCommandOutput } from "./delivery-source.command.js";
7
+ interface SimLogsDeliverySourceCommandsProperties {
8
+ readonly sources: SimLogsDeliverySourceStore;
9
+ readonly deliveries: SimLogsDeliveryStore;
10
+ readonly authorizer: SimLogsAuthorizer;
11
+ readonly accountRegionScope: SimAwsAccountRegionScope;
12
+ }
13
+ /**
14
+ * The commands that put, describe and remove delivery sources.
15
+ */
16
+ export declare class SimLogsDeliverySourceCommands {
17
+ #private;
18
+ constructor(properties: SimLogsDeliverySourceCommandsProperties);
19
+ /**
20
+ * Put a delivery source over a resource whose logs are to be delivered.
21
+ *
22
+ * The service is read from the resource ARN, as real CloudWatch Logs reads
23
+ * it, and the region the request was made in has to be one that service's
24
+ * delivery can be set up from.
25
+ */
26
+ putDeliverySource(command: SimPutDeliverySourceCommand, options?: SimLogsRequestOptions): SimPutDeliverySourceCommandOutput;
27
+ /**
28
+ * Describe the delivery sources in this scope, in the order they were put.
29
+ */
30
+ describeDeliverySources(command: SimDescribeDeliverySourcesCommand, options?: SimLogsRequestOptions): SimDescribeDeliverySourcesCommandOutput;
31
+ /**
32
+ * Remove a delivery source no delivery is carrying logs from.
33
+ */
34
+ deleteDeliverySource(command: SimDeleteDeliverySourceCommand, options?: SimLogsRequestOptions): SimDeleteDeliverySourceCommandOutput;
35
+ }
36
+ export {};
37
+ //# sourceMappingURL=sim-logs-delivery-source-commands.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sim-logs-delivery-source-commands.d.ts","sourceRoot":"","sources":["../../../../../src/service/logs/command/delivery/sim-logs-delivery-source-commands.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,8CAA8C,CAAC;AAU7F,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,kDAAkD,CAAC;AACnG,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,2CAA2C,CAAC;AACtF,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAC;AAE7E,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,gCAAgC,CAAC;AAC5E,OAAO,KAAK,EACV,8BAA8B,EAC9B,oCAAoC,EACpC,iCAAiC,EACjC,uCAAuC,EACvC,2BAA2B,EAC3B,iCAAiC,EAClC,MAAM,8BAA8B,CAAC;AAWtC,UAAU,uCAAuC;IAC/C,QAAQ,CAAC,OAAO,EAAE,0BAA0B,CAAC;IAC7C,QAAQ,CAAC,UAAU,EAAE,oBAAoB,CAAC;IAC1C,QAAQ,CAAC,UAAU,EAAE,iBAAiB,CAAC;IACvC,QAAQ,CAAC,kBAAkB,EAAE,wBAAwB,CAAC;CACvD;AAED;;GAEG;AACH,qBAAa,6BAA6B;;IAMxC,YAAY,UAAU,EAAE,uCAAuC,EAK9D;IAED;;;;;;OAMG;IACH,iBAAiB,CACf,OAAO,EAAE,2BAA2B,EACpC,OAAO,CAAC,EAAE,qBAAqB,GAC9B,iCAAiC,CAsCnC;IAED;;OAEG;IACH,uBAAuB,CACrB,OAAO,EAAE,iCAAiC,EAC1C,OAAO,CAAC,EAAE,qBAAqB,GAC9B,uCAAuC,CAuBzC;IAED;;OAEG;IACH,oBAAoB,CAClB,OAAO,EAAE,8BAA8B,EACvC,OAAO,CAAC,EAAE,qBAAqB,GAC9B,oCAAoC,CAatC;CACF"}
@@ -0,0 +1,86 @@
1
+ import { simLogsAnyDeliverySourceArn, simLogsDeliverySourceArn, } from "../../delivery/sim-logs-delivery-arn.js";
2
+ import { requireSimLogsDeliverySource, requiredSimLogsDeliveredService, } from "../../delivery/sim-logs-delivery-source-service.js";
3
+ import { SimLogsDeliverySource } from "../../delivery/sim-logs-delivery-source.js";
4
+ import { SimLogsPage } from "../sim-logs-page.js";
5
+ import { simLogsDeliverySourceDetail } from "./sim-logs-delivery-detail.js";
6
+ import { refuseSimLogsDeliverySourceInUse } from "./sim-logs-delivery-in-use.js";
7
+ import { refuseUnsimulatedDeliveryTags, requiredSimLogsDeliveryValue, } from "./sim-logs-delivery-input.js";
8
+ /** The largest page the delivery listings take, as real CloudWatch Logs does. */
9
+ const maximumDescribeLimit = 50;
10
+ /**
11
+ * The commands that put, describe and remove delivery sources.
12
+ */
13
+ export class SimLogsDeliverySourceCommands {
14
+ #sources;
15
+ #deliveries;
16
+ #authorizer;
17
+ #scope;
18
+ constructor(properties) {
19
+ this.#sources = properties.sources;
20
+ this.#deliveries = properties.deliveries;
21
+ this.#authorizer = properties.authorizer;
22
+ this.#scope = properties.accountRegionScope;
23
+ }
24
+ /**
25
+ * Put a delivery source over a resource whose logs are to be delivered.
26
+ *
27
+ * The service is read from the resource ARN, as real CloudWatch Logs reads
28
+ * it, and the region the request was made in has to be one that service's
29
+ * delivery can be set up from.
30
+ */
31
+ putDeliverySource(command, options) {
32
+ const input = command.input;
33
+ const name = requiredSimLogsDeliveryValue(input.name, "name");
34
+ const resourceArn = requiredSimLogsDeliveryValue(input.resourceArn, "resourceArn");
35
+ const logType = requiredSimLogsDeliveryValue(input.logType, "logType");
36
+ refuseUnsimulatedDeliveryTags(input.tags, "PutDeliverySource");
37
+ this.#authorizer.authorizeResource("logs:PutDeliverySource", simLogsDeliverySourceArn(this.#scope, name), options?.caller);
38
+ const service = requiredSimLogsDeliveredService(resourceArn);
39
+ requireSimLogsDeliverySource({
40
+ service,
41
+ regionName: this.#scope.regionName,
42
+ logType,
43
+ });
44
+ const source = new SimLogsDeliverySource({
45
+ name,
46
+ resourceArn,
47
+ logType,
48
+ service,
49
+ accountRegionScope: this.#scope,
50
+ });
51
+ this.#sources.put(source);
52
+ return {
53
+ $metadata: {},
54
+ deliverySource: simLogsDeliverySourceDetail(source),
55
+ };
56
+ }
57
+ /**
58
+ * Describe the delivery sources in this scope, in the order they were put.
59
+ */
60
+ describeDeliverySources(command, options) {
61
+ const input = command.input;
62
+ this.#authorizer.authorizeResource("logs:DescribeDeliverySources", simLogsAnyDeliverySourceArn(this.#scope), options?.caller);
63
+ const page = new SimLogsPage({
64
+ listed: this.#sources.all,
65
+ limit: input.limit,
66
+ nextToken: input.nextToken,
67
+ maximumLimit: maximumDescribeLimit,
68
+ });
69
+ return {
70
+ $metadata: {},
71
+ deliverySources: page.items.map((source) => simLogsDeliverySourceDetail(source)),
72
+ nextToken: page.nextToken,
73
+ };
74
+ }
75
+ /**
76
+ * Remove a delivery source no delivery is carrying logs from.
77
+ */
78
+ deleteDeliverySource(command, options) {
79
+ const name = requiredSimLogsDeliveryValue(command.input.name, "name");
80
+ this.#authorizer.authorizeResource("logs:DeleteDeliverySource", simLogsDeliverySourceArn(this.#scope, name), options?.caller);
81
+ refuseSimLogsDeliverySourceInUse(this.#deliveries, name);
82
+ this.#sources.delete(name);
83
+ return { $metadata: {} };
84
+ }
85
+ }
86
+ //# sourceMappingURL=sim-logs-delivery-source-commands.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sim-logs-delivery-source-commands.js","sourceRoot":"","sources":["../../../../../src/service/logs/command/delivery/sim-logs-delivery-source-commands.ts"],"names":[],"mappings":"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"}
@@ -5,4 +5,7 @@ export type { SimCreateLogGroupCommand, SimCreateLogGroupCommandInput, SimCreate
5
5
  export type { SimCreateLogStreamCommand, SimCreateLogStreamCommandInput, SimCreateLogStreamCommandOutput, SimDescribeLogStreamsCommand, SimDescribeLogStreamsCommandInput, SimDescribeLogStreamsCommandOutput, SimLogsLogStreamDetail, } from "./stream/stream.command.js";
6
6
  export type { SimFilterLogEventsCommand, SimFilterLogEventsCommandInput, SimFilterLogEventsCommandOutput, SimGetLogEventsCommand, SimGetLogEventsCommandInput, SimGetLogEventsCommandOutput, SimLogsFilteredLogEvent, SimLogsInputLogEvent, SimLogsOutputLogEvent, SimPutLogEventsCommand, SimPutLogEventsCommandInput, SimPutLogEventsCommandOutput, } from "./event/event.command.js";
7
7
  export type { SimDeleteSubscriptionFilterCommand, SimDeleteSubscriptionFilterCommandInput, SimDeleteSubscriptionFilterCommandOutput, SimDescribeSubscriptionFiltersCommand, SimDescribeSubscriptionFiltersCommandInput, SimDescribeSubscriptionFiltersCommandOutput, SimLogsSubscriptionFilterDetail, SimPutSubscriptionFilterCommand, SimPutSubscriptionFilterCommandInput, SimPutSubscriptionFilterCommandOutput, } from "./subscription/subscription.command.js";
8
+ export type { SimDeleteDeliverySourceCommand, SimDeleteDeliverySourceCommandInput, SimDeleteDeliverySourceCommandOutput, SimDescribeDeliverySourcesCommand, SimDescribeDeliverySourcesCommandInput, SimDescribeDeliverySourcesCommandOutput, SimLogsDeliverySourceDetail, SimPutDeliverySourceCommand, SimPutDeliverySourceCommandInput, SimPutDeliverySourceCommandOutput, } from "./delivery/delivery-source.command.js";
9
+ export type { SimDeleteDeliveryDestinationCommand, SimDeleteDeliveryDestinationCommandInput, SimDeleteDeliveryDestinationCommandOutput, SimDescribeDeliveryDestinationsCommand, SimDescribeDeliveryDestinationsCommandInput, SimDescribeDeliveryDestinationsCommandOutput, SimLogsDeliveryDestinationConfiguration, SimLogsDeliveryDestinationDetail, SimPutDeliveryDestinationCommand, SimPutDeliveryDestinationCommandInput, SimPutDeliveryDestinationCommandOutput, } from "./delivery/delivery-destination.command.js";
10
+ export type { SimCreateDeliveryCommand, SimCreateDeliveryCommandInput, SimCreateDeliveryCommandOutput, SimDeleteDeliveryCommand, SimDeleteDeliveryCommandInput, SimDeleteDeliveryCommandOutput, SimDescribeDeliveriesCommand, SimDescribeDeliveriesCommandInput, SimDescribeDeliveriesCommandOutput, SimLogsDeliveryDetail, SimLogsS3DeliveryConfiguration, } from "./delivery/delivery.command.js";
8
11
  //# sourceMappingURL=sim-logs-command.types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"sim-logs-command.types.d.ts","sourceRoot":"","sources":["../../../../src/service/logs/command/sim-logs-command.types.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,YAAY,EACV,wBAAwB,EACxB,6BAA6B,EAC7B,8BAA8B,EAC9B,wBAAwB,EACxB,6BAA6B,EAC7B,8BAA8B,EAC9B,+BAA+B,EAC/B,oCAAoC,EACpC,qCAAqC,EACrC,2BAA2B,EAC3B,gCAAgC,EAChC,iCAAiC,EACjC,qBAAqB,EACrB,4BAA4B,EAC5B,iCAAiC,EACjC,kCAAkC,GACnC,MAAM,0BAA0B,CAAC;AAClC,YAAY,EACV,yBAAyB,EACzB,8BAA8B,EAC9B,+BAA+B,EAC/B,4BAA4B,EAC5B,iCAAiC,EACjC,kCAAkC,EAClC,sBAAsB,GACvB,MAAM,4BAA4B,CAAC;AACpC,YAAY,EACV,yBAAyB,EACzB,8BAA8B,EAC9B,+BAA+B,EAC/B,sBAAsB,EACtB,2BAA2B,EAC3B,4BAA4B,EAC5B,uBAAuB,EACvB,oBAAoB,EACpB,qBAAqB,EACrB,sBAAsB,EACtB,2BAA2B,EAC3B,4BAA4B,GAC7B,MAAM,0BAA0B,CAAC;AAClC,YAAY,EACV,kCAAkC,EAClC,uCAAuC,EACvC,wCAAwC,EACxC,qCAAqC,EACrC,0CAA0C,EAC1C,2CAA2C,EAC3C,+BAA+B,EAC/B,+BAA+B,EAC/B,oCAAoC,EACpC,qCAAqC,GACtC,MAAM,wCAAwC,CAAC"}
1
+ {"version":3,"file":"sim-logs-command.types.d.ts","sourceRoot":"","sources":["../../../../src/service/logs/command/sim-logs-command.types.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,YAAY,EACV,wBAAwB,EACxB,6BAA6B,EAC7B,8BAA8B,EAC9B,wBAAwB,EACxB,6BAA6B,EAC7B,8BAA8B,EAC9B,+BAA+B,EAC/B,oCAAoC,EACpC,qCAAqC,EACrC,2BAA2B,EAC3B,gCAAgC,EAChC,iCAAiC,EACjC,qBAAqB,EACrB,4BAA4B,EAC5B,iCAAiC,EACjC,kCAAkC,GACnC,MAAM,0BAA0B,CAAC;AAClC,YAAY,EACV,yBAAyB,EACzB,8BAA8B,EAC9B,+BAA+B,EAC/B,4BAA4B,EAC5B,iCAAiC,EACjC,kCAAkC,EAClC,sBAAsB,GACvB,MAAM,4BAA4B,CAAC;AACpC,YAAY,EACV,yBAAyB,EACzB,8BAA8B,EAC9B,+BAA+B,EAC/B,sBAAsB,EACtB,2BAA2B,EAC3B,4BAA4B,EAC5B,uBAAuB,EACvB,oBAAoB,EACpB,qBAAqB,EACrB,sBAAsB,EACtB,2BAA2B,EAC3B,4BAA4B,GAC7B,MAAM,0BAA0B,CAAC;AAClC,YAAY,EACV,kCAAkC,EAClC,uCAAuC,EACvC,wCAAwC,EACxC,qCAAqC,EACrC,0CAA0C,EAC1C,2CAA2C,EAC3C,+BAA+B,EAC/B,+BAA+B,EAC/B,oCAAoC,EACpC,qCAAqC,GACtC,MAAM,wCAAwC,CAAC;AAChD,YAAY,EACV,8BAA8B,EAC9B,mCAAmC,EACnC,oCAAoC,EACpC,iCAAiC,EACjC,sCAAsC,EACtC,uCAAuC,EACvC,2BAA2B,EAC3B,2BAA2B,EAC3B,gCAAgC,EAChC,iCAAiC,GAClC,MAAM,uCAAuC,CAAC;AAC/C,YAAY,EACV,mCAAmC,EACnC,wCAAwC,EACxC,yCAAyC,EACzC,sCAAsC,EACtC,2CAA2C,EAC3C,4CAA4C,EAC5C,uCAAuC,EACvC,gCAAgC,EAChC,gCAAgC,EAChC,qCAAqC,EACrC,sCAAsC,GACvC,MAAM,4CAA4C,CAAC;AACpD,YAAY,EACV,wBAAwB,EACxB,6BAA6B,EAC7B,8BAA8B,EAC9B,wBAAwB,EACxB,6BAA6B,EAC7B,8BAA8B,EAC9B,4BAA4B,EAC5B,iCAAiC,EACjC,kCAAkC,EAClC,qBAAqB,EACrB,8BAA8B,GAC/B,MAAM,gCAAgC,CAAC"}
@@ -0,0 +1,30 @@
1
+ import type { SimAwsAccountRegionScope } from "../../aws/sim-aws-account-region-scope.js";
2
+ /**
3
+ * The ARN of a delivery source.
4
+ *
5
+ * A delivery source is named by the caller, so its ARN carries that name. The
6
+ * delivery itself is the only one of the three resources named by an
7
+ * identifier CloudWatch Logs issues.
8
+ */
9
+ export declare function simLogsDeliverySourceArn(scope: SimAwsAccountRegionScope, name: string): string;
10
+ /**
11
+ * The ARN of every delivery source in one account and region.
12
+ */
13
+ export declare function simLogsAnyDeliverySourceArn(scope: SimAwsAccountRegionScope): string;
14
+ /**
15
+ * The ARN of a delivery destination.
16
+ */
17
+ export declare function simLogsDeliveryDestinationArn(scope: SimAwsAccountRegionScope, name: string): string;
18
+ /**
19
+ * The ARN of every delivery destination in one account and region.
20
+ */
21
+ export declare function simLogsAnyDeliveryDestinationArn(scope: SimAwsAccountRegionScope): string;
22
+ /**
23
+ * The ARN of a delivery.
24
+ */
25
+ export declare function simLogsDeliveryArn(scope: SimAwsAccountRegionScope, deliveryId: string): string;
26
+ /**
27
+ * The ARN of every delivery in one account and region.
28
+ */
29
+ export declare function simLogsAnyDeliveryArn(scope: SimAwsAccountRegionScope): string;
30
+ //# sourceMappingURL=sim-logs-delivery-arn.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sim-logs-delivery-arn.d.ts","sourceRoot":"","sources":["../../../../src/service/logs/delivery/sim-logs-delivery-arn.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,2CAA2C,CAAC;AAG1F;;;;;;GAMG;AACH,wBAAgB,wBAAwB,CACtC,KAAK,EAAE,wBAAwB,EAC/B,IAAI,EAAE,MAAM,GACX,MAAM,CAER;AAED;;GAEG;AACH,wBAAgB,2BAA2B,CACzC,KAAK,EAAE,wBAAwB,GAC9B,MAAM,CAER;AAED;;GAEG;AACH,wBAAgB,6BAA6B,CAC3C,KAAK,EAAE,wBAAwB,EAC/B,IAAI,EAAE,MAAM,GACX,MAAM,CAER;AAED;;GAEG;AACH,wBAAgB,gCAAgC,CAC9C,KAAK,EAAE,wBAAwB,GAC9B,MAAM,CAER;AAED;;GAEG;AACH,wBAAgB,kBAAkB,CAChC,KAAK,EAAE,wBAAwB,EAC/B,UAAU,EAAE,MAAM,GACjB,MAAM,CAER;AAED;;GAEG;AACH,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,wBAAwB,GAAG,MAAM,CAE7E"}
@@ -0,0 +1,42 @@
1
+ import { simLogsArnPrefix } from "../group/sim-logs-arn.js";
2
+ /**
3
+ * The ARN of a delivery source.
4
+ *
5
+ * A delivery source is named by the caller, so its ARN carries that name. The
6
+ * delivery itself is the only one of the three resources named by an
7
+ * identifier CloudWatch Logs issues.
8
+ */
9
+ export function simLogsDeliverySourceArn(scope, name) {
10
+ return `${simLogsArnPrefix(scope)}delivery-source:${name}`;
11
+ }
12
+ /**
13
+ * The ARN of every delivery source in one account and region.
14
+ */
15
+ export function simLogsAnyDeliverySourceArn(scope) {
16
+ return simLogsDeliverySourceArn(scope, "*");
17
+ }
18
+ /**
19
+ * The ARN of a delivery destination.
20
+ */
21
+ export function simLogsDeliveryDestinationArn(scope, name) {
22
+ return `${simLogsArnPrefix(scope)}delivery-destination:${name}`;
23
+ }
24
+ /**
25
+ * The ARN of every delivery destination in one account and region.
26
+ */
27
+ export function simLogsAnyDeliveryDestinationArn(scope) {
28
+ return simLogsDeliveryDestinationArn(scope, "*");
29
+ }
30
+ /**
31
+ * The ARN of a delivery.
32
+ */
33
+ export function simLogsDeliveryArn(scope, deliveryId) {
34
+ return `${simLogsArnPrefix(scope)}delivery:${deliveryId}`;
35
+ }
36
+ /**
37
+ * The ARN of every delivery in one account and region.
38
+ */
39
+ export function simLogsAnyDeliveryArn(scope) {
40
+ return simLogsDeliveryArn(scope, "*");
41
+ }
42
+ //# sourceMappingURL=sim-logs-delivery-arn.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sim-logs-delivery-arn.js","sourceRoot":"","sources":["../../../../src/service/logs/delivery/sim-logs-delivery-arn.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAE5D;;;;;;GAMG;AACH,MAAM,UAAU,wBAAwB,CACtC,KAA+B,EAC/B,IAAY;IAEZ,OAAO,GAAG,gBAAgB,CAAC,KAAK,CAAC,mBAAmB,IAAI,EAAE,CAAC;AAC7D,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,2BAA2B,CACzC,KAA+B;IAE/B,OAAO,wBAAwB,CAAC,KAAK,EAAE,GAAG,CAAC,CAAC;AAC9C,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,6BAA6B,CAC3C,KAA+B,EAC/B,IAAY;IAEZ,OAAO,GAAG,gBAAgB,CAAC,KAAK,CAAC,wBAAwB,IAAI,EAAE,CAAC;AAClE,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,gCAAgC,CAC9C,KAA+B;IAE/B,OAAO,6BAA6B,CAAC,KAAK,EAAE,GAAG,CAAC,CAAC;AACnD,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,kBAAkB,CAChC,KAA+B,EAC/B,UAAkB;IAElB,OAAO,GAAG,gBAAgB,CAAC,KAAK,CAAC,YAAY,UAAU,EAAE,CAAC;AAC5D,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,qBAAqB,CAAC,KAA+B;IACnE,OAAO,kBAAkB,CAAC,KAAK,EAAE,GAAG,CAAC,CAAC;AACxC,CAAC"}
@@ -0,0 +1,41 @@
1
+ import type { SimLogsDeliveryDestination } from "./sim-logs-delivery-destination.js";
2
+ /**
3
+ * The delivery destinations of one simulated CloudWatch Logs scope.
4
+ *
5
+ * Destinations are keyed by name. The output format is fixed once the
6
+ * destination exists, so changing it means deleting the destination and making
7
+ * it again, which is a replacement in a template and a two step change through
8
+ * the SDK.
9
+ */
10
+ export declare class SimLogsDeliveryDestinationStore {
11
+ #private;
12
+ /**
13
+ * Every delivery destination in this scope, in the order they were put.
14
+ */
15
+ get all(): readonly SimLogsDeliveryDestination[];
16
+ /**
17
+ * Put a delivery destination, updating one of the same name.
18
+ *
19
+ * A put that would change the output format is refused rather than applied,
20
+ * because a destination silently rewritten to another format would leave
21
+ * every reader of what it wrote parsing the wrong thing.
22
+ */
23
+ put(destination: SimLogsDeliveryDestination): void;
24
+ /**
25
+ * Find a delivery destination by name.
26
+ */
27
+ find(name: string): SimLogsDeliveryDestination | undefined;
28
+ /**
29
+ * Get a delivery destination by name, refusing one that is not there.
30
+ */
31
+ require(name: string): SimLogsDeliveryDestination;
32
+ /**
33
+ * Get a delivery destination by its own ARN, refusing one that is not there.
34
+ */
35
+ requireByArn(arn: string): SimLogsDeliveryDestination;
36
+ /**
37
+ * Remove a delivery destination, refusing one that is not there.
38
+ */
39
+ delete(name: string): void;
40
+ }
41
+ //# sourceMappingURL=sim-logs-delivery-destination-store.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sim-logs-delivery-destination-store.d.ts","sourceRoot":"","sources":["../../../../src/service/logs/delivery/sim-logs-delivery-destination-store.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,oCAAoC,CAAC;AAErF;;;;;;;GAOG;AACH,qBAAa,+BAA+B;;IAG1C;;OAEG;IACH,IAAI,GAAG,IAAI,SAAS,0BAA0B,EAAE,CAE/C;IAED;;;;;;OAMG;IACH,GAAG,CAAC,WAAW,EAAE,0BAA0B,GAAG,IAAI,CAejD;IAED;;OAEG;IACH,IAAI,CAAC,IAAI,EAAE,MAAM,GAAG,0BAA0B,GAAG,SAAS,CAEzD;IAED;;OAEG;IACH,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,0BAA0B,CAUhD;IAED;;OAEG;IACH,YAAY,CAAC,GAAG,EAAE,MAAM,GAAG,0BAA0B,CAUpD;IAED;;OAEG;IACH,MAAM,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAGzB;CACF"}
@@ -0,0 +1,69 @@
1
+ import { SimLogsResourceNotFoundException, SimLogsValidationException, } from "../error/sim-logs.error.js";
2
+ /**
3
+ * The delivery destinations of one simulated CloudWatch Logs scope.
4
+ *
5
+ * Destinations are keyed by name. The output format is fixed once the
6
+ * destination exists, so changing it means deleting the destination and making
7
+ * it again, which is a replacement in a template and a two step change through
8
+ * the SDK.
9
+ */
10
+ export class SimLogsDeliveryDestinationStore {
11
+ #destinations = new Map();
12
+ /**
13
+ * Every delivery destination in this scope, in the order they were put.
14
+ */
15
+ get all() {
16
+ return this.#destinations.values().toArray();
17
+ }
18
+ /**
19
+ * Put a delivery destination, updating one of the same name.
20
+ *
21
+ * A put that would change the output format is refused rather than applied,
22
+ * because a destination silently rewritten to another format would leave
23
+ * every reader of what it wrote parsing the wrong thing.
24
+ */
25
+ put(destination) {
26
+ const existing = this.find(destination.name);
27
+ if (existing !== undefined &&
28
+ existing.outputFormat !== destination.outputFormat) {
29
+ throw new SimLogsValidationException(`Delivery destination '${destination.name}' was created with ` +
30
+ `output format '${existing.outputFormat}', which cannot be ` +
31
+ `changed to '${destination.outputFormat}'`);
32
+ }
33
+ this.#destinations.set(destination.name, destination);
34
+ }
35
+ /**
36
+ * Find a delivery destination by name.
37
+ */
38
+ find(name) {
39
+ return this.#destinations.get(name);
40
+ }
41
+ /**
42
+ * Get a delivery destination by name, refusing one that is not there.
43
+ */
44
+ require(name) {
45
+ const destination = this.find(name);
46
+ if (destination === undefined) {
47
+ throw new SimLogsResourceNotFoundException(`Delivery destination '${name}' does not exist`);
48
+ }
49
+ return destination;
50
+ }
51
+ /**
52
+ * Get a delivery destination by its own ARN, refusing one that is not there.
53
+ */
54
+ requireByArn(arn) {
55
+ const destination = this.all.find((candidate) => candidate.arn === arn);
56
+ if (destination === undefined) {
57
+ throw new SimLogsResourceNotFoundException(`Delivery destination '${arn}' does not exist`);
58
+ }
59
+ return destination;
60
+ }
61
+ /**
62
+ * Remove a delivery destination, refusing one that is not there.
63
+ */
64
+ delete(name) {
65
+ this.require(name);
66
+ this.#destinations.delete(name);
67
+ }
68
+ }
69
+ //# sourceMappingURL=sim-logs-delivery-destination-store.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sim-logs-delivery-destination-store.js","sourceRoot":"","sources":["../../../../src/service/logs/delivery/sim-logs-delivery-destination-store.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,gCAAgC,EAChC,0BAA0B,GAC3B,MAAM,4BAA4B,CAAC;AAGpC;;;;;;;GAOG;AACH,MAAM,OAAO,+BAA+B;IACjC,aAAa,GAAG,IAAI,GAAG,EAAsC,CAAC;IAEvE;;OAEG;IACH,IAAI,GAAG;QACL,OAAO,IAAI,CAAC,aAAa,CAAC,MAAM,EAAE,CAAC,OAAO,EAAE,CAAC;IAC/C,CAAC;IAED;;;;;;OAMG;IACH,GAAG,CAAC,WAAuC;QACzC,MAAM,QAAQ,GAAG,IAAI,CAAC,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;QAE7C,IACE,QAAQ,KAAK,SAAS;YACtB,QAAQ,CAAC,YAAY,KAAK,WAAW,CAAC,YAAY,EAClD,CAAC;YACD,MAAM,IAAI,0BAA0B,CAClC,yBAAyB,WAAW,CAAC,IAAI,qBAAqB;gBAC5D,kBAAkB,QAAQ,CAAC,YAAY,qBAAqB;gBAC5D,eAAe,WAAW,CAAC,YAAY,GAAG,CAC7C,CAAC;QACJ,CAAC;QAED,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,WAAW,CAAC,IAAI,EAAE,WAAW,CAAC,CAAC;IACxD,CAAC;IAED;;OAEG;IACH,IAAI,CAAC,IAAY;QACf,OAAO,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;IACtC,CAAC;IAED;;OAEG;IACH,OAAO,CAAC,IAAY;QAClB,MAAM,WAAW,GAAG,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAEpC,IAAI,WAAW,KAAK,SAAS,EAAE,CAAC;YAC9B,MAAM,IAAI,gCAAgC,CACxC,yBAAyB,IAAI,kBAAkB,CAChD,CAAC;QACJ,CAAC;QAED,OAAO,WAAW,CAAC;IACrB,CAAC;IAED;;OAEG;IACH,YAAY,CAAC,GAAW;QACtB,MAAM,WAAW,GAAG,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,SAAS,EAAE,EAAE,CAAC,SAAS,CAAC,GAAG,KAAK,GAAG,CAAC,CAAC;QAExE,IAAI,WAAW,KAAK,SAAS,EAAE,CAAC;YAC9B,MAAM,IAAI,gCAAgC,CACxC,yBAAyB,GAAG,kBAAkB,CAC/C,CAAC;QACJ,CAAC;QAED,OAAO,WAAW,CAAC;IACrB,CAAC;IAED;;OAEG;IACH,MAAM,CAAC,IAAY;QACjB,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;QACnB,IAAI,CAAC,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC;IAClC,CAAC;CACF"}
@@ -0,0 +1,16 @@
1
+ /**
2
+ * Where a delivery destination puts what it receives.
3
+ *
4
+ * The three values are the abbreviations real CloudWatch Logs reports: an S3
5
+ * bucket, a CloudWatch Logs log group, and a Firehose delivery stream.
6
+ */
7
+ export type SimLogsDeliveryDestinationType = "S3" | "CWL" | "FH";
8
+ /**
9
+ * Which kind of destination an ARN names.
10
+ *
11
+ * Real CloudWatch Logs works this out from the ARN rather than taking it from
12
+ * the caller, and reports it back on the destination and on every delivery
13
+ * that uses it.
14
+ */
15
+ export declare function requiredSimLogsDeliveryDestinationType(destinationResourceArn: string): SimLogsDeliveryDestinationType;
16
+ //# sourceMappingURL=sim-logs-delivery-destination-type.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sim-logs-delivery-destination-type.d.ts","sourceRoot":"","sources":["../../../../src/service/logs/delivery/sim-logs-delivery-destination-type.ts"],"names":[],"mappings":"AAEA;;;;;GAKG;AACH,MAAM,MAAM,8BAA8B,GAAG,IAAI,GAAG,KAAK,GAAG,IAAI,CAAC;AAiCjE;;;;;;GAMG;AACH,wBAAgB,sCAAsC,CACpD,sBAAsB,EAAE,MAAM,GAC7B,8BAA8B,CAqBhC"}
@@ -0,0 +1,48 @@
1
+ import { SimLogsValidationException } from "../error/sim-logs.error.js";
2
+ /** How many colon separated segments the shortest ARN has. */
3
+ const arnSegmentCount = 6;
4
+ /**
5
+ * The ARN shapes a delivery destination can be built over.
6
+ *
7
+ * The service alone is too little to go on. An account holds plenty of `logs`
8
+ * resources that are not log groups, the delivery destinations themselves
9
+ * among them, and one named as a destination's target would take a delivery
10
+ * and drop everything sent to it.
11
+ */
12
+ const destinationArnShapes = [
13
+ { service: "s3", resourcePrefix: "", destinationType: "S3" },
14
+ { service: "logs", resourcePrefix: "log-group:", destinationType: "CWL" },
15
+ {
16
+ service: "firehose",
17
+ resourcePrefix: "deliverystream/",
18
+ destinationType: "FH",
19
+ },
20
+ ];
21
+ /**
22
+ * Which kind of destination an ARN names.
23
+ *
24
+ * Real CloudWatch Logs works this out from the ARN rather than taking it from
25
+ * the caller, and reports it back on the destination and on every delivery
26
+ * that uses it.
27
+ */
28
+ export function requiredSimLogsDeliveryDestinationType(destinationResourceArn) {
29
+ const segments = destinationResourceArn.split(":");
30
+ if (segments[0] !== "arn" || segments.length < arnSegmentCount) {
31
+ throw destinationArnError(destinationResourceArn);
32
+ }
33
+ const service = segments[2] ?? "";
34
+ const resource = segments.slice(arnSegmentCount - 1).join(":");
35
+ const shape = destinationArnShapes.find((candidate) => candidate.service === service &&
36
+ resource.startsWith(candidate.resourcePrefix) &&
37
+ resource.length > candidate.resourcePrefix.length);
38
+ if (shape === undefined) {
39
+ throw destinationArnError(destinationResourceArn);
40
+ }
41
+ return shape.destinationType;
42
+ }
43
+ function destinationArnError(destinationResourceArn) {
44
+ return new SimLogsValidationException(`destinationResourceArn '${destinationResourceArn}' names no delivery ` +
45
+ `destination: it has to be an S3 bucket, a CloudWatch Logs log group ` +
46
+ `or a Firehose delivery stream`);
47
+ }
48
+ //# sourceMappingURL=sim-logs-delivery-destination-type.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sim-logs-delivery-destination-type.js","sourceRoot":"","sources":["../../../../src/service/logs/delivery/sim-logs-delivery-destination-type.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,0BAA0B,EAAE,MAAM,4BAA4B,CAAC;AAUxE,8DAA8D;AAC9D,MAAM,eAAe,GAAG,CAAC,CAAC;AAY1B;;;;;;;GAOG;AACH,MAAM,oBAAoB,GAAkD;IAC1E,EAAE,OAAO,EAAE,IAAI,EAAE,cAAc,EAAE,EAAE,EAAE,eAAe,EAAE,IAAI,EAAE;IAC5D,EAAE,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,YAAY,EAAE,eAAe,EAAE,KAAK,EAAE;IACzE;QACE,OAAO,EAAE,UAAU;QACnB,cAAc,EAAE,iBAAiB;QACjC,eAAe,EAAE,IAAI;KACtB;CACF,CAAC;AAEF;;;;;;GAMG;AACH,MAAM,UAAU,sCAAsC,CACpD,sBAA8B;IAE9B,MAAM,QAAQ,GAAG,sBAAsB,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IAEnD,IAAI,QAAQ,CAAC,CAAC,CAAC,KAAK,KAAK,IAAI,QAAQ,CAAC,MAAM,GAAG,eAAe,EAAE,CAAC;QAC/D,MAAM,mBAAmB,CAAC,sBAAsB,CAAC,CAAC;IACpD,CAAC;IAED,MAAM,OAAO,GAAG,QAAQ,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC;IAClC,MAAM,QAAQ,GAAG,QAAQ,CAAC,KAAK,CAAC,eAAe,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;IAC/D,MAAM,KAAK,GAAG,oBAAoB,CAAC,IAAI,CACrC,CAAC,SAAS,EAAE,EAAE,CACZ,SAAS,CAAC,OAAO,KAAK,OAAO;QAC7B,QAAQ,CAAC,UAAU,CAAC,SAAS,CAAC,cAAc,CAAC;QAC7C,QAAQ,CAAC,MAAM,GAAG,SAAS,CAAC,cAAc,CAAC,MAAM,CACpD,CAAC;IAEF,IAAI,KAAK,KAAK,SAAS,EAAE,CAAC;QACxB,MAAM,mBAAmB,CAAC,sBAAsB,CAAC,CAAC;IACpD,CAAC;IAED,OAAO,KAAK,CAAC,eAAe,CAAC;AAC/B,CAAC;AAED,SAAS,mBAAmB,CAAC,sBAA8B;IACzD,OAAO,IAAI,0BAA0B,CACnC,2BAA2B,sBAAsB,sBAAsB;QACrE,sEAAsE;QACtE,+BAA+B,CAClC,CAAC;AACJ,CAAC"}