@takumi-stack/core 1.0.0 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.dist/common/coordinator.d.ts +18 -0
- package/.dist/common/index.d.ts +6 -0
- package/.dist/common/modifier.d.ts +4 -0
- package/.dist/common/naming/get-deploy-config.d.ts +5 -0
- package/.dist/common/naming/get-domain.d.ts +8 -0
- package/.dist/common/naming/get-function-entry.d.ts +3 -0
- package/.dist/common/naming/get-logical-name.d.ts +2 -0
- package/.dist/common/naming/get-resource-name.d.ts +26 -0
- package/.dist/common/naming/get-service-name.d.ts +9 -0
- package/.dist/common/naming/index.d.ts +8 -0
- package/.dist/common/naming/string-parser.d.ts +4 -0
- package/.dist/common/service.d.ts +21 -0
- package/.dist/common/synth/account-mapping.d.ts +2 -0
- package/.dist/common/synth/assume-role.d.ts +17 -0
- package/.dist/common/synth/get-global-props.d.ts +4 -0
- package/.dist/common/synth/get-service-props.d.ts +3 -0
- package/.dist/common/synth/index.d.ts +8 -0
- package/.dist/common/synth/pre-script.d.ts +21 -0
- package/.dist/common/synth/props-types.d.ts +41 -0
- package/.dist/common/synth/synth-error.d.ts +7 -0
- package/.dist/index.d.ts +4 -0
- package/.dist/package.json +43 -0
- package/.dist/prefab/analytics/events/handlers/ingestion-transform/handler.d.ts +3 -0
- package/.dist/prefab/analytics/events/index.d.ts +28 -0
- package/.dist/prefab/analytics/events/index.d.ts.map +1 -0
- package/.dist/prefab/analytics/events/index.js +163 -0
- package/.dist/prefab/analytics/events/index.js.map +1 -0
- package/.dist/prefab/analytics/index.d.ts +2 -0
- package/.dist/prefab/auth/cognito-pool/index.d.ts +57 -0
- package/.dist/prefab/auth/cognito-pool/index.d.ts.map +1 -0
- package/.dist/prefab/auth/cognito-pool/index.js.map +1 -0
- package/.dist/prefab/auth/index.d.ts +2 -0
- package/.dist/prefab/cdn/cdn-api/index.d.ts +34 -0
- package/.dist/prefab/cdn/cdn-api/index.d.ts.map +1 -0
- package/.dist/prefab/cdn/cdn-api/index.js +153 -0
- package/.dist/prefab/cdn/cdn-api/index.js.map +1 -0
- package/.dist/prefab/cdn/cdn-asset/index.d.ts +24 -0
- package/.dist/prefab/cdn/cdn-asset/index.d.ts.map +1 -0
- package/.dist/prefab/cdn/cdn-asset/index.js +96 -0
- package/.dist/prefab/cdn/cdn-asset/index.js.map +1 -0
- package/.dist/prefab/cdn/cdn-spa/index.d.ts +24 -0
- package/.dist/prefab/cdn/cdn-spa/index.d.ts.map +1 -0
- package/.dist/prefab/cdn/cdn-spa/index.js +138 -0
- package/.dist/prefab/cdn/cdn-spa/index.js.map +1 -0
- package/.dist/prefab/cdn/cdn-ssr/index.d.ts +33 -0
- package/.dist/prefab/cdn/cdn-ssr/index.d.ts.map +1 -0
- package/.dist/prefab/cdn/cdn-ssr/index.js +271 -0
- package/.dist/prefab/cdn/cdn-ssr/index.js.map +1 -0
- package/.dist/prefab/cdn/index.d.ts +5 -0
- package/.dist/prefab/compute/fargate/cluster.d.ts +13 -0
- package/.dist/prefab/compute/fargate/cluster.d.ts.map +1 -0
- package/.dist/prefab/compute/fargate/cluster.js.map +1 -0
- package/.dist/prefab/compute/fargate/index.d.ts +3 -0
- package/.dist/prefab/compute/fargate/service.d.ts +45 -0
- package/.dist/prefab/compute/fargate/service.d.ts.map +1 -0
- package/.dist/prefab/compute/fargate/service.js.map +1 -0
- package/.dist/prefab/compute/function/api-function/api-aggregate.d.ts +31 -0
- package/.dist/prefab/compute/function/api-function/api-aggregate.d.ts.map +1 -0
- package/.dist/prefab/compute/function/api-function/api-aggregate.js +53 -0
- package/.dist/prefab/compute/function/api-function/api-aggregate.js.map +1 -0
- package/.dist/prefab/compute/function/api-function/api-function.d.ts +22 -0
- package/.dist/prefab/compute/function/api-function/api-function.d.ts.map +1 -0
- package/.dist/prefab/compute/function/api-function/api-function.js +44 -0
- package/.dist/prefab/compute/function/api-function/api-function.js.map +1 -0
- package/.dist/prefab/compute/function/api-function/index.d.ts +3 -0
- package/.dist/prefab/compute/function/base-function/index.d.ts +33 -0
- package/.dist/prefab/compute/function/base-function/index.d.ts.map +1 -0
- package/.dist/prefab/compute/function/base-function/index.js +70 -0
- package/.dist/prefab/compute/function/base-function/index.js.map +1 -0
- package/.dist/prefab/compute/function/cognito-function/cognito-aggregate.d.ts +15 -0
- package/.dist/prefab/compute/function/cognito-function/cognito-aggregate.d.ts.map +1 -0
- package/.dist/prefab/compute/function/cognito-function/cognito-aggregate.js.map +1 -0
- package/.dist/prefab/compute/function/cognito-function/cognito-function.d.ts +17 -0
- package/.dist/prefab/compute/function/cognito-function/cognito-function.d.ts.map +1 -0
- package/.dist/prefab/compute/function/cognito-function/cognito-function.js.map +1 -0
- package/.dist/prefab/compute/function/cognito-function/index.d.ts +3 -0
- package/.dist/prefab/compute/function/cron-function/cron-aggregate.d.ts +14 -0
- package/.dist/prefab/compute/function/cron-function/cron-aggregate.d.ts.map +1 -0
- package/.dist/prefab/compute/function/cron-function/cron-aggregate.js.map +1 -0
- package/.dist/prefab/compute/function/cron-function/cron-function.d.ts +15 -0
- package/.dist/prefab/compute/function/cron-function/cron-function.d.ts.map +1 -0
- package/.dist/prefab/compute/function/cron-function/cron-function.js +24 -0
- package/.dist/prefab/compute/function/cron-function/cron-function.js.map +1 -0
- package/.dist/prefab/compute/function/cron-function/index.d.ts +3 -0
- package/.dist/prefab/compute/function/event-function/EventAggregateParams.d.ts +9 -0
- package/.dist/prefab/compute/function/event-function/EventAggregateParams.d.ts.map +1 -0
- package/.dist/prefab/compute/function/event-function/EventAggregateParams.js +3 -0
- package/.dist/prefab/compute/function/event-function/EventAggregateParams.js.map +1 -0
- package/.dist/prefab/compute/function/event-function/event-aggregate.d.ts +16 -0
- package/.dist/prefab/compute/function/event-function/event-aggregate.d.ts.map +1 -0
- package/.dist/prefab/compute/function/event-function/event-aggregate.js.map +1 -0
- package/.dist/prefab/compute/function/event-function/event-function.d.ts +14 -0
- package/.dist/prefab/compute/function/event-function/event-function.d.ts.map +1 -0
- package/.dist/prefab/compute/function/event-function/event-function.js.map +1 -0
- package/.dist/prefab/compute/function/event-function/index.d.ts +3 -0
- package/.dist/prefab/compute/function/index.d.ts +8 -0
- package/.dist/prefab/compute/function/queue-function/index.d.ts +22 -0
- package/.dist/prefab/compute/function/queue-function/index.d.ts.map +1 -0
- package/.dist/prefab/compute/function/queue-function/index.js +46 -0
- package/.dist/prefab/compute/function/queue-function/index.js.map +1 -0
- package/.dist/prefab/compute/function/topic-function/index.d.ts +20 -0
- package/.dist/prefab/compute/function/topic-function/index.d.ts.map +1 -0
- package/.dist/prefab/compute/function/topic-function/index.js +23 -0
- package/.dist/prefab/compute/function/topic-function/index.js.map +1 -0
- package/.dist/prefab/compute/index.d.ts +3 -0
- package/.dist/prefab/database/dynamo/index.d.ts +13 -0
- package/.dist/prefab/database/dynamo/index.d.ts.map +1 -0
- package/.dist/prefab/database/dynamo/index.js.map +1 -0
- package/.dist/prefab/database/index.d.ts +4 -0
- package/.dist/prefab/database/rds/handlers/start-cluster/handler.d.ts +2 -0
- package/.dist/prefab/database/rds/handlers/stop-cluster/handler.d.ts +2 -0
- package/.dist/prefab/database/rds/index.d.ts +51 -0
- package/.dist/prefab/database/rds/index.d.ts.map +1 -0
- package/.dist/prefab/database/rds/index.js +223 -0
- package/.dist/prefab/database/rds/index.js.map +1 -0
- package/.dist/prefab/database/timestream/index.d.ts +3 -0
- package/.dist/prefab/database/timestream/timestream-database.d.ts +11 -0
- package/.dist/prefab/database/timestream/timestream-database.d.ts.map +1 -0
- package/.dist/prefab/database/timestream/timestream-database.js.map +1 -0
- package/.dist/prefab/database/timestream/timestream-table.d.ts +21 -0
- package/.dist/prefab/database/timestream/timestream-table.d.ts.map +1 -0
- package/.dist/prefab/database/timestream/timestream-table.js.map +1 -0
- package/.dist/prefab/gateway/alb-public/index.d.ts +41 -0
- package/.dist/prefab/gateway/alb-public/index.d.ts.map +1 -0
- package/.dist/prefab/gateway/alb-public/index.js.map +1 -0
- package/.dist/prefab/gateway/api-gateway/api-http.d.ts +27 -0
- package/.dist/prefab/gateway/api-gateway/api-http.d.ts.map +1 -0
- package/.dist/prefab/gateway/api-gateway/api-http.js.map +1 -0
- package/.dist/prefab/gateway/api-gateway/api-rest.d.ts +23 -0
- package/.dist/prefab/gateway/api-gateway/api-rest.d.ts.map +1 -0
- package/.dist/prefab/gateway/api-gateway/api-rest.js.map +1 -0
- package/.dist/prefab/gateway/api-gateway/index.d.ts +3 -0
- package/.dist/prefab/gateway/app-sync/index.d.ts +31 -0
- package/.dist/prefab/gateway/app-sync/index.d.ts.map +1 -0
- package/.dist/prefab/gateway/app-sync/index.js.map +1 -0
- package/.dist/prefab/gateway/app-sync/resolver-aggregate.d.ts +33 -0
- package/.dist/prefab/gateway/app-sync/resolver-aggregate.d.ts.map +1 -0
- package/.dist/prefab/gateway/app-sync/resolver-aggregate.js.map +1 -0
- package/.dist/prefab/gateway/app-sync/types.d.ts +29 -0
- package/.dist/prefab/gateway/app-sync/types.d.ts.map +1 -0
- package/.dist/prefab/gateway/index.d.ts +4 -0
- package/.dist/prefab/index.d.ts +11 -0
- package/.dist/prefab/integration/event-bus/index.d.ts +18 -0
- package/.dist/prefab/integration/event-bus/index.d.ts.map +1 -0
- package/.dist/prefab/integration/event-bus/index.js.map +1 -0
- package/.dist/prefab/integration/index.d.ts +4 -0
- package/.dist/prefab/integration/queue/index.d.ts +29 -0
- package/.dist/prefab/integration/queue/index.d.ts.map +1 -0
- package/.dist/prefab/integration/queue/index.js.map +1 -0
- package/.dist/prefab/integration/topic/index.d.ts +19 -0
- package/.dist/prefab/integration/topic/index.d.ts.map +1 -0
- package/.dist/prefab/integration/topic/index.js.map +1 -0
- package/.dist/prefab/networking/dns-domain-ref/index.d.ts +14 -0
- package/.dist/prefab/networking/dns-domain-ref/index.d.ts.map +1 -0
- package/.dist/prefab/networking/dns-domain-ref/index.js.map +1 -0
- package/.dist/prefab/networking/dns-subdomain-certificate/index.d.ts +11 -0
- package/.dist/prefab/networking/dns-subdomain-certificate/index.d.ts.map +1 -0
- package/.dist/prefab/networking/dns-subdomain-certificate/index.js.map +1 -0
- package/.dist/prefab/networking/dns-subdomain-hosted-zone/index.d.ts +10 -0
- package/.dist/prefab/networking/dns-subdomain-hosted-zone/index.d.ts.map +1 -0
- package/.dist/prefab/networking/dns-subdomain-hosted-zone/index.js.map +1 -0
- package/.dist/prefab/networking/index.d.ts +6 -0
- package/.dist/prefab/networking/vpc/index.d.ts +18 -0
- package/.dist/prefab/networking/vpc/index.d.ts.map +1 -0
- package/.dist/prefab/networking/vpc/index.js.map +1 -0
- package/.dist/prefab/networking/waf/index.d.ts +12 -0
- package/.dist/prefab/networking/waf/index.d.ts.map +1 -0
- package/.dist/prefab/networking/waf/index.js.map +1 -0
- package/.dist/prefab/storage/bucket/asset-bucket.d.ts +10 -0
- package/.dist/prefab/storage/bucket/asset-bucket.d.ts.map +1 -0
- package/.dist/prefab/storage/bucket/index.d.ts +3 -0
- package/.dist/prefab/storage/bucket/private-bucket.d.ts +32 -0
- package/.dist/prefab/storage/bucket/private-bucket.d.ts.map +1 -0
- package/.dist/prefab/storage/bucket/private-bucket.js.map +1 -0
- package/.dist/prefab/storage/index.d.ts +2 -0
- package/.dist/prefab/utils/config/frontend-env-builder.d.ts +12 -0
- package/.dist/prefab/utils/config/frontend-env-builder.d.ts.map +1 -0
- package/.dist/prefab/utils/config/frontend-env-builder.js.map +1 -0
- package/.dist/prefab/utils/config/index.d.ts +4 -0
- package/.dist/prefab/utils/config/parameter-secret.d.ts +19 -0
- package/.dist/prefab/utils/config/parameter-secret.d.ts.map +1 -0
- package/.dist/prefab/utils/config/parameter-secret.js.map +1 -0
- package/.dist/prefab/utils/config/runtime-secret.d.ts.map +1 -0
- package/.dist/prefab/utils/config/runtime-secret.js.map +1 -0
- package/.dist/prefab/utils/deploy-pipeline/catalog/integrations/index.d.ts +2 -0
- package/.dist/prefab/utils/deploy-pipeline/entities/index.d.ts +29 -0
- package/.dist/prefab/utils/deploy-pipeline/index.d.ts +13 -0
- package/.dist/prefab/utils/deploy-pipeline/index.d.ts.map +1 -0
- package/.dist/prefab/utils/deploy-pipeline/index.js.map +1 -0
- package/.dist/prefab/utils/deploy-pipeline/platform/get-pipeline-detail.d.ts +6 -0
- package/.dist/prefab/utils/deploy-pipeline/platform/get-slack-payload.d.ts +3 -0
- package/.dist/prefab/utils/duration.d.ts +2 -0
- package/.dist/prefab/utils/index.d.ts +5 -0
- package/.dist/prefab/utils/ses/index.d.ts +20 -0
- package/.dist/prefab/utils/ses/index.d.ts.map +1 -0
- package/.dist/prefab/utils/ses/index.js.map +1 -0
- package/.dist/script/config-command/bootstrap.d.ts +3 -0
- package/.dist/script/config-command/bootstrap.js +65 -0
- package/.dist/script/config-command/bootstrap.js.map +1 -0
- package/.dist/script/config-command/deploy-spa.d.ts +3 -0
- package/.dist/script/config-command/deploy-spa.d.ts.map +1 -0
- package/.dist/script/config-command/deploy-spa.js +82 -0
- package/.dist/script/config-command/deploy-spa.js.map +1 -0
- package/.dist/script/config-command/deploy.d.ts +3 -0
- package/.dist/script/config-command/deploy.js +26 -0
- package/.dist/script/config-command/deploy.js.map +1 -0
- package/.dist/script/config-command/destroy.d.ts +3 -0
- package/.dist/script/config-command/destroy.js +26 -0
- package/.dist/script/config-command/destroy.js.map +1 -0
- package/.dist/script/config-command/env-ssr.d.ts +3 -0
- package/.dist/script/config-command/env-ssr.js +49 -0
- package/.dist/script/config-command/env-ssr.js.map +1 -0
- package/.dist/script/config-command/invalidation-ssr.d.ts +3 -0
- package/.dist/script/config-command/invalidation-ssr.js +53 -0
- package/.dist/script/config-command/invalidation-ssr.js.map +1 -0
- package/.dist/script/config-command/rds-migration.d.ts +5 -0
- package/.dist/script/config-command/rds-migration.js.map +1 -0
- package/.dist/script/config-command/rds-sync.d.ts +3 -0
- package/.dist/script/config-command/rds-sync.js.map +1 -0
- package/.dist/script/config-command/ssm-connect.d.ts +3 -0
- package/.dist/script/config-command/ssm-connect.js.map +1 -0
- package/.dist/script/config-command/start-spa.d.ts +3 -0
- package/.dist/script/config-command/start-spa.js +53 -0
- package/.dist/script/config-command/start-spa.js.map +1 -0
- package/.dist/script/config-command/start-ssr.d.ts +3 -0
- package/.dist/script/config-command/start-ssr.js +53 -0
- package/.dist/script/config-command/start-ssr.js.map +1 -0
- package/.dist/script/config-command/synth.d.ts +3 -0
- package/.dist/script/config-command/synth.js +26 -0
- package/.dist/script/config-command/synth.js.map +1 -0
- package/.dist/script/index.d.ts +7 -0
- package/.dist/script/index.d.ts.map +1 -0
- package/.dist/script/output-command/create-user.d.ts +9 -0
- package/.dist/script/output-command/create-user.d.ts.map +1 -0
- package/.dist/script/output-command/create-user.js.map +1 -0
- package/.dist/script/output-command/gen-postman-env.d.ts +9 -0
- package/.dist/script/output-command/gen-postman-env.d.ts.map +1 -0
- package/.dist/script/output-command/gen-postman-env.js +55 -0
- package/.dist/script/output-command/gen-postman-env.js.map +1 -0
- package/.dist/tsconfig.tsbuildinfo +1 -0
- package/.prettierignore +10 -0
- package/.prettierrc.json +12 -0
- package/.turbo/turbo-build.log +5 -0
- package/.turbo/turbo-release.log +7 -0
- package/CHANGELOG.md +8 -0
- package/common/coordinator.ts +103 -0
- package/common/index.ts +5 -0
- package/common/modifier.ts +11 -0
- package/common/naming/get-deploy-config.ts +5 -0
- package/common/naming/get-domain.ts +14 -0
- package/common/naming/get-function-entry.ts +11 -0
- package/common/naming/get-logical-name.ts +3 -0
- package/common/naming/get-resource-name.ts +77 -0
- package/common/naming/get-service-name.ts +13 -0
- package/common/naming/index.ts +7 -0
- package/common/naming/string-parser.ts +17 -0
- package/common/service.ts +48 -0
- package/common/synth/account-mapping.ts +16 -0
- package/common/synth/assume-role.ts +39 -0
- package/common/synth/get-global-props.ts +46 -0
- package/common/synth/get-service-props.ts +16 -0
- package/common/synth/index.ts +7 -0
- package/common/synth/pre-script.ts +103 -0
- package/common/synth/props-types.ts +79 -0
- package/common/synth/synth-error.ts +13 -0
- package/index.ts +3 -0
- package/package.json +4 -5
- package/prefab/analytics/events/handlers/ingestion-transform/handler.ts +35 -0
- package/prefab/analytics/events/index.ts +192 -0
- package/prefab/analytics/index.ts +1 -0
- package/prefab/auth/cognito-pool/index.ts +263 -0
- package/prefab/auth/index.ts +1 -0
- package/prefab/cdn/cdn-api/index.ts +169 -0
- package/prefab/cdn/cdn-asset/index.ts +89 -0
- package/prefab/cdn/cdn-spa/index.ts +136 -0
- package/prefab/cdn/cdn-ssr/index.ts +288 -0
- package/prefab/cdn/index.ts +4 -0
- package/prefab/compute/fargate/cluster.ts +24 -0
- package/prefab/compute/fargate/index.ts +2 -0
- package/prefab/compute/fargate/service.ts +130 -0
- package/prefab/compute/function/api-function/api-aggregate.ts +73 -0
- package/prefab/compute/function/api-function/api-function.ts +63 -0
- package/prefab/compute/function/api-function/index.ts +2 -0
- package/prefab/compute/function/base-function/index.ts +102 -0
- package/prefab/compute/function/cognito-function/cognito-aggregate.ts +29 -0
- package/prefab/compute/function/cognito-function/cognito-function.ts +36 -0
- package/prefab/compute/function/cognito-function/index.ts +2 -0
- package/prefab/compute/function/cron-function/cron-aggregate.ts +28 -0
- package/prefab/compute/function/cron-function/cron-function.ts +32 -0
- package/prefab/compute/function/cron-function/index.ts +2 -0
- package/prefab/compute/function/event-function/EventAggregateParams.ts +9 -0
- package/prefab/compute/function/event-function/event-aggregate.ts +33 -0
- package/prefab/compute/function/event-function/event-function.ts +42 -0
- package/prefab/compute/function/event-function/index.ts +2 -0
- package/prefab/compute/function/index.ts +7 -0
- package/prefab/compute/function/queue-function/index.ts +67 -0
- package/prefab/compute/function/topic-function/index.ts +36 -0
- package/prefab/compute/index.ts +2 -0
- package/prefab/database/dynamo/index.ts +113 -0
- package/prefab/database/index.ts +3 -0
- package/prefab/database/rds/handlers/start-cluster/handler.ts +7 -0
- package/prefab/database/rds/handlers/stop-cluster/handler.ts +7 -0
- package/prefab/database/rds/index.ts +248 -0
- package/prefab/database/timestream/index.ts +2 -0
- package/prefab/database/timestream/timestream-database.ts +24 -0
- package/prefab/database/timestream/timestream-table.ts +76 -0
- package/prefab/gateway/alb-public/index.ts +124 -0
- package/prefab/gateway/api-gateway/api-http.ts +71 -0
- package/prefab/gateway/api-gateway/api-rest.ts +93 -0
- package/prefab/gateway/api-gateway/index.ts +2 -0
- package/prefab/gateway/app-sync/index.ts +117 -0
- package/prefab/gateway/app-sync/resolver-aggregate.ts +138 -0
- package/prefab/gateway/app-sync/types.ts +29 -0
- package/prefab/gateway/index.ts +3 -0
- package/prefab/index.ts +10 -0
- package/prefab/integration/event-bus/index.ts +52 -0
- package/prefab/integration/index.ts +3 -0
- package/prefab/integration/queue/index.ts +94 -0
- package/prefab/integration/topic/index.ts +57 -0
- package/prefab/networking/dns-domain-ref/index.ts +32 -0
- package/prefab/networking/dns-subdomain-certificate/index.ts +30 -0
- package/prefab/networking/dns-subdomain-hosted-zone/index.ts +30 -0
- package/prefab/networking/index.ts +5 -0
- package/prefab/networking/vpc/index.ts +39 -0
- package/prefab/networking/waf/index.ts +49 -0
- package/prefab/storage/bucket/asset-bucket.ts +24 -0
- package/prefab/storage/bucket/index.ts +2 -0
- package/prefab/storage/bucket/private-bucket.ts +74 -0
- package/prefab/storage/index.ts +1 -0
- package/prefab/utils/config/frontend-env-builder.ts +30 -0
- package/prefab/utils/config/index.ts +3 -0
- package/prefab/utils/config/parameter-secret.ts +52 -0
- package/prefab/utils/config/runtime-secret.ts +48 -0
- package/prefab/utils/deploy-pipeline/catalog/integrations/index.ts +1 -0
- package/prefab/utils/deploy-pipeline/catalog/integrations/slack.ts +23 -0
- package/prefab/utils/deploy-pipeline/entities/index.ts +23 -0
- package/prefab/utils/deploy-pipeline/handlers/send-to-slack/handler.ts +32 -0
- package/prefab/utils/deploy-pipeline/index.ts +172 -0
- package/prefab/utils/deploy-pipeline/platform/get-pipeline-detail.ts +31 -0
- package/prefab/utils/deploy-pipeline/platform/get-slack-payload.ts +38 -0
- package/prefab/utils/deploy-pipeline/platform/send-to-slack.ts +16 -0
- package/prefab/utils/duration.ts +1 -0
- package/prefab/utils/index.ts +4 -0
- package/prefab/utils/ses/index.ts +134 -0
- package/readme.md +78 -0
- package/script/config-command/bootstrap.ts +108 -0
- package/script/config-command/deploy-spa.ts +126 -0
- package/script/config-command/deploy.ts +50 -0
- package/script/config-command/destroy.ts +49 -0
- package/script/config-command/env-ssr.ts +85 -0
- package/script/config-command/invalidation-ssr.ts +88 -0
- package/script/config-command/rds-migration.ts +177 -0
- package/script/config-command/rds-sync.ts +108 -0
- package/script/config-command/ssm-connect.ts +129 -0
- package/script/config-command/start-spa.ts +93 -0
- package/script/config-command/start-ssr.ts +91 -0
- package/script/config-command/synth.ts +50 -0
- package/script/index.ts +86 -0
- package/script/output-command/create-user.ts +89 -0
- package/script/output-command/gen-postman-env.ts +75 -0
- package/tsconfig.json +26 -0
- package/common/coordinator.d.ts +0 -28
- package/common/index.d.ts +0 -6
- package/common/modifier.d.ts +0 -5
- package/common/naming/get-deploy-config.d.ts +0 -9
- package/common/naming/get-domain.d.ts +0 -9
- package/common/naming/get-function-entry.d.ts +0 -4
- package/common/naming/get-logical-name.d.ts +0 -2
- package/common/naming/get-resource-name.d.ts +0 -47
- package/common/naming/get-service-name.d.ts +0 -10
- package/common/naming/index.d.ts +0 -8
- package/common/naming/string-parser.d.ts +0 -4
- package/common/service.d.ts +0 -29
- package/common/synth/account-mapping.d.ts +0 -2
- package/common/synth/assume-role.d.ts +0 -18
- package/common/synth/get-global-props.d.ts +0 -16
- package/common/synth/get-service-props.d.ts +0 -11
- package/common/synth/index.d.ts +0 -8
- package/common/synth/pre-script.d.ts +0 -32
- package/common/synth/props-types.d.ts +0 -60
- package/common/synth/synth-error.d.ts +0 -8
- package/index.d.ts +0 -4
- package/prefab/analytics/events/handlers/ingestion-transform/handler.d.ts +0 -4
- package/prefab/analytics/events/index.d.ts +0 -31
- package/prefab/analytics/events/index.d.ts.map +0 -1
- package/prefab/analytics/events/index.js +0 -163
- package/prefab/analytics/events/index.js.map +0 -1
- package/prefab/analytics/index.d.ts +0 -2
- package/prefab/auth/cognito-pool/index.d.ts +0 -65
- package/prefab/auth/cognito-pool/index.d.ts.map +0 -1
- package/prefab/auth/cognito-pool/index.js.map +0 -1
- package/prefab/auth/index.d.ts +0 -2
- package/prefab/cdn/cdn-api/index.d.ts +0 -38
- package/prefab/cdn/cdn-api/index.d.ts.map +0 -1
- package/prefab/cdn/cdn-api/index.js +0 -153
- package/prefab/cdn/cdn-api/index.js.map +0 -1
- package/prefab/cdn/cdn-asset/index.d.ts +0 -27
- package/prefab/cdn/cdn-asset/index.d.ts.map +0 -1
- package/prefab/cdn/cdn-asset/index.js +0 -96
- package/prefab/cdn/cdn-asset/index.js.map +0 -1
- package/prefab/cdn/cdn-spa/index.d.ts +0 -27
- package/prefab/cdn/cdn-spa/index.d.ts.map +0 -1
- package/prefab/cdn/cdn-spa/index.js +0 -138
- package/prefab/cdn/cdn-spa/index.js.map +0 -1
- package/prefab/cdn/cdn-ssr/index.d.ts +0 -36
- package/prefab/cdn/cdn-ssr/index.d.ts.map +0 -1
- package/prefab/cdn/cdn-ssr/index.js +0 -271
- package/prefab/cdn/cdn-ssr/index.js.map +0 -1
- package/prefab/cdn/index.d.ts +0 -5
- package/prefab/compute/fargate/cluster.d.ts +0 -16
- package/prefab/compute/fargate/cluster.d.ts.map +0 -1
- package/prefab/compute/fargate/cluster.js.map +0 -1
- package/prefab/compute/fargate/index.d.ts +0 -3
- package/prefab/compute/fargate/service.d.ts +0 -49
- package/prefab/compute/fargate/service.d.ts.map +0 -1
- package/prefab/compute/fargate/service.js.map +0 -1
- package/prefab/compute/function/api-function/api-aggregate.d.ts +0 -32
- package/prefab/compute/function/api-function/api-aggregate.d.ts.map +0 -1
- package/prefab/compute/function/api-function/api-aggregate.js +0 -54
- package/prefab/compute/function/api-function/api-aggregate.js.map +0 -1
- package/prefab/compute/function/api-function/api-function.d.ts +0 -22
- package/prefab/compute/function/api-function/api-function.d.ts.map +0 -1
- package/prefab/compute/function/api-function/api-function.js +0 -45
- package/prefab/compute/function/api-function/api-function.js.map +0 -1
- package/prefab/compute/function/api-function/index.d.ts +0 -3
- package/prefab/compute/function/base-function/index.d.ts +0 -33
- package/prefab/compute/function/base-function/index.d.ts.map +0 -1
- package/prefab/compute/function/base-function/index.js +0 -70
- package/prefab/compute/function/base-function/index.js.map +0 -1
- package/prefab/compute/function/cognito-function/cognito-aggregate.d.ts +0 -18
- package/prefab/compute/function/cognito-function/cognito-aggregate.d.ts.map +0 -1
- package/prefab/compute/function/cognito-function/cognito-aggregate.js.map +0 -1
- package/prefab/compute/function/cognito-function/cognito-function.d.ts +0 -19
- package/prefab/compute/function/cognito-function/cognito-function.d.ts.map +0 -1
- package/prefab/compute/function/cognito-function/cognito-function.js.map +0 -1
- package/prefab/compute/function/cognito-function/index.d.ts +0 -3
- package/prefab/compute/function/cron-function/cron-aggregate.d.ts +0 -17
- package/prefab/compute/function/cron-function/cron-aggregate.d.ts.map +0 -1
- package/prefab/compute/function/cron-function/cron-aggregate.js.map +0 -1
- package/prefab/compute/function/cron-function/cron-function.d.ts +0 -17
- package/prefab/compute/function/cron-function/cron-function.d.ts.map +0 -1
- package/prefab/compute/function/cron-function/cron-function.js +0 -24
- package/prefab/compute/function/cron-function/cron-function.js.map +0 -1
- package/prefab/compute/function/cron-function/index.d.ts +0 -3
- package/prefab/compute/function/event-function/event-aggregate.d.ts +0 -20
- package/prefab/compute/function/event-function/event-aggregate.d.ts.map +0 -1
- package/prefab/compute/function/event-function/event-aggregate.js.map +0 -1
- package/prefab/compute/function/event-function/event-function.d.ts +0 -14
- package/prefab/compute/function/event-function/event-function.d.ts.map +0 -1
- package/prefab/compute/function/event-function/event-function.js.map +0 -1
- package/prefab/compute/function/event-function/index.d.ts +0 -3
- package/prefab/compute/function/index.d.ts +0 -8
- package/prefab/compute/function/queue-function/index.d.ts +0 -25
- package/prefab/compute/function/queue-function/index.d.ts.map +0 -1
- package/prefab/compute/function/queue-function/index.js +0 -46
- package/prefab/compute/function/queue-function/index.js.map +0 -1
- package/prefab/compute/function/topic-function/index.d.ts +0 -23
- package/prefab/compute/function/topic-function/index.d.ts.map +0 -1
- package/prefab/compute/function/topic-function/index.js +0 -23
- package/prefab/compute/function/topic-function/index.js.map +0 -1
- package/prefab/compute/index.d.ts +0 -3
- package/prefab/database/dynamo/index.d.ts +0 -14
- package/prefab/database/dynamo/index.d.ts.map +0 -1
- package/prefab/database/dynamo/index.js.map +0 -1
- package/prefab/database/index.d.ts +0 -4
- package/prefab/database/rds/handlers/start-cluster/handler.d.ts +0 -2
- package/prefab/database/rds/handlers/stop-cluster/handler.d.ts +0 -2
- package/prefab/database/rds/index.d.ts +0 -54
- package/prefab/database/rds/index.d.ts.map +0 -1
- package/prefab/database/rds/index.js +0 -223
- package/prefab/database/rds/index.js.map +0 -1
- package/prefab/database/timestream/index.d.ts +0 -3
- package/prefab/database/timestream/timestream-database.d.ts +0 -13
- package/prefab/database/timestream/timestream-database.d.ts.map +0 -1
- package/prefab/database/timestream/timestream-database.js.map +0 -1
- package/prefab/database/timestream/timestream-table.d.ts +0 -23
- package/prefab/database/timestream/timestream-table.d.ts.map +0 -1
- package/prefab/database/timestream/timestream-table.js.map +0 -1
- package/prefab/gateway/alb-public/index.d.ts +0 -44
- package/prefab/gateway/alb-public/index.d.ts.map +0 -1
- package/prefab/gateway/alb-public/index.js.map +0 -1
- package/prefab/gateway/api-gateway/api-http.d.ts +0 -27
- package/prefab/gateway/api-gateway/api-http.d.ts.map +0 -1
- package/prefab/gateway/api-gateway/api-http.js.map +0 -1
- package/prefab/gateway/api-gateway/api-rest.d.ts +0 -26
- package/prefab/gateway/api-gateway/api-rest.d.ts.map +0 -1
- package/prefab/gateway/api-gateway/api-rest.js.map +0 -1
- package/prefab/gateway/api-gateway/index.d.ts +0 -3
- package/prefab/gateway/app-sync/index.d.ts +0 -36
- package/prefab/gateway/app-sync/index.d.ts.map +0 -1
- package/prefab/gateway/app-sync/index.js.map +0 -1
- package/prefab/gateway/app-sync/resolver-aggregate.d.ts +0 -33
- package/prefab/gateway/app-sync/resolver-aggregate.d.ts.map +0 -1
- package/prefab/gateway/app-sync/resolver-aggregate.js.map +0 -1
- package/prefab/gateway/app-sync/types.d.ts +0 -29
- package/prefab/gateway/app-sync/types.d.ts.map +0 -1
- package/prefab/gateway/index.d.ts +0 -4
- package/prefab/index.d.ts +0 -11
- package/prefab/integration/event-bus/index.d.ts +0 -20
- package/prefab/integration/event-bus/index.d.ts.map +0 -1
- package/prefab/integration/event-bus/index.js.map +0 -1
- package/prefab/integration/index.d.ts +0 -4
- package/prefab/integration/queue/index.d.ts +0 -29
- package/prefab/integration/queue/index.d.ts.map +0 -1
- package/prefab/integration/queue/index.js.map +0 -1
- package/prefab/integration/topic/index.d.ts +0 -21
- package/prefab/integration/topic/index.d.ts.map +0 -1
- package/prefab/integration/topic/index.js.map +0 -1
- package/prefab/networking/dns-domain-ref/index.d.ts +0 -16
- package/prefab/networking/dns-domain-ref/index.d.ts.map +0 -1
- package/prefab/networking/dns-domain-ref/index.js.map +0 -1
- package/prefab/networking/dns-subdomain-certificate/index.d.ts +0 -13
- package/prefab/networking/dns-subdomain-certificate/index.d.ts.map +0 -1
- package/prefab/networking/dns-subdomain-certificate/index.js.map +0 -1
- package/prefab/networking/dns-subdomain-hosted-zone/index.d.ts +0 -12
- package/prefab/networking/dns-subdomain-hosted-zone/index.d.ts.map +0 -1
- package/prefab/networking/dns-subdomain-hosted-zone/index.js.map +0 -1
- package/prefab/networking/index.d.ts +0 -6
- package/prefab/networking/vpc/index.d.ts +0 -20
- package/prefab/networking/vpc/index.d.ts.map +0 -1
- package/prefab/networking/vpc/index.js.map +0 -1
- package/prefab/networking/waf/index.d.ts +0 -14
- package/prefab/networking/waf/index.d.ts.map +0 -1
- package/prefab/networking/waf/index.js.map +0 -1
- package/prefab/storage/bucket/asset-bucket.d.ts +0 -12
- package/prefab/storage/bucket/asset-bucket.d.ts.map +0 -1
- package/prefab/storage/bucket/index.d.ts +0 -3
- package/prefab/storage/bucket/private-bucket.d.ts +0 -26
- package/prefab/storage/bucket/private-bucket.d.ts.map +0 -1
- package/prefab/storage/bucket/private-bucket.js.map +0 -1
- package/prefab/storage/index.d.ts +0 -2
- package/prefab/utils/config/frontend-env-builder.d.ts +0 -14
- package/prefab/utils/config/frontend-env-builder.d.ts.map +0 -1
- package/prefab/utils/config/frontend-env-builder.js.map +0 -1
- package/prefab/utils/config/index.d.ts +0 -4
- package/prefab/utils/config/parameter-secret.d.ts +0 -21
- package/prefab/utils/config/parameter-secret.d.ts.map +0 -1
- package/prefab/utils/config/parameter-secret.js.map +0 -1
- package/prefab/utils/config/runtime-secret.d.ts.map +0 -1
- package/prefab/utils/config/runtime-secret.js.map +0 -1
- package/prefab/utils/deploy-pipeline/catalog/integrations/index.d.ts +0 -2
- package/prefab/utils/deploy-pipeline/entities/index.d.ts +0 -29
- package/prefab/utils/deploy-pipeline/index.d.ts +0 -15
- package/prefab/utils/deploy-pipeline/index.d.ts.map +0 -1
- package/prefab/utils/deploy-pipeline/index.js.map +0 -1
- package/prefab/utils/deploy-pipeline/platform/get-pipeline-detail.d.ts +0 -6
- package/prefab/utils/deploy-pipeline/platform/get-slack-payload.d.ts +0 -4
- package/prefab/utils/duration.d.ts +0 -2
- package/prefab/utils/index.d.ts +0 -5
- package/prefab/utils/ses/index.d.ts +0 -22
- package/prefab/utils/ses/index.d.ts.map +0 -1
- package/prefab/utils/ses/index.js.map +0 -1
- package/script/config-command/bootstrap.d.ts +0 -4
- package/script/config-command/bootstrap.js +0 -66
- package/script/config-command/bootstrap.js.map +0 -1
- package/script/config-command/deploy-spa.d.ts +0 -4
- package/script/config-command/deploy-spa.d.ts.map +0 -1
- package/script/config-command/deploy-spa.js +0 -84
- package/script/config-command/deploy-spa.js.map +0 -1
- package/script/config-command/deploy.d.ts +0 -4
- package/script/config-command/deploy.js +0 -26
- package/script/config-command/deploy.js.map +0 -1
- package/script/config-command/destroy.d.ts +0 -4
- package/script/config-command/destroy.js +0 -26
- package/script/config-command/destroy.js.map +0 -1
- package/script/config-command/env-ssr.d.ts +0 -4
- package/script/config-command/env-ssr.js +0 -51
- package/script/config-command/env-ssr.js.map +0 -1
- package/script/config-command/invalidation-ssr.d.ts +0 -4
- package/script/config-command/invalidation-ssr.js +0 -55
- package/script/config-command/invalidation-ssr.js.map +0 -1
- package/script/config-command/rds-migration.d.ts +0 -7
- package/script/config-command/rds-migration.js.map +0 -1
- package/script/config-command/rds-sync.d.ts +0 -4
- package/script/config-command/rds-sync.js.map +0 -1
- package/script/config-command/ssm-connect.d.ts +0 -4
- package/script/config-command/ssm-connect.js.map +0 -1
- package/script/config-command/start-spa.d.ts +0 -4
- package/script/config-command/start-spa.js +0 -55
- package/script/config-command/start-spa.js.map +0 -1
- package/script/config-command/start-ssr.d.ts +0 -4
- package/script/config-command/start-ssr.js +0 -55
- package/script/config-command/start-ssr.js.map +0 -1
- package/script/config-command/synth.d.ts +0 -4
- package/script/config-command/synth.js +0 -26
- package/script/config-command/synth.js.map +0 -1
- package/script/index.d.ts +0 -25
- package/script/index.d.ts.map +0 -1
- package/script/output-command/create-user.d.ts +0 -9
- package/script/output-command/create-user.d.ts.map +0 -1
- package/script/output-command/create-user.js.map +0 -1
- package/script/output-command/gen-postman-env.d.ts +0 -28
- package/script/output-command/gen-postman-env.d.ts.map +0 -1
- package/script/output-command/gen-postman-env.js +0 -56
- package/script/output-command/gen-postman-env.js.map +0 -1
- package/tsconfig.tsbuildinfo +0 -1
- /package/{common → .dist/common}/coordinator.d.ts.map +0 -0
- /package/{common → .dist/common}/coordinator.js +0 -0
- /package/{common → .dist/common}/coordinator.js.map +0 -0
- /package/{common → .dist/common}/index.d.ts.map +0 -0
- /package/{common → .dist/common}/index.js +0 -0
- /package/{common → .dist/common}/index.js.map +0 -0
- /package/{common → .dist/common}/modifier.d.ts.map +0 -0
- /package/{common → .dist/common}/modifier.js +0 -0
- /package/{common → .dist/common}/modifier.js.map +0 -0
- /package/{common → .dist/common}/naming/get-deploy-config.d.ts.map +0 -0
- /package/{common → .dist/common}/naming/get-deploy-config.js +0 -0
- /package/{common → .dist/common}/naming/get-deploy-config.js.map +0 -0
- /package/{common → .dist/common}/naming/get-domain.d.ts.map +0 -0
- /package/{common → .dist/common}/naming/get-domain.js +0 -0
- /package/{common → .dist/common}/naming/get-domain.js.map +0 -0
- /package/{common → .dist/common}/naming/get-function-entry.d.ts.map +0 -0
- /package/{common → .dist/common}/naming/get-function-entry.js +0 -0
- /package/{common → .dist/common}/naming/get-function-entry.js.map +0 -0
- /package/{common → .dist/common}/naming/get-logical-name.d.ts.map +0 -0
- /package/{common → .dist/common}/naming/get-logical-name.js +0 -0
- /package/{common → .dist/common}/naming/get-logical-name.js.map +0 -0
- /package/{common → .dist/common}/naming/get-resource-name.d.ts.map +0 -0
- /package/{common → .dist/common}/naming/get-resource-name.js +0 -0
- /package/{common → .dist/common}/naming/get-resource-name.js.map +0 -0
- /package/{common → .dist/common}/naming/get-service-name.d.ts.map +0 -0
- /package/{common → .dist/common}/naming/get-service-name.js +0 -0
- /package/{common → .dist/common}/naming/get-service-name.js.map +0 -0
- /package/{common → .dist/common}/naming/index.d.ts.map +0 -0
- /package/{common → .dist/common}/naming/index.js +0 -0
- /package/{common → .dist/common}/naming/index.js.map +0 -0
- /package/{common → .dist/common}/naming/string-parser.d.ts.map +0 -0
- /package/{common → .dist/common}/naming/string-parser.js +0 -0
- /package/{common → .dist/common}/naming/string-parser.js.map +0 -0
- /package/{common → .dist/common}/service.d.ts.map +0 -0
- /package/{common → .dist/common}/service.js +0 -0
- /package/{common → .dist/common}/service.js.map +0 -0
- /package/{common → .dist/common}/synth/account-mapping.d.ts.map +0 -0
- /package/{common → .dist/common}/synth/account-mapping.js +0 -0
- /package/{common → .dist/common}/synth/account-mapping.js.map +0 -0
- /package/{common → .dist/common}/synth/assume-role.d.ts.map +0 -0
- /package/{common → .dist/common}/synth/assume-role.js +0 -0
- /package/{common → .dist/common}/synth/assume-role.js.map +0 -0
- /package/{common → .dist/common}/synth/get-global-props.d.ts.map +0 -0
- /package/{common → .dist/common}/synth/get-global-props.js +0 -0
- /package/{common → .dist/common}/synth/get-global-props.js.map +0 -0
- /package/{common → .dist/common}/synth/get-service-props.d.ts.map +0 -0
- /package/{common → .dist/common}/synth/get-service-props.js +0 -0
- /package/{common → .dist/common}/synth/get-service-props.js.map +0 -0
- /package/{common → .dist/common}/synth/index.d.ts.map +0 -0
- /package/{common → .dist/common}/synth/index.js +0 -0
- /package/{common → .dist/common}/synth/index.js.map +0 -0
- /package/{common → .dist/common}/synth/pre-script.d.ts.map +0 -0
- /package/{common → .dist/common}/synth/pre-script.js +0 -0
- /package/{common → .dist/common}/synth/pre-script.js.map +0 -0
- /package/{common → .dist/common}/synth/props-types.d.ts.map +0 -0
- /package/{common → .dist/common}/synth/props-types.js +0 -0
- /package/{common → .dist/common}/synth/props-types.js.map +0 -0
- /package/{common → .dist/common}/synth/synth-error.d.ts.map +0 -0
- /package/{common → .dist/common}/synth/synth-error.js +0 -0
- /package/{common → .dist/common}/synth/synth-error.js.map +0 -0
- /package/{index.d.ts.map → .dist/index.d.ts.map} +0 -0
- /package/{index.js → .dist/index.js} +0 -0
- /package/{index.js.map → .dist/index.js.map} +0 -0
- /package/{prefab → .dist/prefab}/analytics/events/handlers/ingestion-transform/handler.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/analytics/events/handlers/ingestion-transform/handler.js +0 -0
- /package/{prefab → .dist/prefab}/analytics/events/handlers/ingestion-transform/handler.js.map +0 -0
- /package/{prefab → .dist/prefab}/analytics/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/analytics/index.js +0 -0
- /package/{prefab → .dist/prefab}/analytics/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/auth/cognito-pool/index.js +0 -0
- /package/{prefab → .dist/prefab}/auth/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/auth/index.js +0 -0
- /package/{prefab → .dist/prefab}/auth/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/cdn/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/cdn/index.js +0 -0
- /package/{prefab → .dist/prefab}/cdn/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/compute/fargate/cluster.js +0 -0
- /package/{prefab → .dist/prefab}/compute/fargate/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/compute/fargate/index.js +0 -0
- /package/{prefab → .dist/prefab}/compute/fargate/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/compute/fargate/service.js +0 -0
- /package/{prefab → .dist/prefab}/compute/function/api-function/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/compute/function/api-function/index.js +0 -0
- /package/{prefab → .dist/prefab}/compute/function/api-function/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/compute/function/cognito-function/cognito-aggregate.js +0 -0
- /package/{prefab → .dist/prefab}/compute/function/cognito-function/cognito-function.js +0 -0
- /package/{prefab → .dist/prefab}/compute/function/cognito-function/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/compute/function/cognito-function/index.js +0 -0
- /package/{prefab → .dist/prefab}/compute/function/cognito-function/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/compute/function/cron-function/cron-aggregate.js +0 -0
- /package/{prefab → .dist/prefab}/compute/function/cron-function/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/compute/function/cron-function/index.js +0 -0
- /package/{prefab → .dist/prefab}/compute/function/cron-function/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/compute/function/event-function/event-aggregate.js +0 -0
- /package/{prefab → .dist/prefab}/compute/function/event-function/event-function.js +0 -0
- /package/{prefab → .dist/prefab}/compute/function/event-function/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/compute/function/event-function/index.js +0 -0
- /package/{prefab → .dist/prefab}/compute/function/event-function/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/compute/function/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/compute/function/index.js +0 -0
- /package/{prefab → .dist/prefab}/compute/function/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/compute/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/compute/index.js +0 -0
- /package/{prefab → .dist/prefab}/compute/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/database/dynamo/index.js +0 -0
- /package/{prefab → .dist/prefab}/database/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/database/index.js +0 -0
- /package/{prefab → .dist/prefab}/database/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/database/rds/handlers/start-cluster/handler.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/database/rds/handlers/start-cluster/handler.js +0 -0
- /package/{prefab → .dist/prefab}/database/rds/handlers/start-cluster/handler.js.map +0 -0
- /package/{prefab → .dist/prefab}/database/rds/handlers/stop-cluster/handler.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/database/rds/handlers/stop-cluster/handler.js +0 -0
- /package/{prefab → .dist/prefab}/database/rds/handlers/stop-cluster/handler.js.map +0 -0
- /package/{prefab → .dist/prefab}/database/timestream/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/database/timestream/index.js +0 -0
- /package/{prefab → .dist/prefab}/database/timestream/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/database/timestream/timestream-database.js +0 -0
- /package/{prefab → .dist/prefab}/database/timestream/timestream-table.js +0 -0
- /package/{prefab → .dist/prefab}/gateway/alb-public/index.js +0 -0
- /package/{prefab → .dist/prefab}/gateway/api-gateway/api-http.js +0 -0
- /package/{prefab → .dist/prefab}/gateway/api-gateway/api-rest.js +0 -0
- /package/{prefab → .dist/prefab}/gateway/api-gateway/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/gateway/api-gateway/index.js +0 -0
- /package/{prefab → .dist/prefab}/gateway/api-gateway/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/gateway/app-sync/index.js +0 -0
- /package/{prefab → .dist/prefab}/gateway/app-sync/resolver-aggregate.js +0 -0
- /package/{prefab → .dist/prefab}/gateway/app-sync/types.js +0 -0
- /package/{prefab → .dist/prefab}/gateway/app-sync/types.js.map +0 -0
- /package/{prefab → .dist/prefab}/gateway/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/gateway/index.js +0 -0
- /package/{prefab → .dist/prefab}/gateway/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/index.js +0 -0
- /package/{prefab → .dist/prefab}/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/integration/event-bus/index.js +0 -0
- /package/{prefab → .dist/prefab}/integration/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/integration/index.js +0 -0
- /package/{prefab → .dist/prefab}/integration/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/integration/queue/index.js +0 -0
- /package/{prefab → .dist/prefab}/integration/topic/index.js +0 -0
- /package/{prefab → .dist/prefab}/networking/dns-domain-ref/index.js +0 -0
- /package/{prefab → .dist/prefab}/networking/dns-subdomain-certificate/index.js +0 -0
- /package/{prefab → .dist/prefab}/networking/dns-subdomain-hosted-zone/index.js +0 -0
- /package/{prefab → .dist/prefab}/networking/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/networking/index.js +0 -0
- /package/{prefab → .dist/prefab}/networking/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/networking/vpc/index.js +0 -0
- /package/{prefab → .dist/prefab}/networking/waf/index.js +0 -0
- /package/{prefab → .dist/prefab}/storage/bucket/asset-bucket.js +0 -0
- /package/{prefab → .dist/prefab}/storage/bucket/asset-bucket.js.map +0 -0
- /package/{prefab → .dist/prefab}/storage/bucket/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/storage/bucket/index.js +0 -0
- /package/{prefab → .dist/prefab}/storage/bucket/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/storage/bucket/private-bucket.js +0 -0
- /package/{prefab → .dist/prefab}/storage/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/storage/index.js +0 -0
- /package/{prefab → .dist/prefab}/storage/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/utils/config/frontend-env-builder.js +0 -0
- /package/{prefab → .dist/prefab}/utils/config/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/utils/config/index.js +0 -0
- /package/{prefab → .dist/prefab}/utils/config/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/utils/config/parameter-secret.js +0 -0
- /package/{prefab → .dist/prefab}/utils/config/runtime-secret.d.ts +0 -0
- /package/{prefab → .dist/prefab}/utils/config/runtime-secret.js +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/catalog/integrations/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/catalog/integrations/index.js +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/catalog/integrations/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/catalog/integrations/slack.d.ts +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/catalog/integrations/slack.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/catalog/integrations/slack.js +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/catalog/integrations/slack.js.map +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/entities/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/entities/index.js +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/entities/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/handlers/send-to-slack/handler.d.ts +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/handlers/send-to-slack/handler.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/handlers/send-to-slack/handler.js +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/handlers/send-to-slack/handler.js.map +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/index.js +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/platform/get-pipeline-detail.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/platform/get-pipeline-detail.js +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/platform/get-pipeline-detail.js.map +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/platform/get-slack-payload.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/platform/get-slack-payload.js +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/platform/get-slack-payload.js.map +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/platform/send-to-slack.d.ts +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/platform/send-to-slack.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/platform/send-to-slack.js +0 -0
- /package/{prefab → .dist/prefab}/utils/deploy-pipeline/platform/send-to-slack.js.map +0 -0
- /package/{prefab → .dist/prefab}/utils/duration.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/utils/duration.js +0 -0
- /package/{prefab → .dist/prefab}/utils/duration.js.map +0 -0
- /package/{prefab → .dist/prefab}/utils/index.d.ts.map +0 -0
- /package/{prefab → .dist/prefab}/utils/index.js +0 -0
- /package/{prefab → .dist/prefab}/utils/index.js.map +0 -0
- /package/{prefab → .dist/prefab}/utils/ses/index.js +0 -0
- /package/{script → .dist/script}/config-command/bootstrap.d.ts.map +0 -0
- /package/{script → .dist/script}/config-command/deploy.d.ts.map +0 -0
- /package/{script → .dist/script}/config-command/destroy.d.ts.map +0 -0
- /package/{script → .dist/script}/config-command/env-ssr.d.ts.map +0 -0
- /package/{script → .dist/script}/config-command/invalidation-ssr.d.ts.map +0 -0
- /package/{script → .dist/script}/config-command/rds-migration.d.ts.map +0 -0
- /package/{script → .dist/script}/config-command/rds-migration.js +0 -0
- /package/{script → .dist/script}/config-command/rds-sync.d.ts.map +0 -0
- /package/{script → .dist/script}/config-command/rds-sync.js +0 -0
- /package/{script → .dist/script}/config-command/ssm-connect.d.ts.map +0 -0
- /package/{script → .dist/script}/config-command/ssm-connect.js +0 -0
- /package/{script → .dist/script}/config-command/start-spa.d.ts.map +0 -0
- /package/{script → .dist/script}/config-command/start-ssr.d.ts.map +0 -0
- /package/{script → .dist/script}/config-command/synth.d.ts.map +0 -0
- /package/{script → .dist/script}/index.js +0 -0
- /package/{script → .dist/script}/index.js.map +0 -0
- /package/{script → .dist/script}/output-command/create-user.js +0 -0
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import { Duration } from 'aws-cdk-lib';
|
|
2
|
+
import { SqsEventSource } from 'aws-cdk-lib/aws-lambda-event-sources';
|
|
3
|
+
import { NodejsFunction } from 'aws-cdk-lib/aws-lambda-nodejs';
|
|
4
|
+
import { Construct } from 'constructs';
|
|
5
|
+
|
|
6
|
+
import { ServiceStack, getLogicalName, SynthError } from '../../../../common';
|
|
7
|
+
import { QueuePrefab, QueuePrefabParams } from '../../../integration';
|
|
8
|
+
import { BaseAggregateParams } from '../base-function';
|
|
9
|
+
import { BaseFunction, BaseHandlerParams, FUNCTION_DEFAULT_TIMEOUT } from '../base-function';
|
|
10
|
+
|
|
11
|
+
export type QueueHandlerParams = BaseHandlerParams & {
|
|
12
|
+
queuePrefab?: QueuePrefab;
|
|
13
|
+
queuePrefabParams?: Partial<QueuePrefabParams>;
|
|
14
|
+
maxConcurrency?: number;
|
|
15
|
+
batchSize?: number;
|
|
16
|
+
batchWindow?: Duration;
|
|
17
|
+
visibilityTimeoutRatio?: number;
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
export type QueueFunctionParams = BaseAggregateParams;
|
|
21
|
+
|
|
22
|
+
export class QueueFunction extends Construct {
|
|
23
|
+
public readonly lambdaFunction: NodejsFunction;
|
|
24
|
+
public readonly queuePrefab: QueuePrefab;
|
|
25
|
+
|
|
26
|
+
constructor(service: ServiceStack, params: QueueFunctionParams & QueueHandlerParams) {
|
|
27
|
+
super(service, getLogicalName(QueueFunction.name, params.name));
|
|
28
|
+
|
|
29
|
+
if (params.visibilityTimeoutRatio && params.visibilityTimeoutRatio < 1) {
|
|
30
|
+
throw new SynthError('Visibility timeout ratio must be greater than or equal to 1', service.props);
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
// Visibility timeout is declared, must be greater than or equal to the timeout
|
|
34
|
+
if (
|
|
35
|
+
params.queuePrefabParams?.visibilityTimeout &&
|
|
36
|
+
(params.timeout?.toSeconds() || FUNCTION_DEFAULT_TIMEOUT) > params.queuePrefabParams?.visibilityTimeout.toSeconds()
|
|
37
|
+
) {
|
|
38
|
+
throw new SynthError('Visibility timeout must be greater than or equal to the function timeout', service.props);
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
this.queuePrefab =
|
|
42
|
+
params.queuePrefab ||
|
|
43
|
+
new QueuePrefab(service, {
|
|
44
|
+
name: params.name,
|
|
45
|
+
visibilityTimeout: Duration.seconds((params.timeout?.toSeconds() || 6) * (params.visibilityTimeoutRatio || 2)),
|
|
46
|
+
...params.queuePrefabParams,
|
|
47
|
+
});
|
|
48
|
+
|
|
49
|
+
this.lambdaFunction = new BaseFunction(service, {
|
|
50
|
+
...params,
|
|
51
|
+
environment: { ...params.environment, CC_FUNCTION_TYPE: 'QUEUE' },
|
|
52
|
+
}).lambdaFunction;
|
|
53
|
+
|
|
54
|
+
this.lambdaFunction.addEventSource(
|
|
55
|
+
new SqsEventSource(this.queuePrefab.queue, {
|
|
56
|
+
...(params.maxConcurrency ? { maxConcurrency: params.maxConcurrency } : {}),
|
|
57
|
+
batchSize: params.batchSize || 10,
|
|
58
|
+
maxBatchingWindow: params.batchWindow,
|
|
59
|
+
reportBatchItemFailures: true,
|
|
60
|
+
})
|
|
61
|
+
);
|
|
62
|
+
|
|
63
|
+
// In case the lambda function needs to operate on the queue manually
|
|
64
|
+
this.lambdaFunction.addEnvironment('ORIGIN_QUEUE', this.queuePrefab.queue.queueUrl);
|
|
65
|
+
this.queuePrefab.queue.grantConsumeMessages(this.lambdaFunction);
|
|
66
|
+
}
|
|
67
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { Duration } from 'aws-cdk-lib';
|
|
2
|
+
import { SnsEventSource } from 'aws-cdk-lib/aws-lambda-event-sources';
|
|
3
|
+
import { NodejsFunction } from 'aws-cdk-lib/aws-lambda-nodejs';
|
|
4
|
+
import { Construct } from 'constructs';
|
|
5
|
+
|
|
6
|
+
import { ServiceStack, getLogicalName } from '../../../../common';
|
|
7
|
+
import { CustomTopicParams, TopicPrefab } from '../../../integration';
|
|
8
|
+
import { BaseAggregateParams } from '../base-function';
|
|
9
|
+
import { BaseHandlerParams, BaseFunction } from '../base-function';
|
|
10
|
+
|
|
11
|
+
export type TopicHandlerParams = BaseHandlerParams & {
|
|
12
|
+
topic?: TopicPrefab;
|
|
13
|
+
customTopicParams?: CustomTopicParams;
|
|
14
|
+
batchSize?: number;
|
|
15
|
+
batchWindow?: Duration;
|
|
16
|
+
};
|
|
17
|
+
|
|
18
|
+
export type TopicFunctionParams = BaseAggregateParams;
|
|
19
|
+
|
|
20
|
+
export class TopicFunction extends Construct {
|
|
21
|
+
public readonly lambdaFunction: NodejsFunction;
|
|
22
|
+
public readonly customTopic: TopicPrefab;
|
|
23
|
+
|
|
24
|
+
constructor(service: ServiceStack, params: TopicFunctionParams & TopicHandlerParams) {
|
|
25
|
+
super(service, getLogicalName(TopicFunction.name, params.name));
|
|
26
|
+
|
|
27
|
+
this.customTopic = params.topic || new TopicPrefab(service, { name: params.name, ...params.customTopicParams });
|
|
28
|
+
|
|
29
|
+
this.lambdaFunction = new BaseFunction(service, {
|
|
30
|
+
...params,
|
|
31
|
+
environment: { ...params.environment, CC_FUNCTION_TYPE: 'TOPIC' },
|
|
32
|
+
}).lambdaFunction;
|
|
33
|
+
|
|
34
|
+
this.lambdaFunction.addEventSource(new SnsEventSource(this.customTopic.topic));
|
|
35
|
+
}
|
|
36
|
+
}
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
import { RemovalPolicy } from 'aws-cdk-lib';
|
|
2
|
+
import { AttributeType, BillingMode, Table } from 'aws-cdk-lib/aws-dynamodb';
|
|
3
|
+
import { NodejsFunction } from 'aws-cdk-lib/aws-lambda-nodejs';
|
|
4
|
+
import { Construct } from 'constructs';
|
|
5
|
+
|
|
6
|
+
import { TableStoreBuilder, TablePermission } from '@takumi-stack/sdk';
|
|
7
|
+
|
|
8
|
+
import { ServiceStack, SynthError, getLogicalName, getResourceName } from '../../../common';
|
|
9
|
+
|
|
10
|
+
export class DynamoTablePrefab extends Construct {
|
|
11
|
+
public readonly table: Table;
|
|
12
|
+
public readonly tableName: string;
|
|
13
|
+
public readonly dynamoTableNameEnvVar: string;
|
|
14
|
+
|
|
15
|
+
constructor(service: ServiceStack, params: typeof TableStoreBuilder<any>) {
|
|
16
|
+
super(service, getLogicalName(DynamoTablePrefab.name, new params().tableName));
|
|
17
|
+
|
|
18
|
+
const definition = new params();
|
|
19
|
+
if (!definition.tableName)
|
|
20
|
+
throw new SynthError('Bad implementation of TableStoreBuilder (remember use implements instead of extends in you class)', service.props);
|
|
21
|
+
|
|
22
|
+
this.dynamoTableNameEnvVar = definition.dynamoTableNameEnvVar || parseTableName(definition.tableName);
|
|
23
|
+
this.tableName = definition.tableName;
|
|
24
|
+
|
|
25
|
+
if (definition.keyMapping.PK !== 'PK') {
|
|
26
|
+
throw new SynthError('Bad implementation of TableStoreBuilder (PK must be PK)', service.props);
|
|
27
|
+
}
|
|
28
|
+
if (definition.keyMapping.SK && definition.keyMapping.SK !== 'SK') {
|
|
29
|
+
throw new SynthError('Bad implementation of TableStoreBuilder (SK must be SK)', service.props);
|
|
30
|
+
}
|
|
31
|
+
this.table = new Table(this, definition.tableName, {
|
|
32
|
+
tableName: getResourceName(definition.tableName, service.props),
|
|
33
|
+
billingMode: BillingMode.PAY_PER_REQUEST,
|
|
34
|
+
partitionKey: { name: 'PK', type: AttributeType.STRING },
|
|
35
|
+
timeToLiveAttribute: 'deleteTTL',
|
|
36
|
+
...(definition.keyMapping.SK ? { sortKey: { name: 'SK', type: AttributeType.STRING } } : {}),
|
|
37
|
+
// stream: params.stream,
|
|
38
|
+
});
|
|
39
|
+
|
|
40
|
+
const indexes = { ...definition.attIndexes, ...definition.genericIndexes };
|
|
41
|
+
if (indexes) {
|
|
42
|
+
const indexKeys = Object.keys(indexes);
|
|
43
|
+
indexKeys.forEach((indexKey) => {
|
|
44
|
+
const index = indexes[indexKey];
|
|
45
|
+
if (index) {
|
|
46
|
+
this.table.addGlobalSecondaryIndex({
|
|
47
|
+
indexName: indexKey,
|
|
48
|
+
partitionKey: { name: index.PK, type: AttributeType.STRING },
|
|
49
|
+
...(index.SK ? { sortKey: { name: index.SK, type: AttributeType.STRING } } : {}),
|
|
50
|
+
});
|
|
51
|
+
}
|
|
52
|
+
});
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
this.table.applyRemovalPolicy(RemovalPolicy.DESTROY);
|
|
56
|
+
if (service.props.envName === 'prod') this.table.applyRemovalPolicy(RemovalPolicy.RETAIN);
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
// public useMod(variableName = 'TABLE', mods: ((table: Table) => any)[]): Modifier {
|
|
60
|
+
// return (lambda: NodejsFunction): void => {
|
|
61
|
+
// lambda.addEnvironment(variableName, this.table.tableName);
|
|
62
|
+
// mods.map((fn) => fn(this.table)(lambda));
|
|
63
|
+
// };
|
|
64
|
+
// }
|
|
65
|
+
|
|
66
|
+
// public useModPermission(variableName = 'TABLE', tablePermission: TablePermission): Modifier {
|
|
67
|
+
// return (lambda: NodejsFunction): void => {
|
|
68
|
+
// lambda.addEnvironment(variableName, this.table.tableName);
|
|
69
|
+
// DynamoTablePrefab.modifier.permission(this.table, tablePermission)(lambda);
|
|
70
|
+
// };
|
|
71
|
+
// }
|
|
72
|
+
|
|
73
|
+
// public static modifier = {
|
|
74
|
+
// permission: (table: Table, tablePermission: TablePermission): ((lambda: NodejsFunction) => void) => {
|
|
75
|
+
// return (lambda: NodejsFunction): void => {
|
|
76
|
+
// if (tablePermission === 'none') return;
|
|
77
|
+
// const permissionMapper = {
|
|
78
|
+
// read: () => table.grantReadData(lambda),
|
|
79
|
+
// write: () => table.grantWriteData(lambda),
|
|
80
|
+
// readWrite: () => table.grantReadWriteData(lambda),
|
|
81
|
+
// };
|
|
82
|
+
// permissionMapper[tablePermission]();
|
|
83
|
+
// };
|
|
84
|
+
// },
|
|
85
|
+
// writer: (table: Table): ((lambda: NodejsFunction) => void) => {
|
|
86
|
+
// return (lambda: NodejsFunction): void => {
|
|
87
|
+
// table.grantWriteData(lambda);
|
|
88
|
+
// };
|
|
89
|
+
// },
|
|
90
|
+
// reader: (table: Table): ((lambda: NodejsFunction) => void) => {
|
|
91
|
+
// return (lambda: NodejsFunction): void => {
|
|
92
|
+
// table.grantReadData(lambda);
|
|
93
|
+
// };
|
|
94
|
+
// },
|
|
95
|
+
// };
|
|
96
|
+
|
|
97
|
+
public static addTable(lambdaFunction: NodejsFunction, tablePrefab?: DynamoTablePrefab, tablePermission?: TablePermission): void {
|
|
98
|
+
if (tablePrefab instanceof DynamoTablePrefab) {
|
|
99
|
+
if (!tablePermission) throw new Error('tablePermission is required when table is used');
|
|
100
|
+
lambdaFunction.addEnvironment(tablePrefab.dynamoTableNameEnvVar, tablePrefab.table.tableName);
|
|
101
|
+
if (tablePermission === 'none') return;
|
|
102
|
+
const permissionMapper = {
|
|
103
|
+
read: () => tablePrefab.table.grantReadData(lambdaFunction),
|
|
104
|
+
write: () => tablePrefab.table.grantWriteData(lambdaFunction),
|
|
105
|
+
readWrite: () => tablePrefab.table.grantReadWriteData(lambdaFunction),
|
|
106
|
+
};
|
|
107
|
+
permissionMapper[tablePermission]();
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
function parseTableName(tableName: any): string {
|
|
112
|
+
throw new Error('Function not implemented.');
|
|
113
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { RDSClient, StartDBClusterCommand } from '@aws-sdk/client-rds';
|
|
2
|
+
|
|
3
|
+
const client = new RDSClient({ region: process.env.REGION });
|
|
4
|
+
|
|
5
|
+
export const handler = async (): Promise<any> => {
|
|
6
|
+
await client.send(new StartDBClusterCommand({ DBClusterIdentifier: process.env.DB_CLUSTER_NAME! }));
|
|
7
|
+
};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { RDSClient, StopDBClusterCommand } from '@aws-sdk/client-rds';
|
|
2
|
+
|
|
3
|
+
const client = new RDSClient({ region: process.env.REGION });
|
|
4
|
+
|
|
5
|
+
export const handler = async (): Promise<any> => {
|
|
6
|
+
await client.send(new StopDBClusterCommand({ DBClusterIdentifier: process.env.DB_CLUSTER_NAME! }));
|
|
7
|
+
};
|
|
@@ -0,0 +1,248 @@
|
|
|
1
|
+
import * as awsEc2 from 'aws-cdk-lib/aws-ec2';
|
|
2
|
+
import * as awsRds from 'aws-cdk-lib/aws-rds';
|
|
3
|
+
import { Fn, RemovalPolicy } from 'aws-cdk-lib';
|
|
4
|
+
import { CronOptions } from 'aws-cdk-lib/aws-events';
|
|
5
|
+
import { ManagedPolicy, PolicyStatement, Role, ServicePrincipal } from 'aws-cdk-lib/aws-iam';
|
|
6
|
+
import { ISecret } from 'aws-cdk-lib/aws-secretsmanager';
|
|
7
|
+
import { StringParameter } from 'aws-cdk-lib/aws-ssm';
|
|
8
|
+
import { Construct } from 'constructs';
|
|
9
|
+
|
|
10
|
+
import { Modifier, ServiceStack, SynthError, getLogicalName, getResourceName, getShortResourceName } from '../../../common';
|
|
11
|
+
import { CronAggregate, BaseAggregateParams } from '../../compute';
|
|
12
|
+
import { VpcPrefab } from '../../networking';
|
|
13
|
+
|
|
14
|
+
export type AuroraPerformanceTuning = {
|
|
15
|
+
writeInstanceProps?: awsRds.ServerlessV2ClusterInstanceProps;
|
|
16
|
+
readInstanceProps?: awsRds.ServerlessV2ClusterInstanceProps;
|
|
17
|
+
readInstances?: number;
|
|
18
|
+
readers?: awsRds.IClusterInstance[];
|
|
19
|
+
minCapacity?: number;
|
|
20
|
+
maxCapacity?: number;
|
|
21
|
+
};
|
|
22
|
+
|
|
23
|
+
export type AuroraServerlessV2PrefabParams = {
|
|
24
|
+
clusterName: string;
|
|
25
|
+
vpcPrefab: VpcPrefab;
|
|
26
|
+
performanceTuning: AuroraPerformanceTuning;
|
|
27
|
+
port?: number;
|
|
28
|
+
engine?: awsRds.IClusterEngine;
|
|
29
|
+
publicAccess: boolean;
|
|
30
|
+
baseDir?: string;
|
|
31
|
+
scheduledPause?: {
|
|
32
|
+
startCron: CronOptions;
|
|
33
|
+
stopCron: CronOptions;
|
|
34
|
+
};
|
|
35
|
+
vpcSubnets?: awsEc2.SubnetSelection;
|
|
36
|
+
securityGroupProps?: Partial<awsEc2.SecurityGroupProps>;
|
|
37
|
+
databaseClusterProps?: Partial<awsRds.DatabaseClusterProps>;
|
|
38
|
+
databaseProxyProps?: Partial<awsRds.DatabaseProxyProps>;
|
|
39
|
+
};
|
|
40
|
+
|
|
41
|
+
export class RdsClusterPrefab extends Construct {
|
|
42
|
+
public readonly cluster: awsRds.DatabaseCluster;
|
|
43
|
+
public readonly securityGroupForLambda: awsEc2.SecurityGroup;
|
|
44
|
+
public readonly securityGroup: awsEc2.SecurityGroup;
|
|
45
|
+
public readonly securityGroupBastion!: awsEc2.SecurityGroup;
|
|
46
|
+
public readonly roleBastion!: Role;
|
|
47
|
+
public readonly ec2Bastion!: awsEc2.Instance;
|
|
48
|
+
public readonly vpcSubnets?: awsEc2.SubnetSelection;
|
|
49
|
+
public readonly proxy: awsRds.DatabaseProxy;
|
|
50
|
+
public readonly secret: ISecret;
|
|
51
|
+
public readonly cronAggregate!: CronAggregate;
|
|
52
|
+
public readonly readonlyRdsProxyEndpoint!: awsRds.CfnDBProxyEndpoint;
|
|
53
|
+
|
|
54
|
+
constructor(service: ServiceStack, params: AuroraServerlessV2PrefabParams) {
|
|
55
|
+
super(service, getLogicalName(RdsClusterPrefab.name, params.clusterName));
|
|
56
|
+
|
|
57
|
+
if (!params.publicAccess) {
|
|
58
|
+
// Create SG for EC2 Bastion
|
|
59
|
+
this.securityGroupBastion = new awsEc2.SecurityGroup(this, 'BastionSecurityGroup', {
|
|
60
|
+
securityGroupName: getResourceName('ec2Bastion', service.props),
|
|
61
|
+
vpc: params.vpcPrefab.vpc,
|
|
62
|
+
allowAllOutbound: false,
|
|
63
|
+
});
|
|
64
|
+
this.securityGroupBastion.addEgressRule(awsEc2.Peer.anyIpv4(), awsEc2.Port.tcp(params.port || 5432), 'RdsBastionPort');
|
|
65
|
+
this.securityGroupBastion.addEgressRule(awsEc2.Peer.anyIpv4(), awsEc2.Port.tcp(params.port || 443), 'HttpsBastionPort');
|
|
66
|
+
|
|
67
|
+
// Create Role for EC2 to allow use SSMManagedInstance
|
|
68
|
+
this.roleBastion = new Role(this, getLogicalName('role', 'ec2Bastion'), {
|
|
69
|
+
assumedBy: new ServicePrincipal('ec2.amazonaws.com'),
|
|
70
|
+
roleName: getShortResourceName('ec2BastionSSM', service.props),
|
|
71
|
+
});
|
|
72
|
+
this.roleBastion.addManagedPolicy(ManagedPolicy.fromAwsManagedPolicyName('AmazonSSMManagedInstanceCore'));
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
this.securityGroupForLambda = new awsEc2.SecurityGroup(this, 'LambdaSecurityGroup', {
|
|
76
|
+
securityGroupName: getResourceName(`LambdaToCluster${params.clusterName}`, service.props),
|
|
77
|
+
vpc: params.vpcPrefab.vpc,
|
|
78
|
+
allowAllOutbound: true,
|
|
79
|
+
});
|
|
80
|
+
|
|
81
|
+
this.securityGroup = new awsEc2.SecurityGroup(this, 'ClusterSecurityGroup', {
|
|
82
|
+
securityGroupName: getResourceName(params.clusterName, service.props),
|
|
83
|
+
vpc: params.vpcPrefab.vpc,
|
|
84
|
+
allowAllOutbound: true,
|
|
85
|
+
...params.securityGroupProps,
|
|
86
|
+
});
|
|
87
|
+
this.securityGroup.addIngressRule(awsEc2.Peer.anyIpv4(), awsEc2.Port.tcp(params.port || 5432), 'DefaultClusterPort');
|
|
88
|
+
// Allow SG EC2 in Inbound Rules SG RDS
|
|
89
|
+
if (!params.publicAccess)
|
|
90
|
+
this.securityGroup.connections.allowFrom(this.securityGroupBastion, awsEc2.Port.tcp(params.port || 5432), 'BastionInboundRule');
|
|
91
|
+
|
|
92
|
+
this.cluster = new awsRds.DatabaseCluster(this, 'Cluster', {
|
|
93
|
+
port: params.port || 5432, // Default port for postgres
|
|
94
|
+
clusterIdentifier: getResourceName(params.clusterName, service.props),
|
|
95
|
+
vpc: params.vpcPrefab.vpc,
|
|
96
|
+
...(params.vpcSubnets || params.publicAccess ? { vpcSubnets: { subnetType: awsEc2.SubnetType.PUBLIC } } : {}),
|
|
97
|
+
securityGroups: [this.securityGroup],
|
|
98
|
+
engine:
|
|
99
|
+
params.engine ||
|
|
100
|
+
awsRds.DatabaseClusterEngine.auroraPostgres({
|
|
101
|
+
version: awsRds.AuroraPostgresEngineVersion.VER_15_2,
|
|
102
|
+
}),
|
|
103
|
+
credentials: awsRds.Credentials.fromGeneratedSecret('postgres', {
|
|
104
|
+
secretName: getResourceName(params.clusterName, service.props),
|
|
105
|
+
}),
|
|
106
|
+
writer: awsRds.ClusterInstance.serverlessV2('writer', {
|
|
107
|
+
instanceIdentifier: getResourceName('writer-master', service.props),
|
|
108
|
+
publiclyAccessible: params.publicAccess,
|
|
109
|
+
caCertificate: awsRds.CaCertificate.RDS_CA_RDS2048_G1,
|
|
110
|
+
...params.performanceTuning.writeInstanceProps,
|
|
111
|
+
}),
|
|
112
|
+
readers:
|
|
113
|
+
params.performanceTuning.readers ||
|
|
114
|
+
[...Array(params.performanceTuning.readInstances).keys()].map((i) =>
|
|
115
|
+
awsRds.ClusterInstance.serverlessV2(`reader-${i}`, {
|
|
116
|
+
instanceIdentifier: getResourceName(`reader-${i}`, service.props),
|
|
117
|
+
publiclyAccessible: params.publicAccess,
|
|
118
|
+
caCertificate: awsRds.CaCertificate.RDS_CA_RDS2048_G1,
|
|
119
|
+
...params.performanceTuning.readInstanceProps,
|
|
120
|
+
...(params.performanceTuning.readInstanceProps?.scaleWithWriter === undefined
|
|
121
|
+
? { scaleWithWriter: true }
|
|
122
|
+
: { scaleWithWriter: params.performanceTuning.readInstanceProps?.scaleWithWriter }),
|
|
123
|
+
})
|
|
124
|
+
),
|
|
125
|
+
serverlessV2MinCapacity: params.performanceTuning.minCapacity,
|
|
126
|
+
serverlessV2MaxCapacity: params.performanceTuning.maxCapacity,
|
|
127
|
+
...params.databaseClusterProps,
|
|
128
|
+
});
|
|
129
|
+
if (!params.publicAccess) {
|
|
130
|
+
// Create EC2 Instance
|
|
131
|
+
this.ec2Bastion = new awsEc2.Instance(this, 'EC2BastionInstance', {
|
|
132
|
+
vpc: params.vpcPrefab.vpc,
|
|
133
|
+
vpcSubnets: this.cluster.vpcSubnets,
|
|
134
|
+
role: this.roleBastion,
|
|
135
|
+
securityGroup: this.securityGroupBastion,
|
|
136
|
+
instanceType: awsEc2.InstanceType.of(awsEc2.InstanceClass.T2, awsEc2.InstanceSize.MICRO),
|
|
137
|
+
machineImage: new awsEc2.AmazonLinuxImage({
|
|
138
|
+
generation: awsEc2.AmazonLinuxGeneration.AMAZON_LINUX_2,
|
|
139
|
+
}),
|
|
140
|
+
});
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
this.vpcSubnets = this.cluster.vpcSubnets;
|
|
144
|
+
|
|
145
|
+
// RDS Proxy
|
|
146
|
+
const rdsRole = new Role(this, 'ProxyRole', {
|
|
147
|
+
roleName: getResourceName('proxy', service.props),
|
|
148
|
+
assumedBy: new ServicePrincipal('rds.amazonaws.com'),
|
|
149
|
+
});
|
|
150
|
+
this.proxy = new awsRds.DatabaseProxy(this, 'Proxy', {
|
|
151
|
+
dbProxyName: getResourceName('proxy', service.props),
|
|
152
|
+
proxyTarget: awsRds.ProxyTarget.fromCluster(this.cluster),
|
|
153
|
+
secrets: [this.cluster.secret!],
|
|
154
|
+
iamAuth: true,
|
|
155
|
+
vpc: params.vpcPrefab.vpc,
|
|
156
|
+
securityGroups: [this.securityGroup],
|
|
157
|
+
role: rdsRole,
|
|
158
|
+
...params.databaseProxyProps,
|
|
159
|
+
});
|
|
160
|
+
|
|
161
|
+
// Read-only endpoint
|
|
162
|
+
if ((params.performanceTuning?.readInstances || params.performanceTuning?.readers?.length || 0) > 0) {
|
|
163
|
+
this.readonlyRdsProxyEndpoint = new awsRds.CfnDBProxyEndpoint(this, 'ReadReplicaEndpoint', {
|
|
164
|
+
dbProxyName: this.proxy.dbProxyName,
|
|
165
|
+
dbProxyEndpointName: this.proxy.dbProxyName + '-read-replica',
|
|
166
|
+
vpcSubnetIds: params.vpcPrefab.vpc.selectSubnets(this.cluster.vpcSubnets).subnetIds,
|
|
167
|
+
vpcSecurityGroupIds: [this.securityGroup.securityGroupId],
|
|
168
|
+
targetRole: 'READ_ONLY',
|
|
169
|
+
});
|
|
170
|
+
this.readonlyRdsProxyEndpoint.node.addDependency(this.proxy);
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
// Command Execution Parameter
|
|
174
|
+
this.secret = this.cluster.secret!;
|
|
175
|
+
new StringParameter(this, 'Config', {
|
|
176
|
+
simpleName: true,
|
|
177
|
+
parameterName: getResourceName('config', service.props),
|
|
178
|
+
stringValue: JSON.stringify({
|
|
179
|
+
baseDir: params.baseDir || `support/${service.props.serviceName}`.toLowerCase(),
|
|
180
|
+
clusterSecretArn: this.cluster.secret?.secretArn,
|
|
181
|
+
publicAccess: params.publicAccess,
|
|
182
|
+
...(!params.publicAccess ? { ec2InstanceId: this.ec2Bastion.instanceId } : {}),
|
|
183
|
+
}),
|
|
184
|
+
});
|
|
185
|
+
|
|
186
|
+
this.cluster.applyRemovalPolicy(RemovalPolicy.DESTROY);
|
|
187
|
+
if (service.props.envName === 'prod') this.cluster.applyRemovalPolicy(RemovalPolicy.RETAIN);
|
|
188
|
+
|
|
189
|
+
// Scheduled Pause
|
|
190
|
+
if (params.scheduledPause) {
|
|
191
|
+
this.cronAggregate = new CronAggregate(service, {
|
|
192
|
+
baseFunctionFolder: __dirname,
|
|
193
|
+
...(service.props.isDemoProject ? {} : { compiled: true }),
|
|
194
|
+
handlers: {
|
|
195
|
+
start: {
|
|
196
|
+
name: 'start-cluster',
|
|
197
|
+
cronOptions: params.scheduledPause.startCron,
|
|
198
|
+
environment: { DB_CLUSTER_NAME: this.cluster.clusterIdentifier },
|
|
199
|
+
},
|
|
200
|
+
stop: {
|
|
201
|
+
name: 'stop-cluster',
|
|
202
|
+
cronOptions: params.scheduledPause.stopCron,
|
|
203
|
+
environment: { DB_CLUSTER_NAME: this.cluster.clusterIdentifier },
|
|
204
|
+
},
|
|
205
|
+
},
|
|
206
|
+
});
|
|
207
|
+
if (this.cronAggregate.handlers?.start?.role) {
|
|
208
|
+
this.cronAggregate.handlers.start.role.addToPrincipalPolicy(
|
|
209
|
+
new PolicyStatement({
|
|
210
|
+
actions: ['rds:StartDBCluster'],
|
|
211
|
+
resources: [Fn.join('', [`arn:aws:rds:${service.props.regionName}:${service.account}:cluster:`, this.cluster.clusterIdentifier])],
|
|
212
|
+
})
|
|
213
|
+
);
|
|
214
|
+
}
|
|
215
|
+
if (this.cronAggregate.handlers.stop?.role) {
|
|
216
|
+
this.cronAggregate.handlers.stop.role.addToPrincipalPolicy(
|
|
217
|
+
new PolicyStatement({
|
|
218
|
+
actions: ['rds:StopDBCluster'],
|
|
219
|
+
resources: [Fn.join('', [`arn:aws:rds:${service.props.regionName}:${service.account}:cluster:`, this.cluster.clusterIdentifier])],
|
|
220
|
+
})
|
|
221
|
+
);
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
public useClusterVpcGlobalConfigs(): BaseAggregateParams['globalConfigs'] {
|
|
227
|
+
return {
|
|
228
|
+
vpc: this.cluster.vpc,
|
|
229
|
+
securityGroups: [this.securityGroupForLambda],
|
|
230
|
+
};
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
public useModAccess(access: 'readWrite' | 'readOnly' = 'readWrite', variableName = 'DB'): Modifier {
|
|
234
|
+
return (lambda) => {
|
|
235
|
+
if (!lambda.isBoundToVpc) {
|
|
236
|
+
throw new SynthError('Your lambda must run in the same VPC you passed to this RDSClusterPrefab');
|
|
237
|
+
}
|
|
238
|
+
this.proxy.grantConnect(lambda);
|
|
239
|
+
this.secret.grantRead(lambda);
|
|
240
|
+
|
|
241
|
+
if (access === 'readOnly' && this.readonlyRdsProxyEndpoint) {
|
|
242
|
+
lambda.addEnvironment(variableName, this.readonlyRdsProxyEndpoint.attrEndpoint);
|
|
243
|
+
} else {
|
|
244
|
+
lambda.addEnvironment(variableName, this.proxy.endpoint);
|
|
245
|
+
}
|
|
246
|
+
};
|
|
247
|
+
}
|
|
248
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { RemovalPolicy } from 'aws-cdk-lib';
|
|
2
|
+
import { CfnDatabase } from 'aws-cdk-lib/aws-timestream';
|
|
3
|
+
import { Construct } from 'constructs';
|
|
4
|
+
|
|
5
|
+
import { ServiceStack, getLogicalName, getResourceName } from '../../../common';
|
|
6
|
+
|
|
7
|
+
export type TimeStreamDBParams = {
|
|
8
|
+
databaseName: string;
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export class TimestreamDatabasePrefab extends Construct {
|
|
12
|
+
public readonly database: CfnDatabase;
|
|
13
|
+
|
|
14
|
+
constructor(service: ServiceStack, params: TimeStreamDBParams) {
|
|
15
|
+
super(service, getLogicalName(TimestreamDatabasePrefab.name, params.databaseName));
|
|
16
|
+
|
|
17
|
+
this.database = new CfnDatabase(this, 'Database', {
|
|
18
|
+
databaseName: getResourceName(params.databaseName, service.props),
|
|
19
|
+
});
|
|
20
|
+
|
|
21
|
+
this.database.applyRemovalPolicy(RemovalPolicy.DESTROY);
|
|
22
|
+
if (service.props.envName === 'prod') this.database.applyRemovalPolicy(RemovalPolicy.RETAIN);
|
|
23
|
+
}
|
|
24
|
+
}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import { RemovalPolicy } from 'aws-cdk-lib';
|
|
2
|
+
import { Effect, PolicyStatement } from 'aws-cdk-lib/aws-iam';
|
|
3
|
+
import { NodejsFunction } from 'aws-cdk-lib/aws-lambda-nodejs';
|
|
4
|
+
import { CfnDatabase, CfnTable } from 'aws-cdk-lib/aws-timestream';
|
|
5
|
+
import { Construct } from 'constructs';
|
|
6
|
+
|
|
7
|
+
import { ServiceStack, getLogicalName, getResourceName } from '../../../common';
|
|
8
|
+
|
|
9
|
+
export type TimestreamTableParams = {
|
|
10
|
+
tableName: string;
|
|
11
|
+
database: CfnDatabase;
|
|
12
|
+
memoryHoursRetention?: string;
|
|
13
|
+
diskDaysRetention?: string;
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
export class TimestreamTablePrefab extends Construct {
|
|
17
|
+
public readonly table: CfnTable;
|
|
18
|
+
public readonly database: CfnDatabase;
|
|
19
|
+
|
|
20
|
+
constructor(service: ServiceStack, params: TimestreamTableParams) {
|
|
21
|
+
super(service, getLogicalName(TimestreamTablePrefab.name, params.tableName));
|
|
22
|
+
|
|
23
|
+
this.database = params.database;
|
|
24
|
+
|
|
25
|
+
this.table = new CfnTable(this, getLogicalName('TimestreamTable', params.tableName), {
|
|
26
|
+
tableName: getResourceName(params.tableName, service.props),
|
|
27
|
+
databaseName: params.database.databaseName!,
|
|
28
|
+
magneticStoreWriteProperties: {
|
|
29
|
+
enableMagneticStoreWrites: true,
|
|
30
|
+
},
|
|
31
|
+
retentionProperties: {
|
|
32
|
+
MemoryStoreRetentionPeriodInHours: params.memoryHoursRetention || '24',
|
|
33
|
+
MagneticStoreRetentionPeriodInDays: params.diskDaysRetention || '365',
|
|
34
|
+
},
|
|
35
|
+
});
|
|
36
|
+
|
|
37
|
+
this.table.addDependency(this.database);
|
|
38
|
+
this.table.applyRemovalPolicy(RemovalPolicy.DESTROY);
|
|
39
|
+
if (service.props.envName === 'prod') this.table.applyRemovalPolicy(RemovalPolicy.RETAIN);
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
public useMod(mods: ((table: CfnTable) => any)[]): (lambda: NodejsFunction) => void {
|
|
43
|
+
return (lambda: NodejsFunction): void => {
|
|
44
|
+
lambda.addEnvironment('TIMESTREAM_TABLE', this.table.tableName!);
|
|
45
|
+
lambda.addEnvironment('TIMESTREAM_DB', this.database.databaseName!);
|
|
46
|
+
mods.map((fn) => fn(this.table)(lambda));
|
|
47
|
+
};
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
public static modifier = {
|
|
51
|
+
writer: (table: CfnTable): ((lambda: NodejsFunction) => void) => {
|
|
52
|
+
return (lambda: NodejsFunction): void => {
|
|
53
|
+
lambda.addToRolePolicy(
|
|
54
|
+
new PolicyStatement({
|
|
55
|
+
effect: Effect.ALLOW,
|
|
56
|
+
actions: ['timestream:WriteRecords'],
|
|
57
|
+
resources: [table.attrArn],
|
|
58
|
+
})
|
|
59
|
+
);
|
|
60
|
+
lambda.addToRolePolicy(new PolicyStatement({ effect: Effect.ALLOW, actions: ['timestream:DescribeEndpoints'], resources: ['*'] }));
|
|
61
|
+
};
|
|
62
|
+
},
|
|
63
|
+
reader: (table: CfnTable): ((lambda: NodejsFunction) => void) => {
|
|
64
|
+
return (lambda: NodejsFunction): void => {
|
|
65
|
+
lambda.addToRolePolicy(
|
|
66
|
+
new PolicyStatement({
|
|
67
|
+
effect: Effect.ALLOW,
|
|
68
|
+
actions: ['timestream:Select', 'timestream:SelectValues'],
|
|
69
|
+
resources: [table.attrArn],
|
|
70
|
+
})
|
|
71
|
+
);
|
|
72
|
+
lambda.addToRolePolicy(new PolicyStatement({ effect: Effect.ALLOW, actions: ['timestream:DescribeEndpoints'], resources: ['*'] }));
|
|
73
|
+
};
|
|
74
|
+
},
|
|
75
|
+
};
|
|
76
|
+
}
|