cdk-factory 0.15.10__py3-none-any.whl → 0.18.9__py3-none-any.whl

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.

Potentially problematic release.


This version of cdk-factory might be problematic. Click here for more details.

Files changed (63) hide show
  1. cdk_factory/configurations/base_config.py +23 -24
  2. cdk_factory/configurations/cdk_config.py +6 -4
  3. cdk_factory/configurations/deployment.py +12 -0
  4. cdk_factory/configurations/devops.py +1 -1
  5. cdk_factory/configurations/pipeline_stage.py +29 -5
  6. cdk_factory/configurations/resources/acm.py +85 -0
  7. cdk_factory/configurations/resources/auto_scaling.py +7 -5
  8. cdk_factory/configurations/resources/cloudfront.py +7 -2
  9. cdk_factory/configurations/resources/ecr.py +1 -1
  10. cdk_factory/configurations/resources/ecs_cluster.py +108 -0
  11. cdk_factory/configurations/resources/ecs_service.py +17 -2
  12. cdk_factory/configurations/resources/load_balancer.py +17 -4
  13. cdk_factory/configurations/resources/monitoring.py +8 -3
  14. cdk_factory/configurations/resources/rds.py +305 -19
  15. cdk_factory/configurations/resources/rum.py +7 -2
  16. cdk_factory/configurations/resources/s3.py +1 -1
  17. cdk_factory/configurations/resources/security_group_full_stack.py +7 -8
  18. cdk_factory/configurations/resources/vpc.py +19 -0
  19. cdk_factory/configurations/workload.py +32 -2
  20. cdk_factory/constructs/ecr/ecr_construct.py +9 -2
  21. cdk_factory/constructs/lambdas/policies/policy_docs.py +4 -4
  22. cdk_factory/interfaces/istack.py +6 -3
  23. cdk_factory/interfaces/networked_stack_mixin.py +75 -0
  24. cdk_factory/interfaces/standardized_ssm_mixin.py +657 -0
  25. cdk_factory/interfaces/vpc_provider_mixin.py +210 -0
  26. cdk_factory/lambdas/edge/ip_gate/handler.py +42 -40
  27. cdk_factory/pipeline/pipeline_factory.py +222 -27
  28. cdk_factory/stack/stack_factory.py +34 -0
  29. cdk_factory/stack_library/__init__.py +3 -2
  30. cdk_factory/stack_library/acm/__init__.py +6 -0
  31. cdk_factory/stack_library/acm/acm_stack.py +169 -0
  32. cdk_factory/stack_library/api_gateway/api_gateway_stack.py +84 -59
  33. cdk_factory/stack_library/auto_scaling/auto_scaling_stack.py +366 -408
  34. cdk_factory/stack_library/code_artifact/code_artifact_stack.py +2 -2
  35. cdk_factory/stack_library/cognito/cognito_stack.py +152 -92
  36. cdk_factory/stack_library/dynamodb/dynamodb_stack.py +19 -15
  37. cdk_factory/stack_library/ecr/ecr_stack.py +2 -2
  38. cdk_factory/stack_library/ecs/__init__.py +12 -0
  39. cdk_factory/stack_library/ecs/ecs_cluster_stack.py +316 -0
  40. cdk_factory/stack_library/ecs/ecs_service_stack.py +20 -39
  41. cdk_factory/stack_library/lambda_edge/lambda_edge_stack.py +2 -2
  42. cdk_factory/stack_library/load_balancer/load_balancer_stack.py +151 -118
  43. cdk_factory/stack_library/rds/rds_stack.py +85 -74
  44. cdk_factory/stack_library/route53/route53_stack.py +8 -3
  45. cdk_factory/stack_library/rum/rum_stack.py +108 -91
  46. cdk_factory/stack_library/security_group/security_group_full_stack.py +9 -22
  47. cdk_factory/stack_library/security_group/security_group_stack.py +11 -11
  48. cdk_factory/stack_library/stack_base.py +5 -0
  49. cdk_factory/stack_library/vpc/vpc_stack.py +272 -124
  50. cdk_factory/stack_library/websites/static_website_stack.py +1 -1
  51. cdk_factory/utilities/api_gateway_integration_utility.py +24 -16
  52. cdk_factory/utilities/environment_services.py +5 -5
  53. cdk_factory/utilities/json_loading_utility.py +12 -3
  54. cdk_factory/validation/config_validator.py +483 -0
  55. cdk_factory/version.py +1 -1
  56. cdk_factory/workload/workload_factory.py +1 -0
  57. {cdk_factory-0.15.10.dist-info → cdk_factory-0.18.9.dist-info}/METADATA +1 -1
  58. {cdk_factory-0.15.10.dist-info → cdk_factory-0.18.9.dist-info}/RECORD +61 -54
  59. cdk_factory/interfaces/enhanced_ssm_parameter_mixin.py +0 -321
  60. cdk_factory/interfaces/ssm_parameter_mixin.py +0 -329
  61. {cdk_factory-0.15.10.dist-info → cdk_factory-0.18.9.dist-info}/WHEEL +0 -0
  62. {cdk_factory-0.15.10.dist-info → cdk_factory-0.18.9.dist-info}/entry_points.txt +0 -0
  63. {cdk_factory-0.15.10.dist-info → cdk_factory-0.18.9.dist-info}/licenses/LICENSE +0 -0
@@ -2,26 +2,27 @@ cdk_factory/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
2
  cdk_factory/app.py,sha256=RnX0-pwdTAPAdKJK_j13Zl8anf9zYKBwboR0KA8K8xM,10346
3
3
  cdk_factory/cdk.json,sha256=SKZKhJ2PBpFH78j-F8S3VDYW-lf76--Q2I3ON-ZIQfw,3106
4
4
  cdk_factory/cli.py,sha256=FGbCTS5dYCNsfp-etshzvFlGDCjC28r6rtzYbe7KoHI,6407
5
- cdk_factory/version.py,sha256=bVjzjoCZ4i8ekwD6vYFTiHHb51wVUtF_jW4KJEuwrAk,24
5
+ cdk_factory/version.py,sha256=IVIKMh_0rk9joVhw8HHbpQn8gqEpjdsiBt0jOCyi8os,23
6
6
  cdk_factory/builds/README.md,sha256=9BBWd7bXpyKdMU_g2UljhQwrC9i5O_Tvkb6oPvndoZk,90
7
7
  cdk_factory/commands/command_loader.py,sha256=QbLquuP_AdxtlxlDy-2IWCQ6D-7qa58aphnDPtp_uTs,3744
8
- cdk_factory/configurations/base_config.py,sha256=JKjhNsy0RCUZy1s8n5D_aXXI-upR9izaLtCTfKYiV9k,9624
9
- cdk_factory/configurations/cdk_config.py,sha256=eYboaXcz9CUx4rJbEagX8ppgtIERUlopcJXii7Vn8Ws,8796
10
- cdk_factory/configurations/deployment.py,sha256=LO2gd1yv1nqlX_2MIjRXptylFybWiTKsMKZU0N58rSM,12110
8
+ cdk_factory/configurations/base_config.py,sha256=eJ3Pl3GWk1jVr_bYQaaWlw4_-ZiFGaiXllI_fOOX1i0,9323
9
+ cdk_factory/configurations/cdk_config.py,sha256=-XOG2MSeMahZbUjWrARAkgU7tqbWsYcnV6a8bt063WM,8913
10
+ cdk_factory/configurations/deployment.py,sha256=iQwmccdQGw66wRl-CjHfNPpQ_OyqNCMl3G2V7FUYnGE,12684
11
11
  cdk_factory/configurations/deployment_wave.py,sha256=TFX7CYgr5SmLyziEb-R_OTteFWtlMHB4pT53ekV3d1Y,233
12
- cdk_factory/configurations/devops.py,sha256=PG-s2ldZmMULheWdKf2lf2LSugLoKiOKyLELTZJJxu8,2506
12
+ cdk_factory/configurations/devops.py,sha256=opeMenTgzWCNcrEyFX3SkTUvwFerLyjSd6xipvNVuog,2500
13
13
  cdk_factory/configurations/enhanced_base_config.py,sha256=LQQBn_99n41vkqvpU3NhY_baizCwPz2Di-V3iFBL6oE,6660
14
14
  cdk_factory/configurations/enhanced_ssm_config.py,sha256=J23PCinDTlji1XzsjOhIk9C8PubZc5ICpSWqPf3B0Vw,15873
15
15
  cdk_factory/configurations/management.py,sha256=TSOIyxO9hGNxbgiTsS8a3pz03ungXiNqPPtZtfOpr8M,1373
16
16
  cdk_factory/configurations/pipeline.py,sha256=3RmRP1GIk42rjYZ-A9H3357RcO13IA47N-2IQcBkySQ,4939
17
- cdk_factory/configurations/pipeline_stage.py,sha256=eAT-FoIepIuv5tObk4TXlCN47FaatQO2rrFchgbMdXU,3415
17
+ cdk_factory/configurations/pipeline_stage.py,sha256=hEjgaeaHYLRtkok5yBJwZg5zmPMPUHIRiUd0kzxWoRU,4453
18
18
  cdk_factory/configurations/stack.py,sha256=7whhC48dUYw7BBFV49zM1Q3AghTNkaiDfy4kKYDm_RQ,2217
19
- cdk_factory/configurations/workload.py,sha256=sM-B6UKOdOn5_H-eWmW03J9oa8YZZmO0bvQ69wbCM0Q,7756
19
+ cdk_factory/configurations/workload.py,sha256=ht9sgnCn6b-u8eme5bEovwSuy1VMd4uqTZNJzX3v9Zo,9247
20
20
  cdk_factory/configurations/resources/_resources.py,sha256=tnXGn4kEC0JPQaTWB3QpAZG-2hIGBtugHTzuKn1OTvE,2548
21
+ cdk_factory/configurations/resources/acm.py,sha256=HsHwiH15p0zTqRGDErn35kBEa3rkaRWTDJzVequR9oY,3062
21
22
  cdk_factory/configurations/resources/api_gateway.py,sha256=-k4hMGszIdQLb5DGmWBIPy49YGutp8zczafRh-Vob0I,4904
22
23
  cdk_factory/configurations/resources/apigateway_route_config.py,sha256=6ytn_nwKwlfpBtHL5sV6gxMpgAJ3p6QFGumMoW4CTHM,2351
23
- cdk_factory/configurations/resources/auto_scaling.py,sha256=rY-lZBZIS3bq0Lzf4IGbmMxhgiD_tknjjTZhh4Z6yFI,5922
24
- cdk_factory/configurations/resources/cloudfront.py,sha256=oCWa9I8hbXVu114t-IO5frW6hgvPoovFgDbipDqFoGs,3848
24
+ cdk_factory/configurations/resources/auto_scaling.py,sha256=jga8qmNY_Ctk5CWY43Bz_gMEFvN6rwKLkyAl9d5d-ko,6000
25
+ cdk_factory/configurations/resources/cloudfront.py,sha256=YU4my1sQjLnf4DNBECS4GvPAxUG2FX_BszfO76mSbYw,3959
25
26
  cdk_factory/configurations/resources/cloudwatch_widget.py,sha256=EdEQSXUkDtoY_Mg_cJBWo1Hp84jSiK7U9tsd3k1VhKI,1271
26
27
  cdk_factory/configurations/resources/code_artifact.py,sha256=P2X2i6NEcePitEf2wkN6lFTjIbXasn0uzrlPOT0tEac,3253
27
28
  cdk_factory/configurations/resources/code_artifact_login.py,sha256=mKd8Bx0WypmSspfibwXbgubbIzW-6gGdQqIHvOnDAYQ,6066
@@ -29,108 +30,114 @@ cdk_factory/configurations/resources/code_repository.py,sha256=rAM6cbMtNR_S4TfiB
29
30
  cdk_factory/configurations/resources/cognito.py,sha256=udX2AJ1ITLhy4f1XiJQwrva6F4i9NdbSm0zTg5PGku8,10649
30
31
  cdk_factory/configurations/resources/docker.py,sha256=hUbuxkuhcQu9LnLX7I8_57eTmHefEAGVnOHO37MkqC4,2166
31
32
  cdk_factory/configurations/resources/dynamodb.py,sha256=HsZMOaRwfuNPwKIzokeeE3f5zAQLTB5hRb_GzYq2ibg,2903
32
- cdk_factory/configurations/resources/ecr.py,sha256=o9hHzEBVPoxUvWZGXGbRJ-98FmP6fMLY5a1-qg42jL0,8253
33
- cdk_factory/configurations/resources/ecs_service.py,sha256=fAW4EuBNhPrE7G0QcHXongKoAnFeGMRS6iP7OuGP5Fw,4926
33
+ cdk_factory/configurations/resources/ecr.py,sha256=iJEtKqBT7vQU0LU4urIglraIR7cPZqp3HQBs_2An7kA,8303
34
+ cdk_factory/configurations/resources/ecs_cluster.py,sha256=mQYJu7SUPDl5E4dMR6HCPFoWvFA3RGIb0iMNn-K7LX8,3635
35
+ cdk_factory/configurations/resources/ecs_service.py,sha256=iwUVewUy9fQSLpkfRTNuIaWy7eQYWTHFiiD1jIYt9zU,5452
34
36
  cdk_factory/configurations/resources/exisiting.py,sha256=EVOLnkB-DGfTlmDgyQ5DD5k2zYfpFxqI3gugDR7mifI,478
35
37
  cdk_factory/configurations/resources/lambda_edge.py,sha256=MjmiwDkys4aoRvDQhH3MT6BgeShzJXNWL7761HJrLtQ,3404
36
38
  cdk_factory/configurations/resources/lambda_function.py,sha256=VENZ9-ABJ5mjcN8J8wdLH4KHDYr1kWO0iFDH0B2mJXA,14659
37
39
  cdk_factory/configurations/resources/lambda_layers.py,sha256=gVeP_-LC3Eq0lkPaG_JfFUwboM5evRPr99SfKj53m7A,633
38
40
  cdk_factory/configurations/resources/lambda_triggers.py,sha256=MD7cdMNKEulNBhtMLIFnWJuJ5R-yyIqa0LHUgbSQerA,834
39
- cdk_factory/configurations/resources/load_balancer.py,sha256=idpKdvkkCM7J9J2pNjMBOY1DNaFR1tk1tFjTg76bvrY,5267
40
- cdk_factory/configurations/resources/monitoring.py,sha256=zsfDMa7yph33Ql8iP7lIqqLAyixh-Mesi0imtZJFdcE,2310
41
- cdk_factory/configurations/resources/rds.py,sha256=is_odfCoe3kyiz8DpDxDayt1aVICJoNWuhuaHZ98qQo,5197
41
+ cdk_factory/configurations/resources/load_balancer.py,sha256=P-jKemIjIWWqScmQKspmRy1m3BrwNkRtTNHDStOAJds,5617
42
+ cdk_factory/configurations/resources/monitoring.py,sha256=CPYWbUbWQzoPqDhdPiB4Vahq-pPi6BEkavkVohadSIo,2422
43
+ cdk_factory/configurations/resources/rds.py,sha256=ap2sbrcPsesfaPSluzyomGgT70_PUg9B39smVw6fvEM,15927
42
44
  cdk_factory/configurations/resources/resource_mapping.py,sha256=cwv3n63RJ6E59ErsmSTdkW4i-g8huhHtKI0ExbRhJxA,2182
43
45
  cdk_factory/configurations/resources/resource_naming.py,sha256=VE9S2cpzp11qqPL2z1sX79wXH0o1SntO2OG74nEmWC8,5508
44
46
  cdk_factory/configurations/resources/resource_types.py,sha256=1WQHyDoErb-M-tETZZzyLDtbq_jdC85-I403dM48pgE,2317
45
47
  cdk_factory/configurations/resources/route53.py,sha256=FwfAL90amoQqn7DSGcIprlfNhbJ08T80joplxLg99Ko,3453
46
48
  cdk_factory/configurations/resources/route53_hosted_zone.py,sha256=qjEYPCSxSOx5blr9EULv892ezxkCs--yrLa1ngWbyXM,880
47
- cdk_factory/configurations/resources/rum.py,sha256=5aNLhyJEl97spby2gEV59RsMIQpUto2hGh1DeSyIp_I,5149
48
- cdk_factory/configurations/resources/s3.py,sha256=LBwTOZ4tOxNbgiu1fFGHOTyF5jlzeVphc_9VAqNw8zA,6042
49
+ cdk_factory/configurations/resources/rum.py,sha256=KgC2Mxhtr5XrICVXdgOXmxYp0GKu9lBs7izfG-Re9Ck,5294
50
+ cdk_factory/configurations/resources/s3.py,sha256=kLY0XNCfErNYnOwekefFJxEJ_AKPifA-wSaaNczDp94,6036
49
51
  cdk_factory/configurations/resources/security_group.py,sha256=8kQtaaRVEn2aDm8XoC7QFh2mDOFbPbgobmssIuqU8MA,2259
50
- cdk_factory/configurations/resources/security_group_full_stack.py,sha256=OzcQF5UMqIVAtDAlGY1kf1IWxq2x_gmnwAUTIZ5ITzY,2947
52
+ cdk_factory/configurations/resources/security_group_full_stack.py,sha256=CujSl6mfPlVO0Dxso8fDjwW5VZB0vbeP9HqbcTaM8H4,2657
51
53
  cdk_factory/configurations/resources/sqs.py,sha256=fAh2dqttJ6PX46enFRULuiLEu3TEj0Vb2xntAOgUpYE,4346
52
- cdk_factory/configurations/resources/vpc.py,sha256=sNn6w76bHFwmt6N76gZZhqpsuNB9860C1SZu6tebaXY,3835
54
+ cdk_factory/configurations/resources/vpc.py,sha256=_W77du9wf8SJM64JbEAxEOQYerOm6aw4YaSsE7A_kKE,4453
53
55
  cdk_factory/constructs/cloudfront/cloudfront_distribution_construct.py,sha256=LHgjvTNghCMTpHh90VWl7AbE100Er-S9EgyEVt12J_c,25809
54
- cdk_factory/constructs/ecr/ecr_construct.py,sha256=JLz3gWrsjlM0XghvbgxuoGlF-VIo_7IYxtgX7mTkidE,10660
56
+ cdk_factory/constructs/ecr/ecr_construct.py,sha256=jEimLwLvO5ERuFEn_L2q2pyPKgkdHQ6Oi7Sy990ttSg,11002
55
57
  cdk_factory/constructs/lambdas/lambda_function_construct.py,sha256=SQ5SEXn4kezVAzXuv_A_JB3o_svyBXOMi-htvfB9HQs,4516
56
58
  cdk_factory/constructs/lambdas/lambda_function_docker_construct.py,sha256=O8aiHpNQ59eE3qEttEHVxbvp06v4byXOeYCVTAOI_Cg,9993
57
59
  cdk_factory/constructs/lambdas/lambda_function_role_construct.py,sha256=nJoxKv-4CWugX-ZkAzoG8wrfSsHqXqiMZnGRqSyS4Po,1453
58
- cdk_factory/constructs/lambdas/policies/policy_docs.py,sha256=YKXCk_tUTIGlWghLm_gLvLZFvc92AVxISyMkeWcym_o,21150
60
+ cdk_factory/constructs/lambdas/policies/policy_docs.py,sha256=Zk6qJLnzu2dm9wt2-VF5xYzIwXtRJAa1hYDaDo-G1MI,21125
59
61
  cdk_factory/constructs/lambdas/policies/policy_statements.py,sha256=9DnSehsV8A_sBrSe4A--PQB6kii2HSnW4RnmhgVfon0,4164
60
62
  cdk_factory/constructs/s3_buckets/s3_bucket_construct.py,sha256=5DK5aVUAveJYBjmPby2lg55r1FQMduLMJSQ4N58rwmc,3252
61
63
  cdk_factory/constructs/s3_buckets/s3_bucket_replication_destination_construct.py,sha256=H-EJ2Q71LI5FPQ9thMkXDGRuwJdFc_2OzGIrWA98lxg,2517
62
64
  cdk_factory/constructs/s3_buckets/s3_bucket_replication_source_construct.py,sha256=ZLKbRcMK1q73VruxCH62XbymebKt-lKV5Kul9OjkZiA,3763
63
65
  cdk_factory/constructs/sqs/policies/sqs_policies.py,sha256=4p0G8G-fqNKSr68I55fvqH-DkhIeXyGaFBKkICIJ-qM,1277
64
- cdk_factory/interfaces/enhanced_ssm_parameter_mixin.py,sha256=5-aQ4sg47LQ4AHjd0j20gxyM5U5-NOTeBsGsEUA_K3E,14374
65
- cdk_factory/interfaces/istack.py,sha256=bhTBs-o9FgKwvJMSuwxjUV6D3nUlvZHVzfm27jP9x9Y,987
66
+ cdk_factory/interfaces/istack.py,sha256=3xqGw5kNTt_KeLHdMxI7rIR0YORqcWQOqsacmDlTAv0,1167
66
67
  cdk_factory/interfaces/live_ssm_resolver.py,sha256=3FIr9a02SXqZmbFs3RT0WxczWEQR_CF7QSt7kWbDrVE,8163
67
- cdk_factory/interfaces/ssm_parameter_mixin.py,sha256=uA2j8HmAOpuEA9ynRj51s0WjUHMVLsbLQN-QS9NKyHA,12089
68
+ cdk_factory/interfaces/networked_stack_mixin.py,sha256=CtWT7Nhy73f0goQQG02jG7lsEucq5OrtZ0ltrp7XTFA,2884
69
+ cdk_factory/interfaces/standardized_ssm_mixin.py,sha256=Vzry6QWOYCJf5ZZeAJM9QKwj1L3-JWG9SUzB4Tsi1HM,24378
70
+ cdk_factory/interfaces/vpc_provider_mixin.py,sha256=Kj0mmZd54NINprixJLs8zL-WWiSd0AQBtGdwNg8cz14,8207
68
71
  cdk_factory/lambdas/health_handler.py,sha256=dd40ykKMxWCFEIyp2ZdQvAGNjw_ylI9CSm1N24Hp2ME,196
69
- cdk_factory/lambdas/edge/ip_gate/handler.py,sha256=YrXO42gEhJoBTaH6jS7EWqjHe9t5Fpt4WLgY8vjtou0,10474
72
+ cdk_factory/lambdas/edge/ip_gate/handler.py,sha256=gUevgX462mqGYddtQIyJ1-Jk3oXhFmbmd46jlqjai9E,10657
70
73
  cdk_factory/pipeline/path_utils.py,sha256=fvWdrcb4onmpIu1APkHLhXg8zWfK74HcW3Ra2ynxfXM,2586
71
- cdk_factory/pipeline/pipeline_factory.py,sha256=rvtkdlTPJG477nTVRN8S2ksWt4bwpd9eVLFd9WO02pM,17248
74
+ cdk_factory/pipeline/pipeline_factory.py,sha256=8WXXMXZ4PiEOYAYA8oEKBe8mS--kUGpohbZMg0NhH7w,26324
72
75
  cdk_factory/pipeline/stage.py,sha256=Be7ExMB9A-linRM18IQDOzQ-cP_I2_ThRNzlT4FIrUg,437
73
76
  cdk_factory/pipeline/security/policies.py,sha256=H3-S6nipz3UtF9Pc5eJYr4-aREUTCaJWMjOUyd6Rdv4,4406
74
77
  cdk_factory/pipeline/security/roles.py,sha256=ZB_O5H_BXgotvVspS2kVad9EMcY-a_-vU7Nm1_Z5MB8,4985
75
78
  cdk_factory/stack/istack.py,sha256=-n0FTLvG7uvLxkyqRGjqFTguZeTRuXwFxGzcAIqbsj8,174
76
- cdk_factory/stack/stack_factory.py,sha256=zn4JwfpZidxkYLmv6uT1GaFPFRidTFj0NUGKWDNFRb8,1701
79
+ cdk_factory/stack/stack_factory.py,sha256=PfFzKxfM_5JPhK33_acEvpT4gll_AFCqZP7-lPifbJk,3649
77
80
  cdk_factory/stack/stack_module_loader.py,sha256=EA7ceb8qyktzkYgPYaixQdPJsi8FwTsMU-NrgtXwXcw,1144
78
81
  cdk_factory/stack/stack_module_registry.py,sha256=J14-A75VZESzRQa8p-Fepdap7Z8T7mradTu3sVzuBx8,378
79
82
  cdk_factory/stack/stack_modules.py,sha256=kgEK-j0smZPozVwTCfM1g1V17EyTBT0TXAQZq4vZz0o,784
80
- cdk_factory/stack_library/__init__.py,sha256=5Y9TpIe8ZK1688G60PGcuP-hM0RvYEY_3Hl2qJCJJrw,581
81
- cdk_factory/stack_library/stack_base.py,sha256=tTleSFmlf26DuKVF_ytftf8P7IVWb5iex8cYfYupfvQ,4940
82
- cdk_factory/stack_library/api_gateway/api_gateway_stack.py,sha256=l6J5uurBQqbhj9JuvQitV9PiIHS5kqa-dFWifCeA3GM,39347
83
+ cdk_factory/stack_library/__init__.py,sha256=_v4kz9EYAjox6strrTK_4fb9GloJ2Kyhf63VRPivl2U,638
84
+ cdk_factory/stack_library/stack_base.py,sha256=Cu3qeqPQf33QaaXoxk_EaziNCIXcyspOo5AU3eX_wyM,5140
85
+ cdk_factory/stack_library/acm/__init__.py,sha256=4FNRLykblcKZvq_wieYwvv9N_jgrZnJ7ECH9xKh-0Ls,81
86
+ cdk_factory/stack_library/acm/acm_stack.py,sha256=QJ3GkT17PmWoGkfO5Um02hvrfyJ9HbiPMnclwDP7IbA,5846
87
+ cdk_factory/stack_library/api_gateway/api_gateway_stack.py,sha256=PvLdGvcopGpLP0FwpfUcfXNiTIfYLTXqrG-TniE38yc,39643
83
88
  cdk_factory/stack_library/auto_scaling/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
84
- cdk_factory/stack_library/auto_scaling/auto_scaling_stack.py,sha256=XPTPGF-W8ARvzW8UYd4yPJ7xFUw-2BrdxQOYk9I-v3g,23490
89
+ cdk_factory/stack_library/auto_scaling/auto_scaling_stack.py,sha256=Ct1LkIlKKAi-F6CRNo2oJI0V-yLWvnHAokA367NtGsU,21851
85
90
  cdk_factory/stack_library/aws_lambdas/lambda_stack.py,sha256=SFbBPvvCopbyiuYtq-O5sQkFCf94Wzua6aDUXiFDSB4,26161
86
91
  cdk_factory/stack_library/buckets/README.md,sha256=XkK3UNVtRLE7NtUvbhCOBBYUYi8hlrrSaI1s3GJVrqI,78
87
92
  cdk_factory/stack_library/buckets/bucket_stack.py,sha256=SLoZqSffAqmeBBEVUQg54D_8Ad5UKdkjEAmKAVgAqQo,1778
88
93
  cdk_factory/stack_library/cloudfront/__init__.py,sha256=Zfx50q4xIJ4ZEoVIzUBDTKbRE9DKDM6iyVIFhtQXvww,153
89
94
  cdk_factory/stack_library/cloudfront/cloudfront_stack.py,sha256=kBMWxHlB48aRcFGIX71mRso0tEuEaQxcTBr3YCJOr4s,30210
90
- cdk_factory/stack_library/code_artifact/code_artifact_stack.py,sha256=vySYIjWGTdVfMcUOyJdW6gTL1maHWq9ThzfrN_rVL5A,6290
91
- cdk_factory/stack_library/cognito/cognito_stack.py,sha256=zEHkKVCIeyZywPs_GIMXCXyCux9RAKdl5kba3wy8wtQ,24608
92
- cdk_factory/stack_library/dynamodb/dynamodb_stack.py,sha256=TVyOrUhgaSuN8uymkpaQcpOaSA0lkYJ8QUMgakTCKus,6771
95
+ cdk_factory/stack_library/code_artifact/code_artifact_stack.py,sha256=k831b_fAFoXSiwj5cencnCQzUSeuKIUyVCp6Ev_TMgI,6274
96
+ cdk_factory/stack_library/cognito/cognito_stack.py,sha256=3tjKCNcIwXZn7fd4EDQdY6H9m6CnZohI4uTQ4TpacRQ,25327
97
+ cdk_factory/stack_library/dynamodb/dynamodb_stack.py,sha256=-_Ij1zXIxUuZIWgdevam_1vD3LEJ6pFs9U0hmw0KwIw,6743
93
98
  cdk_factory/stack_library/ecr/README.md,sha256=xw2wPx9WN03Y4BBwqvbi9lAFGNyaD1FUNpqxVJX14Oo,179
94
- cdk_factory/stack_library/ecr/ecr_stack.py,sha256=1xA68sxFVyqreYjXrP_7U9I8RF9RtFeR6KeEfSWuC2U,2118
95
- cdk_factory/stack_library/ecs/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
96
- cdk_factory/stack_library/ecs/ecs_service_stack.py,sha256=IVqzrV6cJCJXQV-eS2mPInUr1bjjIwGIKDNH2Gc-LFM,27709
99
+ cdk_factory/stack_library/ecr/ecr_stack.py,sha256=KLbd5WN5-ZiojsS5wJ4PX-tIL0cCylCSvXjO6sVrgWY,2102
100
+ cdk_factory/stack_library/ecs/__init__.py,sha256=o5vGDtD_h-gVXb3-Ysr8xUNpEcMsnmMVgZv2Pupcdow,219
101
+ cdk_factory/stack_library/ecs/ecs_cluster_stack.py,sha256=sAPTLU5CAwMoLTW_pNy_cd0OtVkfDR7IxxsSq5AE0yo,12091
102
+ cdk_factory/stack_library/ecs/ecs_service_stack.py,sha256=3en447kWBOqd0d_i2C8mRRBscO2GqN9-B2l_PW7kZuM,27409
97
103
  cdk_factory/stack_library/lambda_edge/__init__.py,sha256=ByBJ_CWdc4UtTmFBZH-6pzBMNkjkdtE65AmnB0Fs6lM,156
98
- cdk_factory/stack_library/lambda_edge/lambda_edge_stack.py,sha256=CdId_1kcZmYr1lLI9AD3-KqtE6voC3641PIloJmWiNI,16414
104
+ cdk_factory/stack_library/lambda_edge/lambda_edge_stack.py,sha256=ft5AxHy8__F90ZYDaoJwTjACGIfrn2Sd9Zr2CdHO7GE,16398
99
105
  cdk_factory/stack_library/load_balancer/__init__.py,sha256=wZpKw2OecLJGdF5mPayCYAEhu2H3c2gJFFIxwXftGDU,52
100
- cdk_factory/stack_library/load_balancer/load_balancer_stack.py,sha256=SBB-Cknon7U317iR2chFNWjny-lp8BFmzFMCYLP-8Uo,28253
106
+ cdk_factory/stack_library/load_balancer/load_balancer_stack.py,sha256=o0sxQIayyvOVBIiBrNpY5GvENqnWiYQ16_rn2CGA6yk,29900
101
107
  cdk_factory/stack_library/monitoring/__init__.py,sha256=k1G_KDx47Aw0UugaL99PN_TKlyLK4nkJVApCaAK7GJg,153
102
108
  cdk_factory/stack_library/monitoring/monitoring_stack.py,sha256=N_1YvEXE7fboH_S3kv_dSKZsufxMuPdFMjGzlNFpuSo,19283
103
109
  cdk_factory/stack_library/rds/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
104
- cdk_factory/stack_library/rds/rds_stack.py,sha256=wlKPRCvioz9e6mzMuUDGUBw0gcnCDBnTI0ZN2NVatUo,14822
110
+ cdk_factory/stack_library/rds/rds_stack.py,sha256=5dk_SUMkbnSalD2AKI0c-LrKbaHB4OOgq6DmRa4QMbM,15377
105
111
  cdk_factory/stack_library/route53/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
106
- cdk_factory/stack_library/route53/route53_stack.py,sha256=R-6DW7gIjeg25uBT5ZMLNDiQUOSZMipc-Tw6f8POVvI,8081
112
+ cdk_factory/stack_library/route53/route53_stack.py,sha256=mPUJta6maUNlkXup7xKsqq7gefsRI1w_ulInE29wJs4,8387
107
113
  cdk_factory/stack_library/rum/__init__.py,sha256=gUrWQdzd4rZ2J0YzAQC8PsEGAS7QgyYjB2ZCUKWasy4,90
108
- cdk_factory/stack_library/rum/rum_stack.py,sha256=OvQ6tsjYcXS8adqU_Xh0A_VKdnPtQnij4cG67nNqSVo,13611
114
+ cdk_factory/stack_library/rum/rum_stack.py,sha256=c67m0Jbyx8hx9TTx9TBBhZMDqtSK7QCqKx_Ec1t8LgY,14067
109
115
  cdk_factory/stack_library/security_group/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
110
- cdk_factory/stack_library/security_group/security_group_full_stack.py,sha256=je6MF6lriSaOMtIZ9hrcFagXObu5SItccpBr9Mp5TMo,14200
111
- cdk_factory/stack_library/security_group/security_group_stack.py,sha256=2zxd5ozgQ4GP0xi-Ni7SyChtEAOzC0nXeGz78DPXwPg,14445
116
+ cdk_factory/stack_library/security_group/security_group_full_stack.py,sha256=yvZ5QS9eDj_LkkwHY_Pcb37lOVPbGMfSdizZa1X6BEI,13561
117
+ cdk_factory/stack_library/security_group/security_group_stack.py,sha256=Zv9FCEHvSBT1cM9bXOtyIUFwhRHKCSTgvaqOyhGj0wg,14456
112
118
  cdk_factory/stack_library/simple_queue_service/sqs_stack.py,sha256=jJksWrvrvgZUMM01RZ317DOIxqIJbkYYSYu38w0jHpc,6039
113
119
  cdk_factory/stack_library/vpc/__init__.py,sha256=7pIqP97Gf2AJbv9Ebp1WbQGHYhgEbWJ52L1MzeXBybA,42
114
- cdk_factory/stack_library/vpc/vpc_stack.py,sha256=UZuzb5uSOi4ghuLGPvsKqc3gwe6XI89jHV4WHX8MelA,11472
115
- cdk_factory/stack_library/websites/static_website_stack.py,sha256=A292BlKDof0JnVewkK_3JiRB04rX7J9Na0a-iz3JWzw,11243
120
+ cdk_factory/stack_library/vpc/vpc_stack.py,sha256=AUq5oAJa1OrtUIqPZlnco0jSBOyOQvV3tEspIe2ZAGc,19451
121
+ cdk_factory/stack_library/websites/static_website_stack.py,sha256=jnB-u6x37w2tsheG7WrKBY50WIx1AnCKoVh7mbT4rZU,11254
116
122
  cdk_factory/stages/websites/static_website_stage.py,sha256=X4fpKXkhb0zIbSHx3QyddBhVSLBryb1vf1Cg2fMTqog,755
117
123
  cdk_factory/templates/README.md,sha256=ATBEjG6beYvbEAdLtZ_8xnxgFD5X0cgZoI_6pToqH90,2679
118
124
  cdk_factory/templates/app.py.template,sha256=aM60x0nNV80idtCL8jm1EddY63F5tDITYOlavg-BPMU,1069
119
125
  cdk_factory/templates/cdk.json.template,sha256=SuGz4Y6kCVMDRpJrA_AJlp0kwdENiJPVngIv1xP5bwI,3526
120
- cdk_factory/utilities/api_gateway_integration_utility.py,sha256=Mpyq038ZvL8FafcOwqp2Jj0cNcD_nLfVyTBzMYaUskM,63683
126
+ cdk_factory/utilities/api_gateway_integration_utility.py,sha256=xw7qL8lKe7bYS2Kobgv-buy_PI5PunouH4XqcYWKRag,64210
121
127
  cdk_factory/utilities/commandline_args.py,sha256=0FiNEJFbWVN8Ct7r0VHnJEx7rhUlaRKT7R7HMNJBSTI,2216
122
128
  cdk_factory/utilities/configuration_loader.py,sha256=z0ZdGLNbTO4_yfluB9zUh_i_Poc9qj-7oRyjMRlNkN8,1522
123
129
  cdk_factory/utilities/docker_utilities.py,sha256=6ee9KEGsaRJWo6FqvdPtE3_L2Emp3Lc0vu2Ie3VoflI,8280
124
- cdk_factory/utilities/environment_services.py,sha256=cd2T0efJtFPMLa1Fm7MPL-sqUlhKXCB7_XHsR8sfymE,9696
130
+ cdk_factory/utilities/environment_services.py,sha256=CTuF7MvpGfvuRouS3q-WZIyjALD5E7xr96HXgIawl90,9779
125
131
  cdk_factory/utilities/file_operations.py,sha256=fxqT0iyYZkb46lQr_XXadhFTca_1neVW0VRVkbyMmhA,9462
126
132
  cdk_factory/utilities/git_utilities.py,sha256=7Xac8PaThc7Lmk5jtDBHaJOj-fWRT017cgZmgXkVizM,3155
127
- cdk_factory/utilities/json_loading_utility.py,sha256=YRgzA1I-B_HwZm1eWJTeQ1JLkebCL4C1gpHOqo6GkCA,10341
133
+ cdk_factory/utilities/json_loading_utility.py,sha256=i6C1GJ1HhbTBJRmNP8nEM6OeMZYjE9_eaVL78HHLYSE,10818
128
134
  cdk_factory/utilities/lambda_function_utilities.py,sha256=S1GvBsY_q2cyUiaud3HORJMnLhI5cRi31fbeaktY-_Q,15826
129
135
  cdk_factory/utilities/os_execute.py,sha256=5Op0LY_8Y-pUm04y1k8MTpNrmQvcLmQHPQITEP7EuSU,1019
130
136
  cdk_factory/utils/api_gateway_utilities.py,sha256=If7Xu5s_UxmuV-kL3JkXxPLBdSVUKoLtohm0IUFoiV8,4378
131
- cdk_factory/workload/workload_factory.py,sha256=mM8GU_5mKq_0OyK060T3JrUSUiGAcKf0eqNlT9mfaws,6028
132
- cdk_factory-0.15.10.dist-info/METADATA,sha256=9N2bg9PHi8myWMfxSoxxXA40AuuFbQl10ouIscuHBMQ,2452
133
- cdk_factory-0.15.10.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
134
- cdk_factory-0.15.10.dist-info/entry_points.txt,sha256=S1DPe0ORcdiwEALMN_WIo3UQrW_g4YdQCLEsc_b0Swg,53
135
- cdk_factory-0.15.10.dist-info/licenses/LICENSE,sha256=NOtdOeLwg2il_XBJdXUPFPX8JlV4dqTdDGAd2-khxT8,1066
136
- cdk_factory-0.15.10.dist-info/RECORD,,
137
+ cdk_factory/validation/config_validator.py,sha256=Pb0TkLiPFzUplBOgMorhRCVm08vEzZhRU5xXCDTa5CA,17602
138
+ cdk_factory/workload/workload_factory.py,sha256=yDI3cRhVI5ELNDcJPLpk9UY54Uind1xQoV3spzT4z7E,6068
139
+ cdk_factory-0.18.9.dist-info/METADATA,sha256=P8DYXu4KJp-D52Bkdvg7mN9aFNDlC8toyp8Ls7gwvrE,2451
140
+ cdk_factory-0.18.9.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
141
+ cdk_factory-0.18.9.dist-info/entry_points.txt,sha256=S1DPe0ORcdiwEALMN_WIo3UQrW_g4YdQCLEsc_b0Swg,53
142
+ cdk_factory-0.18.9.dist-info/licenses/LICENSE,sha256=NOtdOeLwg2il_XBJdXUPFPX8JlV4dqTdDGAd2-khxT8,1066
143
+ cdk_factory-0.18.9.dist-info/RECORD,,
@@ -1,321 +0,0 @@
1
- """
2
- Geek Cafe, LLC
3
- Maintainers: Eric Wilson
4
- MIT License. See Project Root for the license information.
5
- """
6
-
7
- """
8
- Enhanced SSM Parameter Mixin for CDK Factory
9
- """
10
-
11
- import os
12
- from typing import Dict, Any, Optional, List
13
- from aws_cdk import aws_ssm as ssm
14
- from constructs import Construct
15
- from aws_lambda_powertools import Logger
16
- from cdk_factory.configurations.enhanced_ssm_config import EnhancedSsmConfig, SsmParameterDefinition
17
- from cdk_factory.configurations.enhanced_base_config import EnhancedBaseConfig
18
- from cdk_factory.interfaces.live_ssm_resolver import LiveSsmResolver
19
-
20
- logger = Logger(service="EnhancedSsmParameterMixin")
21
-
22
-
23
- class EnhancedSsmParameterMixin:
24
- """
25
- Enhanced SSM parameter mixin with auto-discovery and flexible patterns.
26
-
27
- This mixin extends the original SsmParameterMixin to support:
28
- - Auto-discovery of parameters based on resource types
29
- - Flexible pattern templates with environment variable support
30
- - Backward compatibility with existing configurations
31
- - Enhanced error handling and logging
32
- """
33
-
34
- def setup_enhanced_ssm_integration(
35
- self,
36
- scope: Construct,
37
- config,
38
- resource_type: str = None,
39
- resource_name: str = None,
40
- workload_config = None,
41
- deployment_config = None # Deprecated, for backward compatibility
42
- ):
43
- """
44
- Setup enhanced SSM integration for a resource.
45
-
46
- Architecture: One workload deployment = One environment
47
- Environment should be defined at workload level.
48
-
49
- Args:
50
- scope: The CDK construct scope
51
- config: Configuration object with SSM settings
52
- resource_type: Type of resource (e.g., 'api_gateway', 'cognito', 'dynamodb')
53
- resource_name: Name of the resource instance
54
- workload_config: Workload configuration (PRIMARY - contains environment)
55
- deployment_config: Deployment configuration (DEPRECATED - for backward compatibility)
56
- """
57
- config_dict = config if isinstance(config, dict) else config.dictionary
58
- workload_dict = workload_config.dictionary if hasattr(workload_config, 'dictionary') else (workload_config or {})
59
- deployment_dict = deployment_config.dictionary if hasattr(deployment_config, 'dictionary') else (deployment_config or {})
60
-
61
- self.enhanced_ssm_config = EnhancedSsmConfig(
62
- config=config_dict,
63
- resource_type=resource_type or "unknown",
64
- resource_name=resource_name or "default",
65
- workload_config=workload_dict,
66
- deployment_config=deployment_dict # For backward compatibility
67
- )
68
- self.scope = scope
69
-
70
- # Initialize live SSM resolver if configured
71
- self.live_resolver = LiveSsmResolver(config_dict)
72
- if self.live_resolver.enabled:
73
- logger.info(f"Live SSM resolution enabled for {resource_type}/{resource_name}")
74
-
75
- def auto_export_resources(self, resource_values: Dict[str, Any], context: Dict[str, Any] = None) -> Dict[str, str]:
76
- """
77
- Automatically export resources based on enhanced configuration.
78
-
79
- Args:
80
- resource_values: Dictionary of resource values to export
81
- context: Additional context variables for template formatting
82
-
83
- Returns:
84
- Dictionary mapping attribute names to SSM parameter paths
85
- """
86
- if not hasattr(self, 'enhanced_ssm_config') or not self.enhanced_ssm_config.enabled:
87
- return {}
88
-
89
- exported_params = {}
90
- export_definitions = self.enhanced_ssm_config.get_export_definitions()
91
-
92
- logger.info(f"Auto-exporting {len(export_definitions)} parameters for {self.enhanced_ssm_config.resource_type}")
93
-
94
- for definition in export_definitions:
95
- attr = definition.attribute
96
- ssm_path = definition.path
97
-
98
- if attr in resource_values:
99
- value = resource_values[attr]
100
- if value is not None:
101
- try:
102
- param = self._create_enhanced_ssm_parameter(
103
- ssm_path,
104
- value,
105
- definition.description or f"{attr} for {self.enhanced_ssm_config.resource_name}",
106
- definition.parameter_type
107
- )
108
- exported_params[attr] = ssm_path
109
- logger.info(f"Exported {attr} -> {ssm_path}")
110
- except Exception as e:
111
- logger.error(f"Failed to export {attr} to {ssm_path}: {e}")
112
- else:
113
- logger.warning(f"Attribute {attr} not found in resource values")
114
-
115
- return exported_params
116
-
117
- def auto_import_resources(self, context: Dict[str, Any] = None) -> Dict[str, Any]:
118
- """
119
- Automatically import resources based on enhanced configuration.
120
-
121
- Args:
122
- context: Additional context variables for template formatting
123
-
124
- Returns:
125
- Dictionary of imported resource values
126
- """
127
- if not hasattr(self, 'enhanced_ssm_config') or not self.enhanced_ssm_config.enabled:
128
- logger.info("Enhanced SSM integration not enabled or configured")
129
- return {}
130
-
131
- imported_values = {}
132
- import_definitions = self.enhanced_ssm_config.get_import_definitions()
133
-
134
- logger.info(f"Auto-importing {len(import_definitions)} parameters for {self.enhanced_ssm_config.resource_type}")
135
-
136
- for definition in import_definitions:
137
- try:
138
- value = self._import_enhanced_ssm_parameter(definition.path, definition.attribute)
139
- if value:
140
- imported_values[definition.attribute] = value
141
- logger.info(f"Imported {definition.attribute} <- {definition.path}")
142
- else:
143
- logger.warning(f"No value found for {definition.attribute} at {definition.path}")
144
- except Exception as e:
145
- # Log warning but continue - allows for optional imports
146
- logger.warning(f"Could not import {definition.attribute} from {definition.path}: {e}")
147
-
148
- return imported_values
149
-
150
- def _create_enhanced_ssm_parameter(self, path: str, value: Any, description: str, param_type: str = "String") -> ssm.StringParameter:
151
- """
152
- Create an SSM parameter with enhanced handling.
153
-
154
- Args:
155
- path: SSM parameter path
156
- value: Value to store
157
- description: Parameter description
158
- param_type: Parameter type (String, StringList, SecureString)
159
-
160
- Returns:
161
- Created SSM parameter
162
- """
163
- # Generate a unique construct ID from the path
164
- construct_id = f"ssm-param-{path.replace('/', '-').replace('_', '-')}"
165
-
166
- # Handle different value types - use appropriate CDK constructs
167
- if isinstance(value, list):
168
- # For list values, use StringListParameter
169
- return ssm.StringListParameter(
170
- self.scope,
171
- construct_id,
172
- parameter_name=path,
173
- string_list_value=value,
174
- description=description
175
- )
176
- elif param_type == "SecureString":
177
- # For secure strings, use L1 CfnParameter with Type=SecureString
178
- return ssm.CfnParameter(
179
- self.scope,
180
- construct_id,
181
- name=path,
182
- value=str(value),
183
- type="SecureString",
184
- description=description
185
- )
186
- else:
187
- # For regular strings, use StringParameter (no type parameter needed in CDK v2)
188
- return ssm.StringParameter(
189
- self.scope,
190
- construct_id,
191
- parameter_name=path,
192
- string_value=str(value),
193
- description=description
194
- # Note: 'type' parameter removed - deprecated in CDK v2
195
- )
196
-
197
- def _import_enhanced_ssm_parameter(self, path: str, attribute: str) -> Optional[str]:
198
- """
199
- Import an SSM parameter value with enhanced error handling and live resolution fallback.
200
-
201
- Args:
202
- path: SSM parameter path
203
- attribute: Attribute name for logging
204
-
205
- Returns:
206
- Parameter value or None if not found
207
- """
208
- try:
209
- # Generate a unique construct ID from the path
210
- construct_id = f"imported-param-{path.replace('/', '-').replace('_', '-')}"
211
-
212
- param = ssm.StringParameter.from_string_parameter_name(
213
- self.scope,
214
- construct_id,
215
- path
216
- )
217
- cdk_token_value = param.string_value
218
-
219
- # Check if we should use live resolution for this token
220
- if hasattr(self, 'live_resolver') and self.live_resolver.should_use_live_resolution(cdk_token_value):
221
- live_value = self.live_resolver.resolve_parameter(path, fallback_value=None)
222
- if live_value:
223
- logger.info(f"Live resolved {attribute} from {path}: {live_value[:20]}...")
224
- return live_value
225
- else:
226
- logger.warning(f"Live resolution failed for {attribute} at {path}, using CDK token")
227
-
228
- return cdk_token_value
229
-
230
- except Exception as e:
231
- # Try live resolution as fallback if CDK parameter import fails
232
- if hasattr(self, 'live_resolver') and self.live_resolver.enabled:
233
- logger.info(f"CDK parameter import failed for {path}, attempting live resolution")
234
- live_value = self.live_resolver.resolve_parameter(path, fallback_value=None)
235
- if live_value:
236
- logger.info(f"Live resolved {attribute} from {path} after CDK failure")
237
- return live_value
238
-
239
- logger.debug(f"Failed to import SSM parameter {path} for {attribute}: {e}")
240
- return None
241
-
242
- # Backward compatibility methods that delegate to enhanced versions
243
- def export_resource_to_ssm(
244
- self,
245
- scope: Construct,
246
- resource_values: Dict[str, Any],
247
- config: Any,
248
- resource_name: str,
249
- resource_type: str = None,
250
- context: Dict[str, Any] = None,
251
- ) -> Dict[str, ssm.StringParameter]:
252
- """
253
- Export resource attributes to SSM Parameter Store (backward compatibility).
254
-
255
- This method provides backward compatibility while leveraging enhanced functionality
256
- when an EnhancedBaseConfig is provided.
257
- """
258
- # If we have an enhanced config, use the new auto-export functionality
259
- if isinstance(config, EnhancedBaseConfig):
260
- if not hasattr(self, 'enhanced_ssm_config'):
261
- self.setup_enhanced_ssm_integration(scope, config)
262
-
263
- exported_paths = self.auto_export_resources(resource_values, context)
264
-
265
- # Convert paths back to parameter objects for backward compatibility
266
- parameters = {}
267
- for attr, path in exported_paths.items():
268
- # Create a mock parameter object with the path
269
- parameters[f"{attr}_path"] = type('MockParam', (), {'parameter_name': path})()
270
-
271
- return parameters
272
-
273
- # Fall back to original implementation for non-enhanced configs
274
- from .ssm_parameter_mixin import SsmParameterMixin
275
- mixin = SsmParameterMixin()
276
- return mixin.export_resource_to_ssm(scope, resource_values, config, resource_name, resource_type, context)
277
-
278
- def import_resources_from_ssm(
279
- self,
280
- scope: Construct,
281
- config: Any,
282
- resource_name: str,
283
- resource_type: str = None,
284
- context: Dict[str, Any] = None,
285
- ) -> Dict[str, str]:
286
- """
287
- Import resource attributes from SSM Parameter Store (backward compatibility).
288
-
289
- This method provides backward compatibility while leveraging enhanced functionality
290
- when an EnhancedBaseConfig is provided.
291
- """
292
- # If we have an enhanced config, use the new auto-import functionality
293
- if isinstance(config, EnhancedBaseConfig):
294
- if not hasattr(self, 'enhanced_ssm_config'):
295
- self.setup_enhanced_ssm_integration(scope, config)
296
-
297
- return self.auto_import_resources(context)
298
-
299
- # Fall back to original implementation for non-enhanced configs
300
- from .ssm_parameter_mixin import SsmParameterMixin
301
- mixin = SsmParameterMixin()
302
- return mixin.import_resources_from_ssm(scope, config, resource_name, resource_type, context)
303
-
304
- # Legacy method delegation for full backward compatibility
305
- def export_ssm_parameter(self, scope: Construct, id: str, value: str, parameter_name: str, description: str = None, string_list_value: bool = False) -> ssm.StringParameter:
306
- """Export a value to SSM Parameter Store (legacy compatibility)."""
307
- from .ssm_parameter_mixin import SsmParameterMixin
308
- mixin = SsmParameterMixin()
309
- return mixin.export_ssm_parameter(scope, id, value, parameter_name, description, string_list_value)
310
-
311
- def import_ssm_parameter(self, scope: Construct, id: str, parameter_name: str, version: Optional[int] = None) -> str:
312
- """Import a value from SSM Parameter Store (legacy compatibility)."""
313
- from .ssm_parameter_mixin import SsmParameterMixin
314
- mixin = SsmParameterMixin()
315
- return mixin.import_ssm_parameter(scope, id, parameter_name, version)
316
-
317
- def export_ssm_parameters_from_config(self, scope: Construct, config_dict: Dict[str, Any], ssm_config: Dict[str, str], resource: str = "") -> Dict[str, ssm.StringParameter]:
318
- """Export multiple SSM parameters based on configuration (legacy compatibility)."""
319
- from .ssm_parameter_mixin import SsmParameterMixin
320
- mixin = SsmParameterMixin()
321
- return mixin.export_ssm_parameters_from_config(scope, config_dict, ssm_config, resource)