capo-codedeploy 0.1.0__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.
Files changed (472) hide show
  1. capo_codedeploy/__init__.py +70 -0
  2. capo_codedeploy/_async.py +25 -0
  3. capo_codedeploy/_auth/_identity.py +16 -0
  4. capo_codedeploy/_auth/_providers.py +886 -0
  5. capo_codedeploy/_auth/_signers.py +88 -0
  6. capo_codedeploy/_auth/_sigv4.py +434 -0
  7. capo_codedeploy/_auth/_zapros_handler.py +80 -0
  8. capo_codedeploy/_iter.py +113 -0
  9. capo_codedeploy/_operations/code_deploy_20141006/add_tags_to_on_premises_instances.py +153 -0
  10. capo_codedeploy/_operations/code_deploy_20141006/batch_get_application_revisions.py +173 -0
  11. capo_codedeploy/_operations/code_deploy_20141006/batch_get_applications.py +163 -0
  12. capo_codedeploy/_operations/code_deploy_20141006/batch_get_deployment_groups.py +178 -0
  13. capo_codedeploy/_operations/code_deploy_20141006/batch_get_deployment_instances.py +178 -0
  14. capo_codedeploy/_operations/code_deploy_20141006/batch_get_deployment_targets.py +188 -0
  15. capo_codedeploy/_operations/code_deploy_20141006/batch_get_deployments.py +158 -0
  16. capo_codedeploy/_operations/code_deploy_20141006/batch_get_on_premises_instances.py +158 -0
  17. capo_codedeploy/_operations/code_deploy_20141006/continue_deployment.py +155 -0
  18. capo_codedeploy/_operations/code_deploy_20141006/create_application.py +175 -0
  19. capo_codedeploy/_operations/code_deploy_20141006/create_deployment.py +278 -0
  20. capo_codedeploy/_operations/code_deploy_20141006/create_deployment_config.py +185 -0
  21. capo_codedeploy/_operations/code_deploy_20141006/create_deployment_group.py +320 -0
  22. capo_codedeploy/_operations/code_deploy_20141006/delete_application.py +129 -0
  23. capo_codedeploy/_operations/code_deploy_20141006/delete_deployment_config.py +136 -0
  24. capo_codedeploy/_operations/code_deploy_20141006/delete_deployment_group.py +167 -0
  25. capo_codedeploy/_operations/code_deploy_20141006/delete_git_hub_account_token.py +166 -0
  26. capo_codedeploy/_operations/code_deploy_20141006/delete_resources_by_external_id.py +137 -0
  27. capo_codedeploy/_operations/code_deploy_20141006/deregister_on_premises_instance.py +126 -0
  28. capo_codedeploy/_operations/code_deploy_20141006/get_application.py +157 -0
  29. capo_codedeploy/_operations/code_deploy_20141006/get_application_revision.py +173 -0
  30. capo_codedeploy/_operations/code_deploy_20141006/get_deployment.py +157 -0
  31. capo_codedeploy/_operations/code_deploy_20141006/get_deployment_config.py +162 -0
  32. capo_codedeploy/_operations/code_deploy_20141006/get_deployment_group.py +179 -0
  33. capo_codedeploy/_operations/code_deploy_20141006/get_deployment_instance.py +177 -0
  34. capo_codedeploy/_operations/code_deploy_20141006/get_deployment_target.py +182 -0
  35. capo_codedeploy/_operations/code_deploy_20141006/get_on_premises_instance.py +157 -0
  36. capo_codedeploy/_operations/code_deploy_20141006/list_application_revisions.py +195 -0
  37. capo_codedeploy/_operations/code_deploy_20141006/list_applications.py +149 -0
  38. capo_codedeploy/_operations/code_deploy_20141006/list_deployment_configs.py +147 -0
  39. capo_codedeploy/_operations/code_deploy_20141006/list_deployment_groups.py +162 -0
  40. capo_codedeploy/_operations/code_deploy_20141006/list_deployment_instances.py +198 -0
  41. capo_codedeploy/_operations/code_deploy_20141006/list_deployment_targets.py +188 -0
  42. capo_codedeploy/_operations/code_deploy_20141006/list_deployments.py +199 -0
  43. capo_codedeploy/_operations/code_deploy_20141006/list_git_hub_account_token_names.py +157 -0
  44. capo_codedeploy/_operations/code_deploy_20141006/list_on_premises_instances.py +159 -0
  45. capo_codedeploy/_operations/code_deploy_20141006/list_tags_for_resource.py +157 -0
  46. capo_codedeploy/_operations/code_deploy_20141006/put_lifecycle_event_hook_execution_status.py +177 -0
  47. capo_codedeploy/_operations/code_deploy_20141006/register_application_revision.py +147 -0
  48. capo_codedeploy/_operations/code_deploy_20141006/register_on_premises_instance.py +166 -0
  49. capo_codedeploy/_operations/code_deploy_20141006/remove_tags_from_on_premises_instances.py +153 -0
  50. capo_codedeploy/_operations/code_deploy_20141006/skip_wait_time_for_instance_termination.py +146 -0
  51. capo_codedeploy/_operations/code_deploy_20141006/stop_deployment.py +172 -0
  52. capo_codedeploy/_operations/code_deploy_20141006/tag_resource.py +174 -0
  53. capo_codedeploy/_operations/code_deploy_20141006/untag_resource.py +174 -0
  54. capo_codedeploy/_operations/code_deploy_20141006/update_application.py +134 -0
  55. capo_codedeploy/_operations/code_deploy_20141006/update_deployment_group.py +310 -0
  56. capo_codedeploy/_pagination.py +21 -0
  57. capo_codedeploy/_protocol/__init__.py +1 -0
  58. capo_codedeploy/_protocol/errors.py +93 -0
  59. capo_codedeploy/_protocol/eventstream.py +238 -0
  60. capo_codedeploy/_protocol/serialize.py +47 -0
  61. capo_codedeploy/_protocol/xml.py +33 -0
  62. capo_codedeploy/_rule_engine/__init__.py +0 -0
  63. capo_codedeploy/_rule_engine/_aws_partition.py +160 -0
  64. capo_codedeploy/_rule_engine/_endpoint_rule_set.py +138 -0
  65. capo_codedeploy/_rule_engine/_endpoint_runtime.py +389 -0
  66. capo_codedeploy/_services/_aws_config.py +160 -0
  67. capo_codedeploy/_services/_pipeline.py +198 -0
  68. capo_codedeploy/_services/async_code_deploy.py +3278 -0
  69. capo_codedeploy/_services/code_deploy.py +3229 -0
  70. capo_codedeploy/errors/__init__.py +335 -0
  71. capo_codedeploy/errors/_base.py +94 -0
  72. capo_codedeploy/errors/alarms_limit_exceeded_exception.py +52 -0
  73. capo_codedeploy/errors/application_already_exists_exception.py +54 -0
  74. capo_codedeploy/errors/application_does_not_exist_exception.py +54 -0
  75. capo_codedeploy/errors/application_limit_exceeded_exception.py +54 -0
  76. capo_codedeploy/errors/application_name_required_exception.py +54 -0
  77. capo_codedeploy/errors/arn_not_supported_exception.py +52 -0
  78. capo_codedeploy/errors/batch_limit_exceeded_exception.py +52 -0
  79. capo_codedeploy/errors/bucket_name_filter_required_exception.py +54 -0
  80. capo_codedeploy/errors/deployment_already_completed_exception.py +54 -0
  81. capo_codedeploy/errors/deployment_config_already_exists_exception.py +54 -0
  82. capo_codedeploy/errors/deployment_config_does_not_exist_exception.py +54 -0
  83. capo_codedeploy/errors/deployment_config_in_use_exception.py +54 -0
  84. capo_codedeploy/errors/deployment_config_limit_exceeded_exception.py +54 -0
  85. capo_codedeploy/errors/deployment_config_name_required_exception.py +54 -0
  86. capo_codedeploy/errors/deployment_does_not_exist_exception.py +54 -0
  87. capo_codedeploy/errors/deployment_group_already_exists_exception.py +54 -0
  88. capo_codedeploy/errors/deployment_group_does_not_exist_exception.py +54 -0
  89. capo_codedeploy/errors/deployment_group_limit_exceeded_exception.py +54 -0
  90. capo_codedeploy/errors/deployment_group_name_required_exception.py +54 -0
  91. capo_codedeploy/errors/deployment_id_required_exception.py +54 -0
  92. capo_codedeploy/errors/deployment_is_not_in_ready_state_exception.py +54 -0
  93. capo_codedeploy/errors/deployment_limit_exceeded_exception.py +54 -0
  94. capo_codedeploy/errors/deployment_not_started_exception.py +54 -0
  95. capo_codedeploy/errors/deployment_target_does_not_exist_exception.py +54 -0
  96. capo_codedeploy/errors/deployment_target_id_required_exception.py +54 -0
  97. capo_codedeploy/errors/deployment_target_list_size_exceeded_exception.py +56 -0
  98. capo_codedeploy/errors/description_too_long_exception.py +52 -0
  99. capo_codedeploy/errors/ecs_service_mapping_limit_exceeded_exception.py +54 -0
  100. capo_codedeploy/errors/git_hub_account_token_does_not_exist_exception.py +54 -0
  101. capo_codedeploy/errors/git_hub_account_token_name_required_exception.py +54 -0
  102. capo_codedeploy/errors/iam_arn_required_exception.py +52 -0
  103. capo_codedeploy/errors/iam_session_arn_already_registered_exception.py +54 -0
  104. capo_codedeploy/errors/iam_user_arn_already_registered_exception.py +54 -0
  105. capo_codedeploy/errors/iam_user_arn_required_exception.py +52 -0
  106. capo_codedeploy/errors/instance_does_not_exist_exception.py +54 -0
  107. capo_codedeploy/errors/instance_id_required_exception.py +52 -0
  108. capo_codedeploy/errors/instance_limit_exceeded_exception.py +54 -0
  109. capo_codedeploy/errors/instance_name_already_registered_exception.py +54 -0
  110. capo_codedeploy/errors/instance_name_required_exception.py +54 -0
  111. capo_codedeploy/errors/instance_not_registered_exception.py +54 -0
  112. capo_codedeploy/errors/invalid_alarm_config_exception.py +52 -0
  113. capo_codedeploy/errors/invalid_application_name_exception.py +54 -0
  114. capo_codedeploy/errors/invalid_arn_exception.py +52 -0
  115. capo_codedeploy/errors/invalid_auto_rollback_config_exception.py +54 -0
  116. capo_codedeploy/errors/invalid_auto_scaling_group_exception.py +54 -0
  117. capo_codedeploy/errors/invalid_blue_green_deployment_configuration_exception.py +60 -0
  118. capo_codedeploy/errors/invalid_bucket_name_filter_exception.py +54 -0
  119. capo_codedeploy/errors/invalid_compute_platform_exception.py +54 -0
  120. capo_codedeploy/errors/invalid_deployed_state_filter_exception.py +54 -0
  121. capo_codedeploy/errors/invalid_deployment_config_name_exception.py +54 -0
  122. capo_codedeploy/errors/invalid_deployment_group_name_exception.py +54 -0
  123. capo_codedeploy/errors/invalid_deployment_id_exception.py +52 -0
  124. capo_codedeploy/errors/invalid_deployment_instance_type_exception.py +54 -0
  125. capo_codedeploy/errors/invalid_deployment_status_exception.py +54 -0
  126. capo_codedeploy/errors/invalid_deployment_style_exception.py +54 -0
  127. capo_codedeploy/errors/invalid_deployment_target_id_exception.py +54 -0
  128. capo_codedeploy/errors/invalid_deployment_wait_type_exception.py +54 -0
  129. capo_codedeploy/errors/invalid_ec2_tag_combination_exception.py +54 -0
  130. capo_codedeploy/errors/invalid_ec2_tag_exception.py +52 -0
  131. capo_codedeploy/errors/invalid_ecs_service_exception.py +52 -0
  132. capo_codedeploy/errors/invalid_external_id_exception.py +52 -0
  133. capo_codedeploy/errors/invalid_file_exists_behavior_exception.py +54 -0
  134. capo_codedeploy/errors/invalid_git_hub_account_token_exception.py +54 -0
  135. capo_codedeploy/errors/invalid_git_hub_account_token_name_exception.py +54 -0
  136. capo_codedeploy/errors/invalid_iam_session_arn_exception.py +54 -0
  137. capo_codedeploy/errors/invalid_iam_user_arn_exception.py +52 -0
  138. capo_codedeploy/errors/invalid_ignore_application_stop_failures_value_exception.py +60 -0
  139. capo_codedeploy/errors/invalid_input_exception.py +52 -0
  140. capo_codedeploy/errors/invalid_instance_name_exception.py +52 -0
  141. capo_codedeploy/errors/invalid_instance_status_exception.py +54 -0
  142. capo_codedeploy/errors/invalid_instance_type_exception.py +52 -0
  143. capo_codedeploy/errors/invalid_key_prefix_filter_exception.py +54 -0
  144. capo_codedeploy/errors/invalid_lifecycle_event_hook_execution_id_exception.py +60 -0
  145. capo_codedeploy/errors/invalid_lifecycle_event_hook_execution_status_exception.py +60 -0
  146. capo_codedeploy/errors/invalid_load_balancer_info_exception.py +54 -0
  147. capo_codedeploy/errors/invalid_minimum_healthy_host_value_exception.py +54 -0
  148. capo_codedeploy/errors/invalid_next_token_exception.py +52 -0
  149. capo_codedeploy/errors/invalid_on_premises_tag_combination_exception.py +56 -0
  150. capo_codedeploy/errors/invalid_operation_exception.py +52 -0
  151. capo_codedeploy/errors/invalid_registration_status_exception.py +54 -0
  152. capo_codedeploy/errors/invalid_revision_exception.py +52 -0
  153. capo_codedeploy/errors/invalid_role_exception.py +52 -0
  154. capo_codedeploy/errors/invalid_sort_by_exception.py +52 -0
  155. capo_codedeploy/errors/invalid_sort_order_exception.py +52 -0
  156. capo_codedeploy/errors/invalid_tag_exception.py +52 -0
  157. capo_codedeploy/errors/invalid_tag_filter_exception.py +52 -0
  158. capo_codedeploy/errors/invalid_tags_to_add_exception.py +52 -0
  159. capo_codedeploy/errors/invalid_target_filter_name_exception.py +54 -0
  160. capo_codedeploy/errors/invalid_target_group_pair_exception.py +54 -0
  161. capo_codedeploy/errors/invalid_target_instances_exception.py +54 -0
  162. capo_codedeploy/errors/invalid_time_range_exception.py +52 -0
  163. capo_codedeploy/errors/invalid_traffic_routing_configuration_exception.py +58 -0
  164. capo_codedeploy/errors/invalid_trigger_config_exception.py +54 -0
  165. capo_codedeploy/errors/invalid_update_outdated_instances_only_value_exception.py +60 -0
  166. capo_codedeploy/errors/invalid_zonal_deployment_configuration_exception.py +60 -0
  167. capo_codedeploy/errors/lifecycle_event_already_completed_exception.py +54 -0
  168. capo_codedeploy/errors/lifecycle_hook_limit_exceeded_exception.py +54 -0
  169. capo_codedeploy/errors/multiple_iam_arns_provided_exception.py +54 -0
  170. capo_codedeploy/errors/operation_not_supported_exception.py +54 -0
  171. capo_codedeploy/errors/resource_arn_required_exception.py +52 -0
  172. capo_codedeploy/errors/resource_validation_exception.py +52 -0
  173. capo_codedeploy/errors/revision_does_not_exist_exception.py +54 -0
  174. capo_codedeploy/errors/revision_required_exception.py +52 -0
  175. capo_codedeploy/errors/role_required_exception.py +52 -0
  176. capo_codedeploy/errors/tag_limit_exceeded_exception.py +52 -0
  177. capo_codedeploy/errors/tag_required_exception.py +52 -0
  178. capo_codedeploy/errors/tag_set_list_limit_exceeded_exception.py +54 -0
  179. capo_codedeploy/errors/throttling_exception.py +52 -0
  180. capo_codedeploy/errors/trigger_targets_limit_exceeded_exception.py +54 -0
  181. capo_codedeploy/errors/unsupported_action_for_deployment_type_exception.py +58 -0
  182. capo_codedeploy/py.typed +0 -0
  183. capo_codedeploy/types/_prelude/blob.py +12 -0
  184. capo_codedeploy/types/_prelude/timestamp.py +17 -0
  185. capo_codedeploy/types/add_tags_to_on_premises_instances_input.py +59 -0
  186. capo_codedeploy/types/additional_deployment_status_info.py +5 -0
  187. capo_codedeploy/types/alarm.py +28 -0
  188. capo_codedeploy/types/alarm_configuration.py +51 -0
  189. capo_codedeploy/types/alarm_list.py +29 -0
  190. capo_codedeploy/types/alarm_name.py +5 -0
  191. capo_codedeploy/types/app_spec_content.py +35 -0
  192. capo_codedeploy/types/application_id.py +5 -0
  193. capo_codedeploy/types/application_info.py +90 -0
  194. capo_codedeploy/types/application_name.py +5 -0
  195. capo_codedeploy/types/application_revision_sort_by.py +18 -0
  196. capo_codedeploy/types/applications_info_list.py +33 -0
  197. capo_codedeploy/types/applications_list.py +19 -0
  198. capo_codedeploy/types/arn.py +5 -0
  199. capo_codedeploy/types/auto_rollback_configuration.py +50 -0
  200. capo_codedeploy/types/auto_rollback_event.py +18 -0
  201. capo_codedeploy/types/auto_rollback_events_list.py +35 -0
  202. capo_codedeploy/types/auto_scaling_group.py +47 -0
  203. capo_codedeploy/types/auto_scaling_group_hook.py +5 -0
  204. capo_codedeploy/types/auto_scaling_group_list.py +35 -0
  205. capo_codedeploy/types/auto_scaling_group_name.py +5 -0
  206. capo_codedeploy/types/auto_scaling_group_name_list.py +19 -0
  207. capo_codedeploy/types/batch_get_application_revisions_input.py +55 -0
  208. capo_codedeploy/types/batch_get_application_revisions_output.py +56 -0
  209. capo_codedeploy/types/batch_get_applications_input.py +45 -0
  210. capo_codedeploy/types/batch_get_applications_output.py +42 -0
  211. capo_codedeploy/types/batch_get_deployment_groups_input.py +57 -0
  212. capo_codedeploy/types/batch_get_deployment_groups_output.py +49 -0
  213. capo_codedeploy/types/batch_get_deployment_instances_input.py +53 -0
  214. capo_codedeploy/types/batch_get_deployment_instances_output.py +49 -0
  215. capo_codedeploy/types/batch_get_deployment_targets_input.py +51 -0
  216. capo_codedeploy/types/batch_get_deployment_targets_output.py +42 -0
  217. capo_codedeploy/types/batch_get_deployments_input.py +43 -0
  218. capo_codedeploy/types/batch_get_deployments_output.py +42 -0
  219. capo_codedeploy/types/batch_get_on_premises_instances_input.py +45 -0
  220. capo_codedeploy/types/batch_get_on_premises_instances_output.py +42 -0
  221. capo_codedeploy/types/blue_green_deployment_configuration.py +84 -0
  222. capo_codedeploy/types/blue_instance_termination_option.py +46 -0
  223. capo_codedeploy/types/boolean.py +5 -0
  224. capo_codedeploy/types/bundle_type.py +20 -0
  225. capo_codedeploy/types/cloud_formation_resource_type.py +5 -0
  226. capo_codedeploy/types/cloud_formation_target.py +112 -0
  227. capo_codedeploy/types/commit_id.py +5 -0
  228. capo_codedeploy/types/compute_platform.py +18 -0
  229. capo_codedeploy/types/continue_deployment_input.py +49 -0
  230. capo_codedeploy/types/create_application_input.py +67 -0
  231. capo_codedeploy/types/create_application_output.py +28 -0
  232. capo_codedeploy/types/create_deployment_config_input.py +115 -0
  233. capo_codedeploy/types/create_deployment_config_output.py +30 -0
  234. capo_codedeploy/types/create_deployment_group_input.py +353 -0
  235. capo_codedeploy/types/create_deployment_group_output.py +30 -0
  236. capo_codedeploy/types/create_deployment_input.py +178 -0
  237. capo_codedeploy/types/create_deployment_output.py +28 -0
  238. capo_codedeploy/types/delete_application_input.py +31 -0
  239. capo_codedeploy/types/delete_deployment_config_input.py +35 -0
  240. capo_codedeploy/types/delete_deployment_group_input.py +45 -0
  241. capo_codedeploy/types/delete_deployment_group_output.py +42 -0
  242. capo_codedeploy/types/delete_git_hub_account_token_input.py +30 -0
  243. capo_codedeploy/types/delete_git_hub_account_token_output.py +30 -0
  244. capo_codedeploy/types/delete_resources_by_external_id_input.py +28 -0
  245. capo_codedeploy/types/delete_resources_by_external_id_output.py +18 -0
  246. capo_codedeploy/types/deployment_config_id.py +5 -0
  247. capo_codedeploy/types/deployment_config_info.py +134 -0
  248. capo_codedeploy/types/deployment_config_name.py +5 -0
  249. capo_codedeploy/types/deployment_configs_list.py +19 -0
  250. capo_codedeploy/types/deployment_creator.py +23 -0
  251. capo_codedeploy/types/deployment_group_id.py +5 -0
  252. capo_codedeploy/types/deployment_group_info.py +420 -0
  253. capo_codedeploy/types/deployment_group_info_list.py +35 -0
  254. capo_codedeploy/types/deployment_group_name.py +5 -0
  255. capo_codedeploy/types/deployment_groups_list.py +19 -0
  256. capo_codedeploy/types/deployment_id.py +5 -0
  257. capo_codedeploy/types/deployment_info.py +499 -0
  258. capo_codedeploy/types/deployment_option.py +17 -0
  259. capo_codedeploy/types/deployment_overview.py +64 -0
  260. capo_codedeploy/types/deployment_ready_action.py +17 -0
  261. capo_codedeploy/types/deployment_ready_option.py +50 -0
  262. capo_codedeploy/types/deployment_status.py +23 -0
  263. capo_codedeploy/types/deployment_status_list.py +33 -0
  264. capo_codedeploy/types/deployment_status_message_list.py +19 -0
  265. capo_codedeploy/types/deployment_style.py +61 -0
  266. capo_codedeploy/types/deployment_target.py +115 -0
  267. capo_codedeploy/types/deployment_target_list.py +33 -0
  268. capo_codedeploy/types/deployment_target_type.py +19 -0
  269. capo_codedeploy/types/deployment_type.py +17 -0
  270. capo_codedeploy/types/deployment_wait_type.py +17 -0
  271. capo_codedeploy/types/deployments_info_list.py +31 -0
  272. capo_codedeploy/types/deployments_list.py +17 -0
  273. capo_codedeploy/types/deregister_on_premises_instance_input.py +33 -0
  274. capo_codedeploy/types/description.py +5 -0
  275. capo_codedeploy/types/diagnostics.py +63 -0
  276. capo_codedeploy/types/duration.py +5 -0
  277. capo_codedeploy/types/e_tag.py +5 -0
  278. capo_codedeploy/types/ec2_tag_filter.py +52 -0
  279. capo_codedeploy/types/ec2_tag_filter_list.py +29 -0
  280. capo_codedeploy/types/ec2_tag_filter_type.py +18 -0
  281. capo_codedeploy/types/ec2_tag_set.py +42 -0
  282. capo_codedeploy/types/ec2_tag_set_list.py +35 -0
  283. capo_codedeploy/types/ecs_cluster_name.py +5 -0
  284. capo_codedeploy/types/ecs_service.py +35 -0
  285. capo_codedeploy/types/ecs_service_list.py +29 -0
  286. capo_codedeploy/types/ecs_service_name.py +5 -0
  287. capo_codedeploy/types/ecs_target.py +114 -0
  288. capo_codedeploy/types/ecs_task_set.py +111 -0
  289. capo_codedeploy/types/ecs_task_set_count.py +5 -0
  290. capo_codedeploy/types/ecs_task_set_identifier.py +5 -0
  291. capo_codedeploy/types/ecs_task_set_list.py +29 -0
  292. capo_codedeploy/types/ecs_task_set_status.py +5 -0
  293. capo_codedeploy/types/elb_info.py +28 -0
  294. capo_codedeploy/types/elb_info_list.py +29 -0
  295. capo_codedeploy/types/elb_name.py +5 -0
  296. capo_codedeploy/types/error_code.py +49 -0
  297. capo_codedeploy/types/error_information.py +43 -0
  298. capo_codedeploy/types/error_message.py +5 -0
  299. capo_codedeploy/types/external_id.py +5 -0
  300. capo_codedeploy/types/file_exists_behavior.py +18 -0
  301. capo_codedeploy/types/filter_value.py +5 -0
  302. capo_codedeploy/types/filter_value_list.py +17 -0
  303. capo_codedeploy/types/generic_revision_info.py +96 -0
  304. capo_codedeploy/types/get_application_input.py +31 -0
  305. capo_codedeploy/types/get_application_output.py +40 -0
  306. capo_codedeploy/types/get_application_revision_input.py +51 -0
  307. capo_codedeploy/types/get_application_revision_output.py +70 -0
  308. capo_codedeploy/types/get_deployment_config_input.py +35 -0
  309. capo_codedeploy/types/get_deployment_config_output.py +42 -0
  310. capo_codedeploy/types/get_deployment_group_input.py +43 -0
  311. capo_codedeploy/types/get_deployment_group_output.py +42 -0
  312. capo_codedeploy/types/get_deployment_input.py +31 -0
  313. capo_codedeploy/types/get_deployment_instance_input.py +39 -0
  314. capo_codedeploy/types/get_deployment_instance_output.py +42 -0
  315. capo_codedeploy/types/get_deployment_output.py +40 -0
  316. capo_codedeploy/types/get_deployment_target_input.py +39 -0
  317. capo_codedeploy/types/get_deployment_target_output.py +42 -0
  318. capo_codedeploy/types/get_on_premises_instance_input.py +31 -0
  319. capo_codedeploy/types/get_on_premises_instance_output.py +40 -0
  320. capo_codedeploy/types/git_hub_account_token_name.py +5 -0
  321. capo_codedeploy/types/git_hub_account_token_name_list.py +19 -0
  322. capo_codedeploy/types/git_hub_location.py +35 -0
  323. capo_codedeploy/types/green_fleet_provisioning_action.py +17 -0
  324. capo_codedeploy/types/green_fleet_provisioning_option.py +42 -0
  325. capo_codedeploy/types/iam_session_arn.py +5 -0
  326. capo_codedeploy/types/iam_user_arn.py +5 -0
  327. capo_codedeploy/types/instance_action.py +17 -0
  328. capo_codedeploy/types/instance_arn.py +5 -0
  329. capo_codedeploy/types/instance_count.py +5 -0
  330. capo_codedeploy/types/instance_id.py +5 -0
  331. capo_codedeploy/types/instance_info.py +95 -0
  332. capo_codedeploy/types/instance_info_list.py +29 -0
  333. capo_codedeploy/types/instance_name.py +5 -0
  334. capo_codedeploy/types/instance_name_list.py +17 -0
  335. capo_codedeploy/types/instance_status.py +22 -0
  336. capo_codedeploy/types/instance_status_list.py +31 -0
  337. capo_codedeploy/types/instance_summary.py +107 -0
  338. capo_codedeploy/types/instance_summary_list.py +33 -0
  339. capo_codedeploy/types/instance_target.py +112 -0
  340. capo_codedeploy/types/instance_type.py +17 -0
  341. capo_codedeploy/types/instance_type_list.py +29 -0
  342. capo_codedeploy/types/instances_list.py +17 -0
  343. capo_codedeploy/types/key.py +5 -0
  344. capo_codedeploy/types/lambda_function_alias.py +5 -0
  345. capo_codedeploy/types/lambda_function_info.py +69 -0
  346. capo_codedeploy/types/lambda_function_name.py +5 -0
  347. capo_codedeploy/types/lambda_target.py +114 -0
  348. capo_codedeploy/types/last_deployment_info.py +74 -0
  349. capo_codedeploy/types/lifecycle_error_code.py +21 -0
  350. capo_codedeploy/types/lifecycle_event.py +95 -0
  351. capo_codedeploy/types/lifecycle_event_hook_execution_id.py +5 -0
  352. capo_codedeploy/types/lifecycle_event_list.py +31 -0
  353. capo_codedeploy/types/lifecycle_event_name.py +5 -0
  354. capo_codedeploy/types/lifecycle_event_status.py +21 -0
  355. capo_codedeploy/types/lifecycle_message.py +5 -0
  356. capo_codedeploy/types/list_application_revisions_input.py +111 -0
  357. capo_codedeploy/types/list_application_revisions_output.py +49 -0
  358. capo_codedeploy/types/list_applications_input.py +28 -0
  359. capo_codedeploy/types/list_applications_output.py +49 -0
  360. capo_codedeploy/types/list_deployment_configs_input.py +28 -0
  361. capo_codedeploy/types/list_deployment_configs_output.py +49 -0
  362. capo_codedeploy/types/list_deployment_groups_input.py +40 -0
  363. capo_codedeploy/types/list_deployment_groups_output.py +58 -0
  364. capo_codedeploy/types/list_deployment_instances_input.py +82 -0
  365. capo_codedeploy/types/list_deployment_instances_output.py +47 -0
  366. capo_codedeploy/types/list_deployment_targets_input.py +57 -0
  367. capo_codedeploy/types/list_deployment_targets_output.py +45 -0
  368. capo_codedeploy/types/list_deployments_input.py +93 -0
  369. capo_codedeploy/types/list_deployments_output.py +47 -0
  370. capo_codedeploy/types/list_git_hub_account_token_names_input.py +28 -0
  371. capo_codedeploy/types/list_git_hub_account_token_names_output.py +49 -0
  372. capo_codedeploy/types/list_on_premises_instances_input.py +68 -0
  373. capo_codedeploy/types/list_on_premises_instances_output.py +49 -0
  374. capo_codedeploy/types/list_state_filter_action.py +18 -0
  375. capo_codedeploy/types/list_tags_for_resource_input.py +38 -0
  376. capo_codedeploy/types/list_tags_for_resource_output.py +43 -0
  377. capo_codedeploy/types/listener_arn.py +5 -0
  378. capo_codedeploy/types/listener_arn_list.py +17 -0
  379. capo_codedeploy/types/load_balancer_info.py +80 -0
  380. capo_codedeploy/types/log_tail.py +5 -0
  381. capo_codedeploy/types/message.py +5 -0
  382. capo_codedeploy/types/minimum_healthy_hosts.py +50 -0
  383. capo_codedeploy/types/minimum_healthy_hosts_per_zone.py +50 -0
  384. capo_codedeploy/types/minimum_healthy_hosts_per_zone_type.py +17 -0
  385. capo_codedeploy/types/minimum_healthy_hosts_per_zone_value.py +5 -0
  386. capo_codedeploy/types/minimum_healthy_hosts_type.py +17 -0
  387. capo_codedeploy/types/minimum_healthy_hosts_value.py +5 -0
  388. capo_codedeploy/types/next_token.py +5 -0
  389. capo_codedeploy/types/nullable_boolean.py +5 -0
  390. capo_codedeploy/types/on_premises_tag_set.py +42 -0
  391. capo_codedeploy/types/on_premises_tag_set_list.py +31 -0
  392. capo_codedeploy/types/outdated_instances_strategy.py +17 -0
  393. capo_codedeploy/types/percentage.py +5 -0
  394. capo_codedeploy/types/put_lifecycle_event_hook_execution_status_input.py +60 -0
  395. capo_codedeploy/types/put_lifecycle_event_hook_execution_status_output.py +32 -0
  396. capo_codedeploy/types/raw_string.py +35 -0
  397. capo_codedeploy/types/raw_string_content.py +5 -0
  398. capo_codedeploy/types/raw_string_sha256.py +5 -0
  399. capo_codedeploy/types/register_application_revision_input.py +58 -0
  400. capo_codedeploy/types/register_on_premises_instance_input.py +47 -0
  401. capo_codedeploy/types/registration_status.py +17 -0
  402. capo_codedeploy/types/related_deployments.py +55 -0
  403. capo_codedeploy/types/remove_tags_from_on_premises_instances_input.py +61 -0
  404. capo_codedeploy/types/repository.py +5 -0
  405. capo_codedeploy/types/revision_info.py +63 -0
  406. capo_codedeploy/types/revision_info_list.py +29 -0
  407. capo_codedeploy/types/revision_location.py +114 -0
  408. capo_codedeploy/types/revision_location_list.py +33 -0
  409. capo_codedeploy/types/revision_location_type.py +19 -0
  410. capo_codedeploy/types/role.py +5 -0
  411. capo_codedeploy/types/rollback_info.py +49 -0
  412. capo_codedeploy/types/s3_bucket.py +5 -0
  413. capo_codedeploy/types/s3_key.py +5 -0
  414. capo_codedeploy/types/s3_location.py +64 -0
  415. capo_codedeploy/types/script_name.py +5 -0
  416. capo_codedeploy/types/skip_wait_time_for_instance_termination_input.py +28 -0
  417. capo_codedeploy/types/sort_order.py +17 -0
  418. capo_codedeploy/types/stop_deployment_input.py +40 -0
  419. capo_codedeploy/types/stop_deployment_output.py +43 -0
  420. capo_codedeploy/types/stop_status.py +17 -0
  421. capo_codedeploy/types/tag.py +35 -0
  422. capo_codedeploy/types/tag_filter.py +50 -0
  423. capo_codedeploy/types/tag_filter_list.py +29 -0
  424. capo_codedeploy/types/tag_filter_type.py +18 -0
  425. capo_codedeploy/types/tag_key_list.py +17 -0
  426. capo_codedeploy/types/tag_list.py +29 -0
  427. capo_codedeploy/types/tag_resource_input.py +45 -0
  428. capo_codedeploy/types/tag_resource_output.py +18 -0
  429. capo_codedeploy/types/target_arn.py +5 -0
  430. capo_codedeploy/types/target_filter_name.py +17 -0
  431. capo_codedeploy/types/target_filters.py +40 -0
  432. capo_codedeploy/types/target_group_info.py +28 -0
  433. capo_codedeploy/types/target_group_info_list.py +33 -0
  434. capo_codedeploy/types/target_group_name.py +5 -0
  435. capo_codedeploy/types/target_group_pair_info.py +79 -0
  436. capo_codedeploy/types/target_group_pair_info_list.py +35 -0
  437. capo_codedeploy/types/target_id.py +5 -0
  438. capo_codedeploy/types/target_id_list.py +17 -0
  439. capo_codedeploy/types/target_instances.py +78 -0
  440. capo_codedeploy/types/target_label.py +17 -0
  441. capo_codedeploy/types/target_status.py +22 -0
  442. capo_codedeploy/types/time.py +20 -0
  443. capo_codedeploy/types/time_based_canary.py +37 -0
  444. capo_codedeploy/types/time_based_linear.py +37 -0
  445. capo_codedeploy/types/time_range.py +50 -0
  446. capo_codedeploy/types/timestamp.py +20 -0
  447. capo_codedeploy/types/traffic_route.py +42 -0
  448. capo_codedeploy/types/traffic_routing_config.py +80 -0
  449. capo_codedeploy/types/traffic_routing_type.py +18 -0
  450. capo_codedeploy/types/traffic_weight.py +5 -0
  451. capo_codedeploy/types/trigger_config.py +58 -0
  452. capo_codedeploy/types/trigger_config_list.py +31 -0
  453. capo_codedeploy/types/trigger_event_type.py +25 -0
  454. capo_codedeploy/types/trigger_event_type_list.py +35 -0
  455. capo_codedeploy/types/trigger_name.py +5 -0
  456. capo_codedeploy/types/trigger_target_arn.py +5 -0
  457. capo_codedeploy/types/untag_resource_input.py +47 -0
  458. capo_codedeploy/types/untag_resource_output.py +18 -0
  459. capo_codedeploy/types/update_application_input.py +38 -0
  460. capo_codedeploy/types/update_deployment_group_input.py +343 -0
  461. capo_codedeploy/types/update_deployment_group_output.py +42 -0
  462. capo_codedeploy/types/value.py +5 -0
  463. capo_codedeploy/types/version.py +5 -0
  464. capo_codedeploy/types/version_id.py +5 -0
  465. capo_codedeploy/types/wait_time_in_mins.py +5 -0
  466. capo_codedeploy/types/wait_time_in_seconds.py +5 -0
  467. capo_codedeploy/types/zonal_config.py +63 -0
  468. capo_codedeploy-0.1.0.dist-info/METADATA +102 -0
  469. capo_codedeploy-0.1.0.dist-info/RECORD +472 -0
  470. capo_codedeploy-0.1.0.dist-info/WHEEL +5 -0
  471. capo_codedeploy-0.1.0.dist-info/licenses/LICENSE +21 -0
  472. capo_codedeploy-0.1.0.dist-info/top_level.txt +1 -0
@@ -0,0 +1,3278 @@
1
+ """Generated from Smithy shape ``com.amazonaws.codedeploy#CodeDeploy_20141006``."""
2
+
3
+ import warnings
4
+ from collections.abc import AsyncIterator
5
+ from typing import TYPE_CHECKING, Any, Iterable, Optional
6
+
7
+ from typing_extensions import Self, TypedDict
8
+ from zapros import AsyncBaseHandler, AsyncClient
9
+
10
+ import capo_codedeploy._auth._signers
11
+ import capo_codedeploy._auth._sigv4
12
+ from capo_codedeploy._auth._identity import Credentials
13
+ from capo_codedeploy._auth._providers import (
14
+ CredentialsProvider,
15
+ IdentityProvider,
16
+ StaticAwsCredentialsProvider,
17
+ default_aws_credentials_chain,
18
+ )
19
+ from capo_codedeploy._auth._zapros_handler import AuthMiddleware
20
+ from capo_codedeploy._pagination import resolve_path as _resolve_path
21
+ from capo_codedeploy._services._aws_config import aaws_config
22
+ from capo_codedeploy._services._pipeline import (
23
+ AsyncInterceptor,
24
+ AsyncOperationOptions,
25
+ AsyncOperationRequest,
26
+ AsyncOperationResponse,
27
+ aexecute_pipeline,
28
+ aretry,
29
+ )
30
+
31
+ if TYPE_CHECKING:
32
+ import capo_codedeploy.types.add_tags_to_on_premises_instances_input
33
+ import capo_codedeploy.types.alarm_configuration
34
+ import capo_codedeploy.types.application_name
35
+ import capo_codedeploy.types.application_revision_sort_by
36
+ import capo_codedeploy.types.applications_list
37
+ import capo_codedeploy.types.arn
38
+ import capo_codedeploy.types.auto_rollback_configuration
39
+ import capo_codedeploy.types.auto_scaling_group_name_list
40
+ import capo_codedeploy.types.batch_get_application_revisions_input
41
+ import capo_codedeploy.types.batch_get_application_revisions_output
42
+ import capo_codedeploy.types.batch_get_applications_input
43
+ import capo_codedeploy.types.batch_get_applications_output
44
+ import capo_codedeploy.types.batch_get_deployment_groups_input
45
+ import capo_codedeploy.types.batch_get_deployment_groups_output
46
+ import capo_codedeploy.types.batch_get_deployment_instances_input
47
+ import capo_codedeploy.types.batch_get_deployment_instances_output
48
+ import capo_codedeploy.types.batch_get_deployment_targets_input
49
+ import capo_codedeploy.types.batch_get_deployment_targets_output
50
+ import capo_codedeploy.types.batch_get_deployments_input
51
+ import capo_codedeploy.types.batch_get_deployments_output
52
+ import capo_codedeploy.types.batch_get_on_premises_instances_input
53
+ import capo_codedeploy.types.batch_get_on_premises_instances_output
54
+ import capo_codedeploy.types.blue_green_deployment_configuration
55
+ import capo_codedeploy.types.boolean
56
+ import capo_codedeploy.types.compute_platform
57
+ import capo_codedeploy.types.continue_deployment_input
58
+ import capo_codedeploy.types.create_application_input
59
+ import capo_codedeploy.types.create_application_output
60
+ import capo_codedeploy.types.create_deployment_config_input
61
+ import capo_codedeploy.types.create_deployment_config_output
62
+ import capo_codedeploy.types.create_deployment_group_input
63
+ import capo_codedeploy.types.create_deployment_group_output
64
+ import capo_codedeploy.types.create_deployment_input
65
+ import capo_codedeploy.types.create_deployment_output
66
+ import capo_codedeploy.types.delete_application_input
67
+ import capo_codedeploy.types.delete_deployment_config_input
68
+ import capo_codedeploy.types.delete_deployment_group_input
69
+ import capo_codedeploy.types.delete_deployment_group_output
70
+ import capo_codedeploy.types.delete_git_hub_account_token_input
71
+ import capo_codedeploy.types.delete_git_hub_account_token_output
72
+ import capo_codedeploy.types.delete_resources_by_external_id_input
73
+ import capo_codedeploy.types.delete_resources_by_external_id_output
74
+ import capo_codedeploy.types.deployment_config_name
75
+ import capo_codedeploy.types.deployment_group_name
76
+ import capo_codedeploy.types.deployment_groups_list
77
+ import capo_codedeploy.types.deployment_id
78
+ import capo_codedeploy.types.deployment_status_list
79
+ import capo_codedeploy.types.deployment_style
80
+ import capo_codedeploy.types.deployment_wait_type
81
+ import capo_codedeploy.types.deployments_list
82
+ import capo_codedeploy.types.deregister_on_premises_instance_input
83
+ import capo_codedeploy.types.description
84
+ import capo_codedeploy.types.ec2_tag_filter_list
85
+ import capo_codedeploy.types.ec2_tag_set
86
+ import capo_codedeploy.types.ecs_service_list
87
+ import capo_codedeploy.types.external_id
88
+ import capo_codedeploy.types.file_exists_behavior
89
+ import capo_codedeploy.types.get_application_input
90
+ import capo_codedeploy.types.get_application_output
91
+ import capo_codedeploy.types.get_application_revision_input
92
+ import capo_codedeploy.types.get_application_revision_output
93
+ import capo_codedeploy.types.get_deployment_config_input
94
+ import capo_codedeploy.types.get_deployment_config_output
95
+ import capo_codedeploy.types.get_deployment_group_input
96
+ import capo_codedeploy.types.get_deployment_group_output
97
+ import capo_codedeploy.types.get_deployment_input
98
+ import capo_codedeploy.types.get_deployment_instance_input
99
+ import capo_codedeploy.types.get_deployment_instance_output
100
+ import capo_codedeploy.types.get_deployment_output
101
+ import capo_codedeploy.types.get_deployment_target_input
102
+ import capo_codedeploy.types.get_deployment_target_output
103
+ import capo_codedeploy.types.get_on_premises_instance_input
104
+ import capo_codedeploy.types.get_on_premises_instance_output
105
+ import capo_codedeploy.types.git_hub_account_token_name
106
+ import capo_codedeploy.types.iam_session_arn
107
+ import capo_codedeploy.types.iam_user_arn
108
+ import capo_codedeploy.types.instance_id
109
+ import capo_codedeploy.types.instance_name
110
+ import capo_codedeploy.types.instance_name_list
111
+ import capo_codedeploy.types.instance_status_list
112
+ import capo_codedeploy.types.instance_type_list
113
+ import capo_codedeploy.types.instances_list
114
+ import capo_codedeploy.types.lifecycle_event_hook_execution_id
115
+ import capo_codedeploy.types.lifecycle_event_status
116
+ import capo_codedeploy.types.list_application_revisions_input
117
+ import capo_codedeploy.types.list_application_revisions_output
118
+ import capo_codedeploy.types.list_applications_input
119
+ import capo_codedeploy.types.list_applications_output
120
+ import capo_codedeploy.types.list_deployment_configs_input
121
+ import capo_codedeploy.types.list_deployment_configs_output
122
+ import capo_codedeploy.types.list_deployment_groups_input
123
+ import capo_codedeploy.types.list_deployment_groups_output
124
+ import capo_codedeploy.types.list_deployment_instances_input
125
+ import capo_codedeploy.types.list_deployment_instances_output
126
+ import capo_codedeploy.types.list_deployment_targets_input
127
+ import capo_codedeploy.types.list_deployment_targets_output
128
+ import capo_codedeploy.types.list_deployments_input
129
+ import capo_codedeploy.types.list_deployments_output
130
+ import capo_codedeploy.types.list_git_hub_account_token_names_input
131
+ import capo_codedeploy.types.list_git_hub_account_token_names_output
132
+ import capo_codedeploy.types.list_on_premises_instances_input
133
+ import capo_codedeploy.types.list_on_premises_instances_output
134
+ import capo_codedeploy.types.list_state_filter_action
135
+ import capo_codedeploy.types.list_tags_for_resource_input
136
+ import capo_codedeploy.types.list_tags_for_resource_output
137
+ import capo_codedeploy.types.load_balancer_info
138
+ import capo_codedeploy.types.minimum_healthy_hosts
139
+ import capo_codedeploy.types.next_token
140
+ import capo_codedeploy.types.nullable_boolean
141
+ import capo_codedeploy.types.on_premises_tag_set
142
+ import capo_codedeploy.types.outdated_instances_strategy
143
+ import capo_codedeploy.types.put_lifecycle_event_hook_execution_status_input
144
+ import capo_codedeploy.types.put_lifecycle_event_hook_execution_status_output
145
+ import capo_codedeploy.types.register_application_revision_input
146
+ import capo_codedeploy.types.register_on_premises_instance_input
147
+ import capo_codedeploy.types.registration_status
148
+ import capo_codedeploy.types.remove_tags_from_on_premises_instances_input
149
+ import capo_codedeploy.types.revision_location
150
+ import capo_codedeploy.types.revision_location_list
151
+ import capo_codedeploy.types.role
152
+ import capo_codedeploy.types.s3_bucket
153
+ import capo_codedeploy.types.s3_key
154
+ import capo_codedeploy.types.skip_wait_time_for_instance_termination_input
155
+ import capo_codedeploy.types.sort_order
156
+ import capo_codedeploy.types.stop_deployment_input
157
+ import capo_codedeploy.types.stop_deployment_output
158
+ import capo_codedeploy.types.tag_filter_list
159
+ import capo_codedeploy.types.tag_key_list
160
+ import capo_codedeploy.types.tag_list
161
+ import capo_codedeploy.types.tag_resource_input
162
+ import capo_codedeploy.types.tag_resource_output
163
+ import capo_codedeploy.types.target_filters
164
+ import capo_codedeploy.types.target_id
165
+ import capo_codedeploy.types.target_id_list
166
+ import capo_codedeploy.types.target_instances
167
+ import capo_codedeploy.types.time_range
168
+ import capo_codedeploy.types.traffic_routing_config
169
+ import capo_codedeploy.types.trigger_config_list
170
+ import capo_codedeploy.types.untag_resource_input
171
+ import capo_codedeploy.types.untag_resource_output
172
+ import capo_codedeploy.types.update_application_input
173
+ import capo_codedeploy.types.update_deployment_group_input
174
+ import capo_codedeploy.types.update_deployment_group_output
175
+ import capo_codedeploy.types.zonal_config
176
+
177
+
178
+ class AsyncCodeDeployClientConfig(TypedDict, total=False, closed=True):
179
+ operation_interceptors: Iterable[AsyncInterceptor[Any, Any]]
180
+ retry_max_attempts: int | None
181
+ region: str | None
182
+ use_dual_stack: bool | None
183
+ use_fips: bool | None
184
+ endpoint: str | None
185
+ credentials_provider: IdentityProvider[Credentials] | None
186
+
187
+
188
+ class AsyncCodeDeployClient:
189
+ """A client for the ``CodeDeploy`` service.
190
+
191
+ Args:
192
+ http_handler: HTTP handler for sending requests. If not provided, creates a default handler.
193
+ operation_interceptors: Interceptors that wrap every operation call. If not provided, defaults to an empty list.
194
+ retry_max_attempts: Maximum number of times to retry a failed operation. Defaults to 3.
195
+ region: The value of the ``AWS::Region`` endpoint parameter.
196
+ use_dual_stack: The value of the ``AWS::UseDualStack`` endpoint parameter.
197
+ use_fips: The value of the ``AWS::UseFIPS`` endpoint parameter.
198
+ endpoint: The value of the ``SDK::Endpoint`` endpoint parameter.
199
+ credentials: AWS credentials for request signing.
200
+ credentials_provider: Provider that resolves AWS credentials. Takes precedence over ``credentials``.
201
+ """
202
+
203
+ def __init__(
204
+ self,
205
+ http_handler: AsyncBaseHandler | None = None,
206
+ operation_interceptors: Iterable[AsyncInterceptor[Any, Any]] | None = None,
207
+ retry_max_attempts: int | None = None,
208
+ region: str | None = None,
209
+ use_dual_stack: bool | None = None,
210
+ use_fips: bool | None = None,
211
+ endpoint: str | None = None,
212
+ credentials: Credentials | None = None,
213
+ credentials_provider: CredentialsProvider | None = None,
214
+ ):
215
+ self._client = AsyncClient(http_handler).wrap_with_middleware(
216
+ lambda next: AuthMiddleware(next)
217
+ )
218
+ if credentials is not None and credentials_provider is not None:
219
+ warnings.warn(
220
+ "Both credentials and credentials_provider given; provider takes precedence"
221
+ )
222
+ resolved_credentials_provider: IdentityProvider[Credentials] | None = (
223
+ credentials_provider
224
+ )
225
+ if resolved_credentials_provider is None and credentials is not None:
226
+ resolved_credentials_provider = StaticAwsCredentialsProvider(credentials)
227
+ if resolved_credentials_provider is None and credentials is None:
228
+ resolved_credentials_provider = default_aws_credentials_chain(
229
+ AsyncClient(http_handler)
230
+ )
231
+ self._config = AsyncCodeDeployClientConfig(
232
+ {
233
+ "operation_interceptors": operation_interceptors or [],
234
+ "retry_max_attempts": retry_max_attempts,
235
+ "region": region,
236
+ "use_dual_stack": use_dual_stack,
237
+ "use_fips": use_fips,
238
+ "endpoint": endpoint,
239
+ "credentials_provider": resolved_credentials_provider,
240
+ }
241
+ )
242
+
243
+ def operation_options(
244
+ self, config_overrides: Optional[AsyncCodeDeployClientConfig] = None
245
+ ) -> tuple[Iterable[AsyncInterceptor[Any, Any]], AsyncOperationOptions]:
246
+ overrides: AsyncCodeDeployClientConfig = config_overrides or {}
247
+ interceptors_: list[AsyncInterceptor[Any, Any]] = [
248
+ *overrides.get(
249
+ "operation_interceptors", self._config.get("operation_interceptors", [])
250
+ ),
251
+ aaws_config(),
252
+ aretry(),
253
+ ]
254
+ options_: AsyncOperationOptions = AsyncOperationOptions(
255
+ client=self._client,
256
+ retry_max_attempts=overrides.get(
257
+ "retry_max_attempts", self._config.get("retry_max_attempts")
258
+ ),
259
+ region=overrides.get("region", self._config.get("region")),
260
+ use_dual_stack=overrides.get(
261
+ "use_dual_stack", self._config.get("use_dual_stack")
262
+ ),
263
+ use_fips=overrides.get("use_fips", self._config.get("use_fips")),
264
+ endpoint=overrides.get("endpoint", self._config.get("endpoint")),
265
+ credentials_provider=overrides.get(
266
+ "credentials_provider", self._config.get("credentials_provider")
267
+ ),
268
+ )
269
+ return interceptors_, options_
270
+
271
+ async def add_tags_to_on_premises_instances(
272
+ self,
273
+ tags: "capo_codedeploy.types.tag_list.TagList",
274
+ instance_names: "capo_codedeploy.types.instance_name_list.InstanceNameList",
275
+ *,
276
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
277
+ ) -> None:
278
+ """<p>Adds tags to on-premises instances.</p>
279
+
280
+ Args:
281
+ tags: <p>The tag key-value pairs to add to the on-premises instances.</p> <p>Keys and values are both required. Keys cannot be null or empty strings. Value-only tags are not allowed.</p>
282
+ instance_names: <p>The names of the on-premises instances to which to add tags.</p>
283
+
284
+ Raises:
285
+ capo_codedeploy.errors.instance_limit_exceeded_exception.InstanceLimitExceededException: <p>The maximum number of allowed on-premises instances in a single call was exceeded.</p>
286
+ capo_codedeploy.errors.instance_name_required_exception.InstanceNameRequiredException: <p>An on-premises instance name was not specified.</p>
287
+ capo_codedeploy.errors.instance_not_registered_exception.InstanceNotRegisteredException: <p>The specified on-premises instance is not registered.</p>
288
+ capo_codedeploy.errors.invalid_instance_name_exception.InvalidInstanceNameException: <p>The on-premises instance name was specified in an invalid format.</p>
289
+ capo_codedeploy.errors.invalid_tag_exception.InvalidTagException: <p>The tag was specified in an invalid format.</p>
290
+ capo_codedeploy.errors.tag_limit_exceeded_exception.TagLimitExceededException: <p>The maximum allowed number of tags was exceeded.</p>
291
+ capo_codedeploy.errors.tag_required_exception.TagRequiredException: <p>A tag was not specified.</p>
292
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
293
+ """
294
+
295
+ async def _handler(
296
+ req: "AsyncOperationRequest[capo_codedeploy.types.add_tags_to_on_premises_instances_input.AddTagsToOnPremisesInstancesInput]",
297
+ ) -> AsyncOperationResponse[None]:
298
+ import capo_codedeploy._operations.code_deploy_20141006.add_tags_to_on_premises_instances
299
+
300
+ (
301
+ output,
302
+ http_response,
303
+ ) = await capo_codedeploy._operations.code_deploy_20141006.add_tags_to_on_premises_instances.async_add_tags_to_on_premises_instances(
304
+ req.options, req.input
305
+ )
306
+ return AsyncOperationResponse(output=output, response=http_response)
307
+
308
+ interceptors_, options_ = self.operation_options(config_overrides)
309
+ input_: capo_codedeploy.types.add_tags_to_on_premises_instances_input.AddTagsToOnPremisesInstancesInput = {
310
+ "tags": tags,
311
+ "instance_names": instance_names,
312
+ }
313
+
314
+ response = await aexecute_pipeline(
315
+ AsyncOperationRequest(input=input_, options=options_),
316
+ handler=_handler,
317
+ interceptors=list(interceptors_),
318
+ )
319
+ await response.response.aclose()
320
+ return response.output
321
+
322
+ async def batch_get_application_revisions(
323
+ self,
324
+ application_name: "capo_codedeploy.types.application_name.ApplicationName",
325
+ revisions: "capo_codedeploy.types.revision_location_list.RevisionLocationList",
326
+ *,
327
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
328
+ ) -> "capo_codedeploy.types.batch_get_application_revisions_output.BatchGetApplicationRevisionsOutput":
329
+ """<p>Gets information about one or more application revisions. The maximum number of application revisions that can be returned is 25.</p>
330
+
331
+ Args:
332
+ application_name: <p>The name of an CodeDeploy application about which to get revision information.</p>
333
+ revisions: <p>An array of <code>RevisionLocation</code> objects that specify information to get about the application revisions, including type and location. The maximum number of <code>RevisionLocation</code> objects you can specify is 25.</p>
334
+
335
+ Raises:
336
+ capo_codedeploy.errors.application_does_not_exist_exception.ApplicationDoesNotExistException: <p>The application does not exist with the user or Amazon Web Services account.</p>
337
+ capo_codedeploy.errors.application_name_required_exception.ApplicationNameRequiredException: <p>The minimum number of required application names was not specified.</p>
338
+ capo_codedeploy.errors.batch_limit_exceeded_exception.BatchLimitExceededException: <p>The maximum number of names or IDs allowed for this request (100) was exceeded.</p>
339
+ capo_codedeploy.errors.invalid_application_name_exception.InvalidApplicationNameException: <p>The application name was specified in an invalid format.</p>
340
+ capo_codedeploy.errors.invalid_revision_exception.InvalidRevisionException: <p>The revision was specified in an invalid format.</p>
341
+ capo_codedeploy.errors.revision_required_exception.RevisionRequiredException: <p>The revision ID was not specified.</p>
342
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
343
+ """
344
+
345
+ async def _handler(
346
+ req: "AsyncOperationRequest[capo_codedeploy.types.batch_get_application_revisions_input.BatchGetApplicationRevisionsInput]",
347
+ ) -> AsyncOperationResponse[
348
+ "capo_codedeploy.types.batch_get_application_revisions_output.BatchGetApplicationRevisionsOutput"
349
+ ]:
350
+ import capo_codedeploy._operations.code_deploy_20141006.batch_get_application_revisions
351
+
352
+ (
353
+ output,
354
+ http_response,
355
+ ) = await capo_codedeploy._operations.code_deploy_20141006.batch_get_application_revisions.async_batch_get_application_revisions(
356
+ req.options, req.input
357
+ )
358
+ return AsyncOperationResponse(output=output, response=http_response)
359
+
360
+ interceptors_, options_ = self.operation_options(config_overrides)
361
+ input_: capo_codedeploy.types.batch_get_application_revisions_input.BatchGetApplicationRevisionsInput = {
362
+ "application_name": application_name,
363
+ "revisions": revisions,
364
+ }
365
+
366
+ response = await aexecute_pipeline(
367
+ AsyncOperationRequest(input=input_, options=options_),
368
+ handler=_handler,
369
+ interceptors=list(interceptors_),
370
+ )
371
+ await response.response.aclose()
372
+ return response.output
373
+
374
+ async def batch_get_applications(
375
+ self,
376
+ application_names: "capo_codedeploy.types.applications_list.ApplicationsList",
377
+ *,
378
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
379
+ ) -> (
380
+ "capo_codedeploy.types.batch_get_applications_output.BatchGetApplicationsOutput"
381
+ ):
382
+ """<p>Gets information about one or more applications. The maximum number of applications that can be returned is 100.</p>
383
+
384
+ Args:
385
+ application_names: <p>A list of application names separated by spaces. The maximum number of application names you can specify is 100.</p>
386
+
387
+ Raises:
388
+ capo_codedeploy.errors.application_does_not_exist_exception.ApplicationDoesNotExistException: <p>The application does not exist with the user or Amazon Web Services account.</p>
389
+ capo_codedeploy.errors.application_name_required_exception.ApplicationNameRequiredException: <p>The minimum number of required application names was not specified.</p>
390
+ capo_codedeploy.errors.batch_limit_exceeded_exception.BatchLimitExceededException: <p>The maximum number of names or IDs allowed for this request (100) was exceeded.</p>
391
+ capo_codedeploy.errors.invalid_application_name_exception.InvalidApplicationNameException: <p>The application name was specified in an invalid format.</p>
392
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
393
+ """
394
+
395
+ async def _handler(
396
+ req: "AsyncOperationRequest[capo_codedeploy.types.batch_get_applications_input.BatchGetApplicationsInput]",
397
+ ) -> AsyncOperationResponse[
398
+ "capo_codedeploy.types.batch_get_applications_output.BatchGetApplicationsOutput"
399
+ ]:
400
+ import capo_codedeploy._operations.code_deploy_20141006.batch_get_applications
401
+
402
+ (
403
+ output,
404
+ http_response,
405
+ ) = await capo_codedeploy._operations.code_deploy_20141006.batch_get_applications.async_batch_get_applications(
406
+ req.options, req.input
407
+ )
408
+ return AsyncOperationResponse(output=output, response=http_response)
409
+
410
+ interceptors_, options_ = self.operation_options(config_overrides)
411
+ input_: capo_codedeploy.types.batch_get_applications_input.BatchGetApplicationsInput = {
412
+ "application_names": application_names
413
+ }
414
+
415
+ response = await aexecute_pipeline(
416
+ AsyncOperationRequest(input=input_, options=options_),
417
+ handler=_handler,
418
+ interceptors=list(interceptors_),
419
+ )
420
+ await response.response.aclose()
421
+ return response.output
422
+
423
+ async def batch_get_deployment_groups(
424
+ self,
425
+ application_name: "capo_codedeploy.types.application_name.ApplicationName",
426
+ deployment_group_names: "capo_codedeploy.types.deployment_groups_list.DeploymentGroupsList",
427
+ *,
428
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
429
+ ) -> "capo_codedeploy.types.batch_get_deployment_groups_output.BatchGetDeploymentGroupsOutput":
430
+ """<p>Gets information about one or more deployment groups.</p>
431
+
432
+ Args:
433
+ application_name: <p>The name of an CodeDeploy application associated with the applicable user or Amazon Web Services account.</p>
434
+ deployment_group_names: <p>The names of the deployment groups.</p>
435
+
436
+ Raises:
437
+ capo_codedeploy.errors.application_does_not_exist_exception.ApplicationDoesNotExistException: <p>The application does not exist with the user or Amazon Web Services account.</p>
438
+ capo_codedeploy.errors.application_name_required_exception.ApplicationNameRequiredException: <p>The minimum number of required application names was not specified.</p>
439
+ capo_codedeploy.errors.batch_limit_exceeded_exception.BatchLimitExceededException: <p>The maximum number of names or IDs allowed for this request (100) was exceeded.</p>
440
+ capo_codedeploy.errors.deployment_config_does_not_exist_exception.DeploymentConfigDoesNotExistException: <p>The deployment configuration does not exist with the user or Amazon Web Services account.</p>
441
+ capo_codedeploy.errors.deployment_group_name_required_exception.DeploymentGroupNameRequiredException: <p>The deployment group name was not specified.</p>
442
+ capo_codedeploy.errors.invalid_application_name_exception.InvalidApplicationNameException: <p>The application name was specified in an invalid format.</p>
443
+ capo_codedeploy.errors.invalid_deployment_group_name_exception.InvalidDeploymentGroupNameException: <p>The deployment group name was specified in an invalid format.</p>
444
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
445
+ """
446
+
447
+ async def _handler(
448
+ req: "AsyncOperationRequest[capo_codedeploy.types.batch_get_deployment_groups_input.BatchGetDeploymentGroupsInput]",
449
+ ) -> AsyncOperationResponse[
450
+ "capo_codedeploy.types.batch_get_deployment_groups_output.BatchGetDeploymentGroupsOutput"
451
+ ]:
452
+ import capo_codedeploy._operations.code_deploy_20141006.batch_get_deployment_groups
453
+
454
+ (
455
+ output,
456
+ http_response,
457
+ ) = await capo_codedeploy._operations.code_deploy_20141006.batch_get_deployment_groups.async_batch_get_deployment_groups(
458
+ req.options, req.input
459
+ )
460
+ return AsyncOperationResponse(output=output, response=http_response)
461
+
462
+ interceptors_, options_ = self.operation_options(config_overrides)
463
+ input_: capo_codedeploy.types.batch_get_deployment_groups_input.BatchGetDeploymentGroupsInput = {
464
+ "application_name": application_name,
465
+ "deployment_group_names": deployment_group_names,
466
+ }
467
+
468
+ response = await aexecute_pipeline(
469
+ AsyncOperationRequest(input=input_, options=options_),
470
+ handler=_handler,
471
+ interceptors=list(interceptors_),
472
+ )
473
+ await response.response.aclose()
474
+ return response.output
475
+
476
+ async def batch_get_deployment_instances(
477
+ self,
478
+ deployment_id: "capo_codedeploy.types.deployment_id.DeploymentId",
479
+ instance_ids: "capo_codedeploy.types.instances_list.InstancesList",
480
+ *,
481
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
482
+ ) -> "capo_codedeploy.types.batch_get_deployment_instances_output.BatchGetDeploymentInstancesOutput":
483
+ """<note> <p> This method works, but is deprecated. Use <code>BatchGetDeploymentTargets</code> instead. </p> </note> <p> Returns an array of one or more instances associated with a deployment. This method works with EC2/On-premises and Lambda compute platforms. The newer <code>BatchGetDeploymentTargets</code> works with all compute platforms. The maximum number of instances that can be returned is 25.</p>
484
+
485
+ Args:
486
+ deployment_id: <p> The unique ID of a deployment. </p>
487
+ instance_ids: <p>The unique IDs of instances used in the deployment. The maximum number of instance IDs you can specify is 25.</p>
488
+
489
+ Raises:
490
+ capo_codedeploy.errors.batch_limit_exceeded_exception.BatchLimitExceededException: <p>The maximum number of names or IDs allowed for this request (100) was exceeded.</p>
491
+ capo_codedeploy.errors.deployment_does_not_exist_exception.DeploymentDoesNotExistException: <p>The deployment with the user or Amazon Web Services account does not exist.</p>
492
+ capo_codedeploy.errors.deployment_id_required_exception.DeploymentIdRequiredException: <p>At least one deployment ID must be specified.</p>
493
+ capo_codedeploy.errors.instance_id_required_exception.InstanceIdRequiredException: <p>The instance ID was not specified.</p>
494
+ capo_codedeploy.errors.invalid_compute_platform_exception.InvalidComputePlatformException: <p>The computePlatform is invalid. The computePlatform should be <code>Lambda</code>, <code>Server</code>, or <code>ECS</code>.</p>
495
+ capo_codedeploy.errors.invalid_deployment_id_exception.InvalidDeploymentIdException: <p>At least one of the deployment IDs was specified in an invalid format.</p>
496
+ capo_codedeploy.errors.invalid_instance_name_exception.InvalidInstanceNameException: <p>The on-premises instance name was specified in an invalid format.</p>
497
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
498
+ """
499
+
500
+ async def _handler(
501
+ req: "AsyncOperationRequest[capo_codedeploy.types.batch_get_deployment_instances_input.BatchGetDeploymentInstancesInput]",
502
+ ) -> AsyncOperationResponse[
503
+ "capo_codedeploy.types.batch_get_deployment_instances_output.BatchGetDeploymentInstancesOutput"
504
+ ]:
505
+ import capo_codedeploy._operations.code_deploy_20141006.batch_get_deployment_instances
506
+
507
+ (
508
+ output,
509
+ http_response,
510
+ ) = await capo_codedeploy._operations.code_deploy_20141006.batch_get_deployment_instances.async_batch_get_deployment_instances(
511
+ req.options, req.input
512
+ )
513
+ return AsyncOperationResponse(output=output, response=http_response)
514
+
515
+ interceptors_, options_ = self.operation_options(config_overrides)
516
+ input_: capo_codedeploy.types.batch_get_deployment_instances_input.BatchGetDeploymentInstancesInput = {
517
+ "deployment_id": deployment_id,
518
+ "instance_ids": instance_ids,
519
+ }
520
+
521
+ response = await aexecute_pipeline(
522
+ AsyncOperationRequest(input=input_, options=options_),
523
+ handler=_handler,
524
+ interceptors=list(interceptors_),
525
+ )
526
+ await response.response.aclose()
527
+ return response.output
528
+
529
+ async def batch_get_deployments(
530
+ self,
531
+ deployment_ids: "capo_codedeploy.types.deployments_list.DeploymentsList",
532
+ *,
533
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
534
+ ) -> "capo_codedeploy.types.batch_get_deployments_output.BatchGetDeploymentsOutput":
535
+ """<p>Gets information about one or more deployments. The maximum number of deployments that can be returned is 25.</p>
536
+
537
+ Args:
538
+ deployment_ids: <p> A list of deployment IDs, separated by spaces. The maximum number of deployment IDs you can specify is 25.</p>
539
+
540
+ Raises:
541
+ capo_codedeploy.errors.batch_limit_exceeded_exception.BatchLimitExceededException: <p>The maximum number of names or IDs allowed for this request (100) was exceeded.</p>
542
+ capo_codedeploy.errors.deployment_id_required_exception.DeploymentIdRequiredException: <p>At least one deployment ID must be specified.</p>
543
+ capo_codedeploy.errors.invalid_deployment_id_exception.InvalidDeploymentIdException: <p>At least one of the deployment IDs was specified in an invalid format.</p>
544
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
545
+ """
546
+
547
+ async def _handler(
548
+ req: "AsyncOperationRequest[capo_codedeploy.types.batch_get_deployments_input.BatchGetDeploymentsInput]",
549
+ ) -> AsyncOperationResponse[
550
+ "capo_codedeploy.types.batch_get_deployments_output.BatchGetDeploymentsOutput"
551
+ ]:
552
+ import capo_codedeploy._operations.code_deploy_20141006.batch_get_deployments
553
+
554
+ (
555
+ output,
556
+ http_response,
557
+ ) = await capo_codedeploy._operations.code_deploy_20141006.batch_get_deployments.async_batch_get_deployments(
558
+ req.options, req.input
559
+ )
560
+ return AsyncOperationResponse(output=output, response=http_response)
561
+
562
+ interceptors_, options_ = self.operation_options(config_overrides)
563
+ input_: capo_codedeploy.types.batch_get_deployments_input.BatchGetDeploymentsInput = {
564
+ "deployment_ids": deployment_ids
565
+ }
566
+
567
+ response = await aexecute_pipeline(
568
+ AsyncOperationRequest(input=input_, options=options_),
569
+ handler=_handler,
570
+ interceptors=list(interceptors_),
571
+ )
572
+ await response.response.aclose()
573
+ return response.output
574
+
575
+ async def batch_get_deployment_targets(
576
+ self,
577
+ deployment_id: "capo_codedeploy.types.deployment_id.DeploymentId",
578
+ target_ids: "capo_codedeploy.types.target_id_list.TargetIdList",
579
+ *,
580
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
581
+ ) -> "capo_codedeploy.types.batch_get_deployment_targets_output.BatchGetDeploymentTargetsOutput":
582
+ """<p> Returns an array of one or more targets associated with a deployment. This method works with all compute types and should be used instead of the deprecated <code>BatchGetDeploymentInstances</code>. The maximum number of targets that can be returned is 25.</p> <p> The type of targets returned depends on the deployment's compute platform or deployment method: </p> <ul> <li> <p> <b>EC2/On-premises</b>: Information about Amazon EC2 instance targets. </p> </li> <li> <p> <b>Lambda</b>: Information about Lambda functions targets. </p> </li> <li> <p> <b>Amazon ECS</b>: Information about Amazon ECS service targets. </p> </li> <li> <p> <b>CloudFormation</b>: Information about targets of blue/green deployments initiated by a CloudFormation stack update.</p> </li> </ul>
583
+
584
+ Args:
585
+ deployment_id: <p> The unique ID of a deployment. </p>
586
+ target_ids: <p> The unique IDs of the deployment targets. The compute platform of the deployment determines the type of the targets and their formats. The maximum number of deployment target IDs you can specify is 25.</p> <ul> <li> <p> For deployments that use the EC2/On-premises compute platform, the target IDs are Amazon EC2 or on-premises instances IDs, and their target type is <code>instanceTarget</code>. </p> </li> <li> <p> For deployments that use the Lambda compute platform, the target IDs are the names of Lambda functions, and their target type is <code>instanceTarget</code>. </p> </li> <li> <p> For deployments that use the Amazon ECS compute platform, the target IDs are pairs of Amazon ECS clusters and services specified using the format <code><clustername>:<servicename></code>. Their target type is <code>ecsTarget</code>. </p> </li> <li> <p> For deployments that are deployed with CloudFormation, the target IDs are CloudFormation stack IDs. Their target type is <code>cloudFormationTarget</code>. </p> </li> </ul>
587
+
588
+ Raises:
589
+ capo_codedeploy.errors.deployment_does_not_exist_exception.DeploymentDoesNotExistException: <p>The deployment with the user or Amazon Web Services account does not exist.</p>
590
+ capo_codedeploy.errors.deployment_id_required_exception.DeploymentIdRequiredException: <p>At least one deployment ID must be specified.</p>
591
+ capo_codedeploy.errors.deployment_not_started_exception.DeploymentNotStartedException: <p>The specified deployment has not started.</p>
592
+ capo_codedeploy.errors.deployment_target_does_not_exist_exception.DeploymentTargetDoesNotExistException: <p> The provided target ID does not belong to the attempted deployment. </p>
593
+ capo_codedeploy.errors.deployment_target_id_required_exception.DeploymentTargetIdRequiredException: <p> A deployment target ID was not provided. </p>
594
+ capo_codedeploy.errors.deployment_target_list_size_exceeded_exception.DeploymentTargetListSizeExceededException: <p> The maximum number of targets that can be associated with an Amazon ECS or Lambda deployment was exceeded. The target list of both types of deployments must have exactly one item. This exception does not apply to EC2/On-premises deployments. </p>
595
+ capo_codedeploy.errors.instance_does_not_exist_exception.InstanceDoesNotExistException: <p>The specified instance does not exist in the deployment group.</p>
596
+ capo_codedeploy.errors.invalid_deployment_id_exception.InvalidDeploymentIdException: <p>At least one of the deployment IDs was specified in an invalid format.</p>
597
+ capo_codedeploy.errors.invalid_deployment_target_id_exception.InvalidDeploymentTargetIdException: <p> The target ID provided was not valid. </p>
598
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
599
+ """
600
+
601
+ async def _handler(
602
+ req: "AsyncOperationRequest[capo_codedeploy.types.batch_get_deployment_targets_input.BatchGetDeploymentTargetsInput]",
603
+ ) -> AsyncOperationResponse[
604
+ "capo_codedeploy.types.batch_get_deployment_targets_output.BatchGetDeploymentTargetsOutput"
605
+ ]:
606
+ import capo_codedeploy._operations.code_deploy_20141006.batch_get_deployment_targets
607
+
608
+ (
609
+ output,
610
+ http_response,
611
+ ) = await capo_codedeploy._operations.code_deploy_20141006.batch_get_deployment_targets.async_batch_get_deployment_targets(
612
+ req.options, req.input
613
+ )
614
+ return AsyncOperationResponse(output=output, response=http_response)
615
+
616
+ interceptors_, options_ = self.operation_options(config_overrides)
617
+ input_: capo_codedeploy.types.batch_get_deployment_targets_input.BatchGetDeploymentTargetsInput = {
618
+ "deployment_id": deployment_id,
619
+ "target_ids": target_ids,
620
+ }
621
+
622
+ response = await aexecute_pipeline(
623
+ AsyncOperationRequest(input=input_, options=options_),
624
+ handler=_handler,
625
+ interceptors=list(interceptors_),
626
+ )
627
+ await response.response.aclose()
628
+ return response.output
629
+
630
+ async def batch_get_on_premises_instances(
631
+ self,
632
+ instance_names: "capo_codedeploy.types.instance_name_list.InstanceNameList",
633
+ *,
634
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
635
+ ) -> "capo_codedeploy.types.batch_get_on_premises_instances_output.BatchGetOnPremisesInstancesOutput":
636
+ """<p>Gets information about one or more on-premises instances. The maximum number of on-premises instances that can be returned is 25.</p>
637
+
638
+ Args:
639
+ instance_names: <p>The names of the on-premises instances about which to get information. The maximum number of instance names you can specify is 25.</p>
640
+
641
+ Raises:
642
+ capo_codedeploy.errors.batch_limit_exceeded_exception.BatchLimitExceededException: <p>The maximum number of names or IDs allowed for this request (100) was exceeded.</p>
643
+ capo_codedeploy.errors.instance_name_required_exception.InstanceNameRequiredException: <p>An on-premises instance name was not specified.</p>
644
+ capo_codedeploy.errors.invalid_instance_name_exception.InvalidInstanceNameException: <p>The on-premises instance name was specified in an invalid format.</p>
645
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
646
+ """
647
+
648
+ async def _handler(
649
+ req: "AsyncOperationRequest[capo_codedeploy.types.batch_get_on_premises_instances_input.BatchGetOnPremisesInstancesInput]",
650
+ ) -> AsyncOperationResponse[
651
+ "capo_codedeploy.types.batch_get_on_premises_instances_output.BatchGetOnPremisesInstancesOutput"
652
+ ]:
653
+ import capo_codedeploy._operations.code_deploy_20141006.batch_get_on_premises_instances
654
+
655
+ (
656
+ output,
657
+ http_response,
658
+ ) = await capo_codedeploy._operations.code_deploy_20141006.batch_get_on_premises_instances.async_batch_get_on_premises_instances(
659
+ req.options, req.input
660
+ )
661
+ return AsyncOperationResponse(output=output, response=http_response)
662
+
663
+ interceptors_, options_ = self.operation_options(config_overrides)
664
+ input_: capo_codedeploy.types.batch_get_on_premises_instances_input.BatchGetOnPremisesInstancesInput = {
665
+ "instance_names": instance_names
666
+ }
667
+
668
+ response = await aexecute_pipeline(
669
+ AsyncOperationRequest(input=input_, options=options_),
670
+ handler=_handler,
671
+ interceptors=list(interceptors_),
672
+ )
673
+ await response.response.aclose()
674
+ return response.output
675
+
676
+ async def continue_deployment(
677
+ self,
678
+ *,
679
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
680
+ deployment_id: Optional[
681
+ "capo_codedeploy.types.deployment_id.DeploymentId"
682
+ ] = None,
683
+ deployment_wait_type: Optional[
684
+ "capo_codedeploy.types.deployment_wait_type.DeploymentWaitType"
685
+ ] = None,
686
+ ) -> None:
687
+ """<p>For a blue/green deployment, starts the process of rerouting traffic from instances in the original environment to instances in the replacement environment without waiting for a specified wait time to elapse. (Traffic rerouting, which is achieved by registering instances in the replacement environment with the load balancer, can start as soon as all instances have a status of Ready.) </p>
688
+
689
+ Args:
690
+ deployment_id: <p> The unique ID of a blue/green deployment for which you want to start rerouting traffic to the replacement environment. </p>
691
+ deployment_wait_type: <p> The status of the deployment's waiting period. <code>READY_WAIT</code> indicates that the deployment is ready to start shifting traffic. <code>TERMINATION_WAIT</code> indicates that the traffic is shifted, but the original target is not terminated. </p>
692
+
693
+ Raises:
694
+ capo_codedeploy.errors.deployment_already_completed_exception.DeploymentAlreadyCompletedException: <p>The deployment is already complete.</p>
695
+ capo_codedeploy.errors.deployment_does_not_exist_exception.DeploymentDoesNotExistException: <p>The deployment with the user or Amazon Web Services account does not exist.</p>
696
+ capo_codedeploy.errors.deployment_id_required_exception.DeploymentIdRequiredException: <p>At least one deployment ID must be specified.</p>
697
+ capo_codedeploy.errors.deployment_is_not_in_ready_state_exception.DeploymentIsNotInReadyStateException: <p>The deployment does not have a status of Ready and can't continue yet.</p>
698
+ capo_codedeploy.errors.invalid_deployment_id_exception.InvalidDeploymentIdException: <p>At least one of the deployment IDs was specified in an invalid format.</p>
699
+ capo_codedeploy.errors.invalid_deployment_status_exception.InvalidDeploymentStatusException: <p>The specified deployment status doesn't exist or cannot be determined.</p>
700
+ capo_codedeploy.errors.invalid_deployment_wait_type_exception.InvalidDeploymentWaitTypeException: <p> The wait type is invalid. </p>
701
+ capo_codedeploy.errors.unsupported_action_for_deployment_type_exception.UnsupportedActionForDeploymentTypeException: <p>A call was submitted that is not supported for the specified deployment type.</p>
702
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
703
+ """
704
+
705
+ async def _handler(
706
+ req: "AsyncOperationRequest[capo_codedeploy.types.continue_deployment_input.ContinueDeploymentInput]",
707
+ ) -> AsyncOperationResponse[None]:
708
+ import capo_codedeploy._operations.code_deploy_20141006.continue_deployment
709
+
710
+ (
711
+ output,
712
+ http_response,
713
+ ) = await capo_codedeploy._operations.code_deploy_20141006.continue_deployment.async_continue_deployment(
714
+ req.options, req.input
715
+ )
716
+ return AsyncOperationResponse(output=output, response=http_response)
717
+
718
+ interceptors_, options_ = self.operation_options(config_overrides)
719
+ input_: capo_codedeploy.types.continue_deployment_input.ContinueDeploymentInput = {}
720
+ if deployment_id is not None:
721
+ input_["deployment_id"] = deployment_id
722
+ if deployment_wait_type is not None:
723
+ input_["deployment_wait_type"] = deployment_wait_type
724
+
725
+ response = await aexecute_pipeline(
726
+ AsyncOperationRequest(input=input_, options=options_),
727
+ handler=_handler,
728
+ interceptors=list(interceptors_),
729
+ )
730
+ await response.response.aclose()
731
+ return response.output
732
+
733
+ async def create_application(
734
+ self,
735
+ application_name: "capo_codedeploy.types.application_name.ApplicationName",
736
+ *,
737
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
738
+ compute_platform: Optional[
739
+ "capo_codedeploy.types.compute_platform.ComputePlatform"
740
+ ] = None,
741
+ tags: Optional["capo_codedeploy.types.tag_list.TagList"] = None,
742
+ ) -> "capo_codedeploy.types.create_application_output.CreateApplicationOutput":
743
+ """<p>Creates an application.</p>
744
+
745
+ Args:
746
+ application_name: <p>The name of the application. This name must be unique with the applicable user or Amazon Web Services account.</p>
747
+ compute_platform: <p> The destination platform type for the deployment (<code>Lambda</code>, <code>Server</code>, or <code>ECS</code>).</p>
748
+ tags: <p> The metadata that you apply to CodeDeploy applications to help you organize and categorize them. Each tag consists of a key and an optional value, both of which you define. </p>
749
+
750
+ Raises:
751
+ capo_codedeploy.errors.application_already_exists_exception.ApplicationAlreadyExistsException: <p>An application with the specified name with the user or Amazon Web Services account already exists.</p>
752
+ capo_codedeploy.errors.application_limit_exceeded_exception.ApplicationLimitExceededException: <p>More applications were attempted to be created than are allowed.</p>
753
+ capo_codedeploy.errors.application_name_required_exception.ApplicationNameRequiredException: <p>The minimum number of required application names was not specified.</p>
754
+ capo_codedeploy.errors.invalid_application_name_exception.InvalidApplicationNameException: <p>The application name was specified in an invalid format.</p>
755
+ capo_codedeploy.errors.invalid_compute_platform_exception.InvalidComputePlatformException: <p>The computePlatform is invalid. The computePlatform should be <code>Lambda</code>, <code>Server</code>, or <code>ECS</code>.</p>
756
+ capo_codedeploy.errors.invalid_tags_to_add_exception.InvalidTagsToAddException: <p> The specified tags are not valid. </p>
757
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
758
+ """
759
+
760
+ async def _handler(
761
+ req: "AsyncOperationRequest[capo_codedeploy.types.create_application_input.CreateApplicationInput]",
762
+ ) -> AsyncOperationResponse[
763
+ "capo_codedeploy.types.create_application_output.CreateApplicationOutput"
764
+ ]:
765
+ import capo_codedeploy._operations.code_deploy_20141006.create_application
766
+
767
+ (
768
+ output,
769
+ http_response,
770
+ ) = await capo_codedeploy._operations.code_deploy_20141006.create_application.async_create_application(
771
+ req.options, req.input
772
+ )
773
+ return AsyncOperationResponse(output=output, response=http_response)
774
+
775
+ interceptors_, options_ = self.operation_options(config_overrides)
776
+ input_: capo_codedeploy.types.create_application_input.CreateApplicationInput = {
777
+ "application_name": application_name
778
+ }
779
+ if compute_platform is not None:
780
+ input_["compute_platform"] = compute_platform
781
+ if tags is not None:
782
+ input_["tags"] = tags
783
+
784
+ response = await aexecute_pipeline(
785
+ AsyncOperationRequest(input=input_, options=options_),
786
+ handler=_handler,
787
+ interceptors=list(interceptors_),
788
+ )
789
+ await response.response.aclose()
790
+ return response.output
791
+
792
+ async def create_deployment(
793
+ self,
794
+ application_name: "capo_codedeploy.types.application_name.ApplicationName",
795
+ *,
796
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
797
+ deployment_group_name: Optional[
798
+ "capo_codedeploy.types.deployment_group_name.DeploymentGroupName"
799
+ ] = None,
800
+ revision: Optional[
801
+ "capo_codedeploy.types.revision_location.RevisionLocation"
802
+ ] = None,
803
+ deployment_config_name: Optional[
804
+ "capo_codedeploy.types.deployment_config_name.DeploymentConfigName"
805
+ ] = None,
806
+ description: Optional["capo_codedeploy.types.description.Description"] = None,
807
+ ignore_application_stop_failures: Optional[
808
+ "capo_codedeploy.types.boolean.Boolean"
809
+ ] = None,
810
+ target_instances: Optional[
811
+ "capo_codedeploy.types.target_instances.TargetInstances"
812
+ ] = None,
813
+ auto_rollback_configuration: Optional[
814
+ "capo_codedeploy.types.auto_rollback_configuration.AutoRollbackConfiguration"
815
+ ] = None,
816
+ update_outdated_instances_only: Optional[
817
+ "capo_codedeploy.types.boolean.Boolean"
818
+ ] = None,
819
+ file_exists_behavior: Optional[
820
+ "capo_codedeploy.types.file_exists_behavior.FileExistsBehavior"
821
+ ] = None,
822
+ override_alarm_configuration: Optional[
823
+ "capo_codedeploy.types.alarm_configuration.AlarmConfiguration"
824
+ ] = None,
825
+ ) -> "capo_codedeploy.types.create_deployment_output.CreateDeploymentOutput":
826
+ """<p>Deploys an application revision through the specified deployment group.</p>
827
+
828
+ Args:
829
+ application_name: <p>The name of an CodeDeploy application associated with the user or Amazon Web Services account.</p>
830
+ deployment_group_name: <p>The name of the deployment group.</p>
831
+ revision: <p> The type and location of the revision to deploy. </p>
832
+ deployment_config_name: <p>The name of a deployment configuration associated with the user or Amazon Web Services account.</p> <p>If not specified, the value configured in the deployment group is used as the default. If the deployment group does not have a deployment configuration associated with it, <code>CodeDeployDefault</code>.<code>OneAtATime</code> is used by default.</p>
833
+ description: <p>A comment about the deployment.</p>
834
+ ignore_application_stop_failures: <p> If true, then if an <code>ApplicationStop</code>, <code>BeforeBlockTraffic</code>, or <code>AfterBlockTraffic</code> deployment lifecycle event to an instance fails, then the deployment continues to the next deployment lifecycle event. For example, if <code>ApplicationStop</code> fails, the deployment continues with <code>DownloadBundle</code>. If <code>BeforeBlockTraffic</code> fails, the deployment continues with <code>BlockTraffic</code>. If <code>AfterBlockTraffic</code> fails, the deployment continues with <code>ApplicationStop</code>. </p> <p> If false or not specified, then if a lifecycle event fails during a deployment to an instance, that deployment fails. If deployment to that instance is part of an overall deployment and the number of healthy hosts is not less than the minimum number of healthy hosts, then a deployment to the next instance is attempted. </p> <p> During a deployment, the CodeDeploy agent runs the scripts specified for <code>ApplicationStop</code>, <code>BeforeBlockTraffic</code>, and <code>AfterBlockTraffic</code> in the AppSpec file from the previous successful deployment. (All other scripts are run from the AppSpec file in the current deployment.) If one of these scripts contains an error and does not run successfully, the deployment can fail. </p> <p> If the cause of the failure is a script from the last successful deployment that will never run successfully, create a new deployment and use <code>ignoreApplicationStopFailures</code> to specify that the <code>ApplicationStop</code>, <code>BeforeBlockTraffic</code>, and <code>AfterBlockTraffic</code> failures should be ignored. </p>
835
+ target_instances: <p> Information about the instances that belong to the replacement environment in a blue/green deployment. </p>
836
+ auto_rollback_configuration: <p>Configuration information for an automatic rollback that is added when a deployment is created.</p>
837
+ update_outdated_instances_only: <p> Indicates whether to deploy to all instances or only to instances that are not running the latest application revision. </p>
838
+ file_exists_behavior: <p>Information about how CodeDeploy handles files that already exist in a deployment target location but weren't part of the previous successful deployment.</p> <p>The <code>fileExistsBehavior</code> parameter takes any of the following values:</p> <ul> <li> <p>DISALLOW: The deployment fails. This is also the default behavior if no option is specified.</p> </li> <li> <p>OVERWRITE: The version of the file from the application revision currently being deployed replaces the version already on the instance.</p> </li> <li> <p>RETAIN: The version of the file already on the instance is kept and used as part of the new deployment.</p> </li> </ul>
839
+ override_alarm_configuration: <p>Allows you to specify information about alarms associated with a deployment. The alarm configuration that you specify here will override the alarm configuration at the deployment group level. Consider overriding the alarm configuration if you have set up alarms at the deployment group level that are causing deployment failures. In this case, you would call <code>CreateDeployment</code> to create a new deployment that uses a previous application revision that is known to work, and set its alarm configuration to turn off alarm polling. Turning off alarm polling ensures that the new deployment proceeds without being blocked by the alarm that was generated by the previous, failed, deployment.</p> <note> <p>If you specify an <code>overrideAlarmConfiguration</code>, you need the <code>UpdateDeploymentGroup</code> IAM permission when calling <code>CreateDeployment</code>.</p> </note>
840
+
841
+ Raises:
842
+ capo_codedeploy.errors.alarms_limit_exceeded_exception.AlarmsLimitExceededException: <p>The maximum number of alarms for a deployment group (10) was exceeded.</p>
843
+ capo_codedeploy.errors.application_does_not_exist_exception.ApplicationDoesNotExistException: <p>The application does not exist with the user or Amazon Web Services account.</p>
844
+ capo_codedeploy.errors.application_name_required_exception.ApplicationNameRequiredException: <p>The minimum number of required application names was not specified.</p>
845
+ capo_codedeploy.errors.deployment_config_does_not_exist_exception.DeploymentConfigDoesNotExistException: <p>The deployment configuration does not exist with the user or Amazon Web Services account.</p>
846
+ capo_codedeploy.errors.deployment_group_does_not_exist_exception.DeploymentGroupDoesNotExistException: <p>The named deployment group with the user or Amazon Web Services account does not exist.</p>
847
+ capo_codedeploy.errors.deployment_group_name_required_exception.DeploymentGroupNameRequiredException: <p>The deployment group name was not specified.</p>
848
+ capo_codedeploy.errors.deployment_limit_exceeded_exception.DeploymentLimitExceededException: <p>The number of allowed deployments was exceeded.</p>
849
+ capo_codedeploy.errors.description_too_long_exception.DescriptionTooLongException: <p>The description is too long.</p>
850
+ capo_codedeploy.errors.invalid_alarm_config_exception.InvalidAlarmConfigException: <p>The format of the alarm configuration is invalid. Possible causes include:</p> <ul> <li> <p>The alarm list is null.</p> </li> <li> <p>The alarm object is null.</p> </li> <li> <p>The alarm name is empty or null or exceeds the limit of 255 characters.</p> </li> <li> <p>Two alarms with the same name have been specified.</p> </li> <li> <p>The alarm configuration is enabled, but the alarm list is empty.</p> </li> </ul>
851
+ capo_codedeploy.errors.invalid_application_name_exception.InvalidApplicationNameException: <p>The application name was specified in an invalid format.</p>
852
+ capo_codedeploy.errors.invalid_auto_rollback_config_exception.InvalidAutoRollbackConfigException: <p>The automatic rollback configuration was specified in an invalid format. For example, automatic rollback is enabled, but an invalid triggering event type or no event types were listed.</p>
853
+ capo_codedeploy.errors.invalid_auto_scaling_group_exception.InvalidAutoScalingGroupException: <p>The Auto Scaling group was specified in an invalid format or does not exist.</p>
854
+ capo_codedeploy.errors.invalid_deployment_config_name_exception.InvalidDeploymentConfigNameException: <p>The deployment configuration name was specified in an invalid format.</p>
855
+ capo_codedeploy.errors.invalid_deployment_group_name_exception.InvalidDeploymentGroupNameException: <p>The deployment group name was specified in an invalid format.</p>
856
+ capo_codedeploy.errors.invalid_file_exists_behavior_exception.InvalidFileExistsBehaviorException: <p>An invalid fileExistsBehavior option was specified to determine how CodeDeploy handles files or directories that already exist in a deployment target location, but weren't part of the previous successful deployment. Valid values include \"DISALLOW,\" \"OVERWRITE,\" and \"RETAIN.\"</p>
857
+ capo_codedeploy.errors.invalid_git_hub_account_token_exception.InvalidGitHubAccountTokenException: <p>The GitHub token is not valid.</p>
858
+ capo_codedeploy.errors.invalid_ignore_application_stop_failures_value_exception.InvalidIgnoreApplicationStopFailuresValueException: <p>The IgnoreApplicationStopFailures value is invalid. For Lambda deployments, <code>false</code> is expected. For EC2/On-premises deployments, <code>true</code> or <code>false</code> is expected.</p>
859
+ capo_codedeploy.errors.invalid_load_balancer_info_exception.InvalidLoadBalancerInfoException: <p>An invalid load balancer name, or no load balancer name, was specified.</p>
860
+ capo_codedeploy.errors.invalid_revision_exception.InvalidRevisionException: <p>The revision was specified in an invalid format.</p>
861
+ capo_codedeploy.errors.invalid_role_exception.InvalidRoleException: <p>The service role ARN was specified in an invalid format. Or, if an Auto Scaling group was specified, the specified service role does not grant the appropriate permissions to Amazon EC2 Auto Scaling.</p>
862
+ capo_codedeploy.errors.invalid_target_instances_exception.InvalidTargetInstancesException: <p>The target instance configuration is invalid. Possible causes include:</p> <ul> <li> <p>Configuration data for target instances was entered for an in-place deployment.</p> </li> <li> <p>The limit of 10 tags for a tag type was exceeded.</p> </li> <li> <p>The combined length of the tag names exceeded the limit. </p> </li> <li> <p>A specified tag is not currently applied to any instances.</p> </li> </ul>
863
+ capo_codedeploy.errors.invalid_traffic_routing_configuration_exception.InvalidTrafficRoutingConfigurationException: <p> The configuration that specifies how traffic is routed during a deployment is invalid.</p>
864
+ capo_codedeploy.errors.invalid_update_outdated_instances_only_value_exception.InvalidUpdateOutdatedInstancesOnlyValueException: <p>The UpdateOutdatedInstancesOnly value is invalid. For Lambda deployments, <code>false</code> is expected. For EC2/On-premises deployments, <code>true</code> or <code>false</code> is expected.</p>
865
+ capo_codedeploy.errors.revision_does_not_exist_exception.RevisionDoesNotExistException: <p>The named revision does not exist with the user or Amazon Web Services account.</p>
866
+ capo_codedeploy.errors.revision_required_exception.RevisionRequiredException: <p>The revision ID was not specified.</p>
867
+ capo_codedeploy.errors.throttling_exception.ThrottlingException: <p>An API function was called too frequently.</p>
868
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
869
+ """
870
+
871
+ async def _handler(
872
+ req: "AsyncOperationRequest[capo_codedeploy.types.create_deployment_input.CreateDeploymentInput]",
873
+ ) -> AsyncOperationResponse[
874
+ "capo_codedeploy.types.create_deployment_output.CreateDeploymentOutput"
875
+ ]:
876
+ import capo_codedeploy._operations.code_deploy_20141006.create_deployment
877
+
878
+ (
879
+ output,
880
+ http_response,
881
+ ) = await capo_codedeploy._operations.code_deploy_20141006.create_deployment.async_create_deployment(
882
+ req.options, req.input
883
+ )
884
+ return AsyncOperationResponse(output=output, response=http_response)
885
+
886
+ interceptors_, options_ = self.operation_options(config_overrides)
887
+ input_: capo_codedeploy.types.create_deployment_input.CreateDeploymentInput = {
888
+ "application_name": application_name
889
+ }
890
+ if deployment_group_name is not None:
891
+ input_["deployment_group_name"] = deployment_group_name
892
+ if revision is not None:
893
+ input_["revision"] = revision
894
+ if deployment_config_name is not None:
895
+ input_["deployment_config_name"] = deployment_config_name
896
+ if description is not None:
897
+ input_["description"] = description
898
+ if ignore_application_stop_failures is not None:
899
+ input_["ignore_application_stop_failures"] = (
900
+ ignore_application_stop_failures
901
+ )
902
+ if target_instances is not None:
903
+ input_["target_instances"] = target_instances
904
+ if auto_rollback_configuration is not None:
905
+ input_["auto_rollback_configuration"] = auto_rollback_configuration
906
+ if update_outdated_instances_only is not None:
907
+ input_["update_outdated_instances_only"] = update_outdated_instances_only
908
+ if file_exists_behavior is not None:
909
+ input_["file_exists_behavior"] = file_exists_behavior
910
+ if override_alarm_configuration is not None:
911
+ input_["override_alarm_configuration"] = override_alarm_configuration
912
+
913
+ response = await aexecute_pipeline(
914
+ AsyncOperationRequest(input=input_, options=options_),
915
+ handler=_handler,
916
+ interceptors=list(interceptors_),
917
+ )
918
+ await response.response.aclose()
919
+ return response.output
920
+
921
+ async def create_deployment_config(
922
+ self,
923
+ deployment_config_name: "capo_codedeploy.types.deployment_config_name.DeploymentConfigName",
924
+ *,
925
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
926
+ minimum_healthy_hosts: Optional[
927
+ "capo_codedeploy.types.minimum_healthy_hosts.MinimumHealthyHosts"
928
+ ] = None,
929
+ traffic_routing_config: Optional[
930
+ "capo_codedeploy.types.traffic_routing_config.TrafficRoutingConfig"
931
+ ] = None,
932
+ compute_platform: Optional[
933
+ "capo_codedeploy.types.compute_platform.ComputePlatform"
934
+ ] = None,
935
+ zonal_config: Optional["capo_codedeploy.types.zonal_config.ZonalConfig"] = None,
936
+ ) -> "capo_codedeploy.types.create_deployment_config_output.CreateDeploymentConfigOutput":
937
+ r"""<p> Creates a deployment configuration. </p>
938
+
939
+ Args:
940
+ deployment_config_name: <p>The name of the deployment configuration to create.</p>
941
+ minimum_healthy_hosts: <p>The minimum number of healthy instances that should be available at any time during the deployment. There are two parameters expected in the input: type and value.</p> <p>The type parameter takes either of the following values:</p> <ul> <li> <p>HOST_COUNT: The value parameter represents the minimum number of healthy instances as an absolute value.</p> </li> <li> <p>FLEET_PERCENT: The value parameter represents the minimum number of healthy instances as a percentage of the total number of instances in the deployment. If you specify FLEET_PERCENT, at the start of the deployment, CodeDeploy converts the percentage to the equivalent number of instances and rounds up fractional instances.</p> </li> </ul> <p>The value parameter takes an integer.</p> <p>For example, to set a minimum of 95% healthy instance, specify a type of FLEET_PERCENT and a value of 95.</p>
942
+ traffic_routing_config: <p>The configuration that specifies how the deployment traffic is routed.</p>
943
+ compute_platform: <p>The destination platform type for the deployment (<code>Lambda</code>, <code>Server</code>, or <code>ECS</code>).</p>
944
+ zonal_config: <p>Configure the <code>ZonalConfig</code> object if you want CodeDeploy to deploy your application to one <a href=\"https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-regions-availability-zones.html#concepts-availability-zones\">Availability Zone</a> at a time, within an Amazon Web Services Region.</p> <p>For more information about the zonal configuration feature, see <a href=\"https://docs.aws.amazon.com/codedeploy/latest/userguide/deployment-configurations-create.html#zonal-config\">zonal configuration</a> in the <i>CodeDeploy User Guide</i>.</p>
945
+
946
+ Raises:
947
+ capo_codedeploy.errors.deployment_config_already_exists_exception.DeploymentConfigAlreadyExistsException: <p>A deployment configuration with the specified name with the user or Amazon Web Services account already exists.</p>
948
+ capo_codedeploy.errors.deployment_config_limit_exceeded_exception.DeploymentConfigLimitExceededException: <p>The deployment configurations limit was exceeded.</p>
949
+ capo_codedeploy.errors.deployment_config_name_required_exception.DeploymentConfigNameRequiredException: <p>The deployment configuration name was not specified.</p>
950
+ capo_codedeploy.errors.invalid_compute_platform_exception.InvalidComputePlatformException: <p>The computePlatform is invalid. The computePlatform should be <code>Lambda</code>, <code>Server</code>, or <code>ECS</code>.</p>
951
+ capo_codedeploy.errors.invalid_deployment_config_name_exception.InvalidDeploymentConfigNameException: <p>The deployment configuration name was specified in an invalid format.</p>
952
+ capo_codedeploy.errors.invalid_minimum_healthy_host_value_exception.InvalidMinimumHealthyHostValueException: <p>The minimum healthy instance value was specified in an invalid format.</p>
953
+ capo_codedeploy.errors.invalid_traffic_routing_configuration_exception.InvalidTrafficRoutingConfigurationException: <p> The configuration that specifies how traffic is routed during a deployment is invalid.</p>
954
+ capo_codedeploy.errors.invalid_zonal_deployment_configuration_exception.InvalidZonalDeploymentConfigurationException: <p>The <code>ZonalConfig</code> object is not valid.</p>
955
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
956
+ """
957
+
958
+ async def _handler(
959
+ req: "AsyncOperationRequest[capo_codedeploy.types.create_deployment_config_input.CreateDeploymentConfigInput]",
960
+ ) -> AsyncOperationResponse[
961
+ "capo_codedeploy.types.create_deployment_config_output.CreateDeploymentConfigOutput"
962
+ ]:
963
+ import capo_codedeploy._operations.code_deploy_20141006.create_deployment_config
964
+
965
+ (
966
+ output,
967
+ http_response,
968
+ ) = await capo_codedeploy._operations.code_deploy_20141006.create_deployment_config.async_create_deployment_config(
969
+ req.options, req.input
970
+ )
971
+ return AsyncOperationResponse(output=output, response=http_response)
972
+
973
+ interceptors_, options_ = self.operation_options(config_overrides)
974
+ input_: capo_codedeploy.types.create_deployment_config_input.CreateDeploymentConfigInput = {
975
+ "deployment_config_name": deployment_config_name
976
+ }
977
+ if minimum_healthy_hosts is not None:
978
+ input_["minimum_healthy_hosts"] = minimum_healthy_hosts
979
+ if traffic_routing_config is not None:
980
+ input_["traffic_routing_config"] = traffic_routing_config
981
+ if compute_platform is not None:
982
+ input_["compute_platform"] = compute_platform
983
+ if zonal_config is not None:
984
+ input_["zonal_config"] = zonal_config
985
+
986
+ response = await aexecute_pipeline(
987
+ AsyncOperationRequest(input=input_, options=options_),
988
+ handler=_handler,
989
+ interceptors=list(interceptors_),
990
+ )
991
+ await response.response.aclose()
992
+ return response.output
993
+
994
+ async def create_deployment_group(
995
+ self,
996
+ application_name: "capo_codedeploy.types.application_name.ApplicationName",
997
+ deployment_group_name: "capo_codedeploy.types.deployment_group_name.DeploymentGroupName",
998
+ service_role_arn: "capo_codedeploy.types.role.Role",
999
+ *,
1000
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
1001
+ deployment_config_name: Optional[
1002
+ "capo_codedeploy.types.deployment_config_name.DeploymentConfigName"
1003
+ ] = None,
1004
+ ec2_tag_filters: Optional[
1005
+ "capo_codedeploy.types.ec2_tag_filter_list.EC2TagFilterList"
1006
+ ] = None,
1007
+ on_premises_instance_tag_filters: Optional[
1008
+ "capo_codedeploy.types.tag_filter_list.TagFilterList"
1009
+ ] = None,
1010
+ auto_scaling_groups: Optional[
1011
+ "capo_codedeploy.types.auto_scaling_group_name_list.AutoScalingGroupNameList"
1012
+ ] = None,
1013
+ trigger_configurations: Optional[
1014
+ "capo_codedeploy.types.trigger_config_list.TriggerConfigList"
1015
+ ] = None,
1016
+ alarm_configuration: Optional[
1017
+ "capo_codedeploy.types.alarm_configuration.AlarmConfiguration"
1018
+ ] = None,
1019
+ auto_rollback_configuration: Optional[
1020
+ "capo_codedeploy.types.auto_rollback_configuration.AutoRollbackConfiguration"
1021
+ ] = None,
1022
+ outdated_instances_strategy: Optional[
1023
+ "capo_codedeploy.types.outdated_instances_strategy.OutdatedInstancesStrategy"
1024
+ ] = None,
1025
+ deployment_style: Optional[
1026
+ "capo_codedeploy.types.deployment_style.DeploymentStyle"
1027
+ ] = None,
1028
+ blue_green_deployment_configuration: Optional[
1029
+ "capo_codedeploy.types.blue_green_deployment_configuration.BlueGreenDeploymentConfiguration"
1030
+ ] = None,
1031
+ load_balancer_info: Optional[
1032
+ "capo_codedeploy.types.load_balancer_info.LoadBalancerInfo"
1033
+ ] = None,
1034
+ ec2_tag_set: Optional["capo_codedeploy.types.ec2_tag_set.EC2TagSet"] = None,
1035
+ ecs_services: Optional[
1036
+ "capo_codedeploy.types.ecs_service_list.ECSServiceList"
1037
+ ] = None,
1038
+ on_premises_tag_set: Optional[
1039
+ "capo_codedeploy.types.on_premises_tag_set.OnPremisesTagSet"
1040
+ ] = None,
1041
+ tags: Optional["capo_codedeploy.types.tag_list.TagList"] = None,
1042
+ termination_hook_enabled: Optional[
1043
+ "capo_codedeploy.types.nullable_boolean.NullableBoolean"
1044
+ ] = None,
1045
+ ) -> "capo_codedeploy.types.create_deployment_group_output.CreateDeploymentGroupOutput":
1046
+ r"""<p>Creates a deployment group to which application revisions are deployed.</p>
1047
+
1048
+ Args:
1049
+ application_name: <p>The name of an CodeDeploy application associated with the user or Amazon Web Services account.</p>
1050
+ deployment_group_name: <p>The name of a new deployment group for the specified application.</p>
1051
+ deployment_config_name: <p>If specified, the deployment configuration name can be either one of the predefined configurations provided with CodeDeploy or a custom deployment configuration that you create by calling the create deployment configuration operation.</p> <p> <code>CodeDeployDefault.OneAtATime</code> is the default deployment configuration. It is used if a configuration isn't specified for the deployment or deployment group.</p> <p>For more information about the predefined deployment configurations in CodeDeploy, see <a href=\"https://docs.aws.amazon.com/codedeploy/latest/userguide/deployment-configurations.html\">Working with Deployment Configurations in CodeDeploy</a> in the <i>CodeDeploy User Guide</i>.</p>
1052
+ ec2_tag_filters: <p>The Amazon EC2 tags on which to filter. The deployment group includes Amazon EC2 instances with any of the specified tags. Cannot be used in the same call as ec2TagSet.</p>
1053
+ on_premises_instance_tag_filters: <p>The on-premises instance tags on which to filter. The deployment group includes on-premises instances with any of the specified tags. Cannot be used in the same call as <code>OnPremisesTagSet</code>.</p>
1054
+ auto_scaling_groups: <p>A list of associated Amazon EC2 Auto Scaling groups.</p>
1055
+ service_role_arn: <p>A service role Amazon Resource Name (ARN) that allows CodeDeploy to act on the user's behalf when interacting with Amazon Web Services services.</p>
1056
+ trigger_configurations: <p>Information about triggers to create when the deployment group is created. For examples, see <a href=\"https://docs.aws.amazon.com/codedeploy/latest/userguide/how-to-notify-sns.html\">Create a Trigger for an CodeDeploy Event</a> in the <i>CodeDeploy User Guide</i>.</p>
1057
+ alarm_configuration: <p>Information to add about Amazon CloudWatch alarms when the deployment group is created.</p>
1058
+ auto_rollback_configuration: <p>Configuration information for an automatic rollback that is added when a deployment group is created.</p>
1059
+ outdated_instances_strategy: <p>Indicates what happens when new Amazon EC2 instances are launched mid-deployment and do not receive the deployed application revision.</p> <p>If this option is set to <code>UPDATE</code> or is unspecified, CodeDeploy initiates one or more 'auto-update outdated instances' deployments to apply the deployed application revision to the new Amazon EC2 instances.</p> <p>If this option is set to <code>IGNORE</code>, CodeDeploy does not initiate a deployment to update the new Amazon EC2 instances. This may result in instances having different revisions.</p>
1060
+ deployment_style: <p>Information about the type of deployment, in-place or blue/green, that you want to run and whether to route deployment traffic behind a load balancer.</p>
1061
+ blue_green_deployment_configuration: <p>Information about blue/green deployment options for a deployment group.</p>
1062
+ load_balancer_info: <p>Information about the load balancer used in a deployment.</p>
1063
+ ec2_tag_set: <p>Information about groups of tags applied to Amazon EC2 instances. The deployment group includes only Amazon EC2 instances identified by all the tag groups. Cannot be used in the same call as <code>ec2TagFilters</code>.</p>
1064
+ ecs_services: <p> The target Amazon ECS services in the deployment group. This applies only to deployment groups that use the Amazon ECS compute platform. A target Amazon ECS service is specified as an Amazon ECS cluster and service name pair using the format <code><clustername>:<servicename></code>. </p>
1065
+ on_premises_tag_set: <p>Information about groups of tags applied to on-premises instances. The deployment group includes only on-premises instances identified by all of the tag groups. Cannot be used in the same call as <code>onPremisesInstanceTagFilters</code>.</p>
1066
+ tags: <p> The metadata that you apply to CodeDeploy deployment groups to help you organize and categorize them. Each tag consists of a key and an optional value, both of which you define. </p>
1067
+ termination_hook_enabled: <p>This parameter only applies if you are using CodeDeploy with Amazon EC2 Auto Scaling. For more information, see <a href=\"https://docs.aws.amazon.com/codedeploy/latest/userguide/integrations-aws-auto-scaling.html\">Integrating CodeDeploy with Amazon EC2 Auto Scaling</a> in the <i>CodeDeploy User Guide</i>.</p> <p>Set <code>terminationHookEnabled</code> to <code>true</code> to have CodeDeploy install a termination hook into your Auto Scaling group when you create a deployment group. When this hook is installed, CodeDeploy will perform termination deployments.</p> <p>For information about termination deployments, see <a href=\"https://docs.aws.amazon.com/codedeploy/latest/userguide/integrations-aws-auto-scaling.html#integrations-aws-auto-scaling-behaviors-hook-enable\">Enabling termination deployments during Auto Scaling scale-in events</a> in the <i>CodeDeploy User Guide</i>.</p> <p>For more information about Auto Scaling scale-in events, see the <a href=\"https://docs.aws.amazon.com/autoscaling/ec2/userguide/ec2-auto-scaling-lifecycle.html#as-lifecycle-scale-in\">Scale in</a> topic in the <i>Amazon EC2 Auto Scaling User Guide</i>.</p>
1068
+
1069
+ Raises:
1070
+ capo_codedeploy.errors.alarms_limit_exceeded_exception.AlarmsLimitExceededException: <p>The maximum number of alarms for a deployment group (10) was exceeded.</p>
1071
+ capo_codedeploy.errors.application_does_not_exist_exception.ApplicationDoesNotExistException: <p>The application does not exist with the user or Amazon Web Services account.</p>
1072
+ capo_codedeploy.errors.application_name_required_exception.ApplicationNameRequiredException: <p>The minimum number of required application names was not specified.</p>
1073
+ capo_codedeploy.errors.deployment_config_does_not_exist_exception.DeploymentConfigDoesNotExistException: <p>The deployment configuration does not exist with the user or Amazon Web Services account.</p>
1074
+ capo_codedeploy.errors.deployment_group_already_exists_exception.DeploymentGroupAlreadyExistsException: <p>A deployment group with the specified name with the user or Amazon Web Services account already exists.</p>
1075
+ capo_codedeploy.errors.deployment_group_limit_exceeded_exception.DeploymentGroupLimitExceededException: <p> The deployment groups limit was exceeded.</p>
1076
+ capo_codedeploy.errors.deployment_group_name_required_exception.DeploymentGroupNameRequiredException: <p>The deployment group name was not specified.</p>
1077
+ capo_codedeploy.errors.ecs_service_mapping_limit_exceeded_exception.ECSServiceMappingLimitExceededException: <p> The Amazon ECS service is associated with more than one deployment groups. An Amazon ECS service can be associated with only one deployment group. </p>
1078
+ capo_codedeploy.errors.invalid_alarm_config_exception.InvalidAlarmConfigException: <p>The format of the alarm configuration is invalid. Possible causes include:</p> <ul> <li> <p>The alarm list is null.</p> </li> <li> <p>The alarm object is null.</p> </li> <li> <p>The alarm name is empty or null or exceeds the limit of 255 characters.</p> </li> <li> <p>Two alarms with the same name have been specified.</p> </li> <li> <p>The alarm configuration is enabled, but the alarm list is empty.</p> </li> </ul>
1079
+ capo_codedeploy.errors.invalid_application_name_exception.InvalidApplicationNameException: <p>The application name was specified in an invalid format.</p>
1080
+ capo_codedeploy.errors.invalid_auto_rollback_config_exception.InvalidAutoRollbackConfigException: <p>The automatic rollback configuration was specified in an invalid format. For example, automatic rollback is enabled, but an invalid triggering event type or no event types were listed.</p>
1081
+ capo_codedeploy.errors.invalid_auto_scaling_group_exception.InvalidAutoScalingGroupException: <p>The Auto Scaling group was specified in an invalid format or does not exist.</p>
1082
+ capo_codedeploy.errors.invalid_blue_green_deployment_configuration_exception.InvalidBlueGreenDeploymentConfigurationException: <p>The configuration for the blue/green deployment group was provided in an invalid format. For information about deployment configuration format, see <a>CreateDeploymentConfig</a>.</p>
1083
+ capo_codedeploy.errors.invalid_deployment_config_name_exception.InvalidDeploymentConfigNameException: <p>The deployment configuration name was specified in an invalid format.</p>
1084
+ capo_codedeploy.errors.invalid_deployment_group_name_exception.InvalidDeploymentGroupNameException: <p>The deployment group name was specified in an invalid format.</p>
1085
+ capo_codedeploy.errors.invalid_deployment_style_exception.InvalidDeploymentStyleException: <p>An invalid deployment style was specified. Valid deployment types include \"IN_PLACE\" and \"BLUE_GREEN.\" Valid deployment options include \"WITH_TRAFFIC_CONTROL\" and \"WITHOUT_TRAFFIC_CONTROL.\"</p>
1086
+ capo_codedeploy.errors.invalid_ec2_tag_combination_exception.InvalidEC2TagCombinationException: <p>A call was submitted that specified both Ec2TagFilters and Ec2TagSet, but only one of these data types can be used in a single call.</p>
1087
+ capo_codedeploy.errors.invalid_ec2_tag_exception.InvalidEC2TagException: <p>The tag was specified in an invalid format.</p>
1088
+ capo_codedeploy.errors.invalid_ecs_service_exception.InvalidECSServiceException: <p> The Amazon ECS service identifier is not valid. </p>
1089
+ capo_codedeploy.errors.invalid_input_exception.InvalidInputException: <p>The input was specified in an invalid format.</p>
1090
+ capo_codedeploy.errors.invalid_load_balancer_info_exception.InvalidLoadBalancerInfoException: <p>An invalid load balancer name, or no load balancer name, was specified.</p>
1091
+ capo_codedeploy.errors.invalid_on_premises_tag_combination_exception.InvalidOnPremisesTagCombinationException: <p>A call was submitted that specified both OnPremisesTagFilters and OnPremisesTagSet, but only one of these data types can be used in a single call.</p>
1092
+ capo_codedeploy.errors.invalid_role_exception.InvalidRoleException: <p>The service role ARN was specified in an invalid format. Or, if an Auto Scaling group was specified, the specified service role does not grant the appropriate permissions to Amazon EC2 Auto Scaling.</p>
1093
+ capo_codedeploy.errors.invalid_tag_exception.InvalidTagException: <p>The tag was specified in an invalid format.</p>
1094
+ capo_codedeploy.errors.invalid_tags_to_add_exception.InvalidTagsToAddException: <p> The specified tags are not valid. </p>
1095
+ capo_codedeploy.errors.invalid_target_group_pair_exception.InvalidTargetGroupPairException: <p> A target group pair associated with this deployment is not valid. </p>
1096
+ capo_codedeploy.errors.invalid_traffic_routing_configuration_exception.InvalidTrafficRoutingConfigurationException: <p> The configuration that specifies how traffic is routed during a deployment is invalid.</p>
1097
+ capo_codedeploy.errors.invalid_trigger_config_exception.InvalidTriggerConfigException: <p>The trigger was specified in an invalid format.</p>
1098
+ capo_codedeploy.errors.lifecycle_hook_limit_exceeded_exception.LifecycleHookLimitExceededException: <p>The limit for lifecycle hooks was exceeded.</p>
1099
+ capo_codedeploy.errors.role_required_exception.RoleRequiredException: <p>The role ID was not specified.</p>
1100
+ capo_codedeploy.errors.tag_set_list_limit_exceeded_exception.TagSetListLimitExceededException: <p>The number of tag groups included in the tag set list exceeded the maximum allowed limit of 3.</p>
1101
+ capo_codedeploy.errors.throttling_exception.ThrottlingException: <p>An API function was called too frequently.</p>
1102
+ capo_codedeploy.errors.trigger_targets_limit_exceeded_exception.TriggerTargetsLimitExceededException: <p>The maximum allowed number of triggers was exceeded.</p>
1103
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
1104
+ """
1105
+
1106
+ async def _handler(
1107
+ req: "AsyncOperationRequest[capo_codedeploy.types.create_deployment_group_input.CreateDeploymentGroupInput]",
1108
+ ) -> AsyncOperationResponse[
1109
+ "capo_codedeploy.types.create_deployment_group_output.CreateDeploymentGroupOutput"
1110
+ ]:
1111
+ import capo_codedeploy._operations.code_deploy_20141006.create_deployment_group
1112
+
1113
+ (
1114
+ output,
1115
+ http_response,
1116
+ ) = await capo_codedeploy._operations.code_deploy_20141006.create_deployment_group.async_create_deployment_group(
1117
+ req.options, req.input
1118
+ )
1119
+ return AsyncOperationResponse(output=output, response=http_response)
1120
+
1121
+ interceptors_, options_ = self.operation_options(config_overrides)
1122
+ input_: capo_codedeploy.types.create_deployment_group_input.CreateDeploymentGroupInput = {
1123
+ "application_name": application_name,
1124
+ "deployment_group_name": deployment_group_name,
1125
+ "service_role_arn": service_role_arn,
1126
+ }
1127
+ if deployment_config_name is not None:
1128
+ input_["deployment_config_name"] = deployment_config_name
1129
+ if ec2_tag_filters is not None:
1130
+ input_["ec2_tag_filters"] = ec2_tag_filters
1131
+ if on_premises_instance_tag_filters is not None:
1132
+ input_["on_premises_instance_tag_filters"] = (
1133
+ on_premises_instance_tag_filters
1134
+ )
1135
+ if auto_scaling_groups is not None:
1136
+ input_["auto_scaling_groups"] = auto_scaling_groups
1137
+ if trigger_configurations is not None:
1138
+ input_["trigger_configurations"] = trigger_configurations
1139
+ if alarm_configuration is not None:
1140
+ input_["alarm_configuration"] = alarm_configuration
1141
+ if auto_rollback_configuration is not None:
1142
+ input_["auto_rollback_configuration"] = auto_rollback_configuration
1143
+ if outdated_instances_strategy is not None:
1144
+ input_["outdated_instances_strategy"] = outdated_instances_strategy
1145
+ if deployment_style is not None:
1146
+ input_["deployment_style"] = deployment_style
1147
+ if blue_green_deployment_configuration is not None:
1148
+ input_["blue_green_deployment_configuration"] = (
1149
+ blue_green_deployment_configuration
1150
+ )
1151
+ if load_balancer_info is not None:
1152
+ input_["load_balancer_info"] = load_balancer_info
1153
+ if ec2_tag_set is not None:
1154
+ input_["ec2_tag_set"] = ec2_tag_set
1155
+ if ecs_services is not None:
1156
+ input_["ecs_services"] = ecs_services
1157
+ if on_premises_tag_set is not None:
1158
+ input_["on_premises_tag_set"] = on_premises_tag_set
1159
+ if tags is not None:
1160
+ input_["tags"] = tags
1161
+ if termination_hook_enabled is not None:
1162
+ input_["termination_hook_enabled"] = termination_hook_enabled
1163
+
1164
+ response = await aexecute_pipeline(
1165
+ AsyncOperationRequest(input=input_, options=options_),
1166
+ handler=_handler,
1167
+ interceptors=list(interceptors_),
1168
+ )
1169
+ await response.response.aclose()
1170
+ return response.output
1171
+
1172
+ async def delete_application(
1173
+ self,
1174
+ application_name: "capo_codedeploy.types.application_name.ApplicationName",
1175
+ *,
1176
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
1177
+ ) -> None:
1178
+ """<p>Deletes an application.</p>
1179
+
1180
+ Args:
1181
+ application_name: <p>The name of an CodeDeploy application associated with the user or Amazon Web Services account.</p>
1182
+
1183
+ Raises:
1184
+ capo_codedeploy.errors.application_name_required_exception.ApplicationNameRequiredException: <p>The minimum number of required application names was not specified.</p>
1185
+ capo_codedeploy.errors.invalid_application_name_exception.InvalidApplicationNameException: <p>The application name was specified in an invalid format.</p>
1186
+ capo_codedeploy.errors.invalid_role_exception.InvalidRoleException: <p>The service role ARN was specified in an invalid format. Or, if an Auto Scaling group was specified, the specified service role does not grant the appropriate permissions to Amazon EC2 Auto Scaling.</p>
1187
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
1188
+ """
1189
+
1190
+ async def _handler(
1191
+ req: "AsyncOperationRequest[capo_codedeploy.types.delete_application_input.DeleteApplicationInput]",
1192
+ ) -> AsyncOperationResponse[None]:
1193
+ import capo_codedeploy._operations.code_deploy_20141006.delete_application
1194
+
1195
+ (
1196
+ output,
1197
+ http_response,
1198
+ ) = await capo_codedeploy._operations.code_deploy_20141006.delete_application.async_delete_application(
1199
+ req.options, req.input
1200
+ )
1201
+ return AsyncOperationResponse(output=output, response=http_response)
1202
+
1203
+ interceptors_, options_ = self.operation_options(config_overrides)
1204
+ input_: capo_codedeploy.types.delete_application_input.DeleteApplicationInput = {
1205
+ "application_name": application_name
1206
+ }
1207
+
1208
+ response = await aexecute_pipeline(
1209
+ AsyncOperationRequest(input=input_, options=options_),
1210
+ handler=_handler,
1211
+ interceptors=list(interceptors_),
1212
+ )
1213
+ await response.response.aclose()
1214
+ return response.output
1215
+
1216
+ async def delete_deployment_config(
1217
+ self,
1218
+ deployment_config_name: "capo_codedeploy.types.deployment_config_name.DeploymentConfigName",
1219
+ *,
1220
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
1221
+ ) -> None:
1222
+ """<p>Deletes a deployment configuration.</p> <note> <p>A deployment configuration cannot be deleted if it is currently in use. Predefined configurations cannot be deleted.</p> </note>
1223
+
1224
+ Args:
1225
+ deployment_config_name: <p>The name of a deployment configuration associated with the user or Amazon Web Services account.</p>
1226
+
1227
+ Raises:
1228
+ capo_codedeploy.errors.deployment_config_in_use_exception.DeploymentConfigInUseException: <p>The deployment configuration is still in use.</p>
1229
+ capo_codedeploy.errors.deployment_config_name_required_exception.DeploymentConfigNameRequiredException: <p>The deployment configuration name was not specified.</p>
1230
+ capo_codedeploy.errors.invalid_deployment_config_name_exception.InvalidDeploymentConfigNameException: <p>The deployment configuration name was specified in an invalid format.</p>
1231
+ capo_codedeploy.errors.invalid_operation_exception.InvalidOperationException: <p>An invalid operation was detected.</p>
1232
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
1233
+ """
1234
+
1235
+ async def _handler(
1236
+ req: "AsyncOperationRequest[capo_codedeploy.types.delete_deployment_config_input.DeleteDeploymentConfigInput]",
1237
+ ) -> AsyncOperationResponse[None]:
1238
+ import capo_codedeploy._operations.code_deploy_20141006.delete_deployment_config
1239
+
1240
+ (
1241
+ output,
1242
+ http_response,
1243
+ ) = await capo_codedeploy._operations.code_deploy_20141006.delete_deployment_config.async_delete_deployment_config(
1244
+ req.options, req.input
1245
+ )
1246
+ return AsyncOperationResponse(output=output, response=http_response)
1247
+
1248
+ interceptors_, options_ = self.operation_options(config_overrides)
1249
+ input_: capo_codedeploy.types.delete_deployment_config_input.DeleteDeploymentConfigInput = {
1250
+ "deployment_config_name": deployment_config_name
1251
+ }
1252
+
1253
+ response = await aexecute_pipeline(
1254
+ AsyncOperationRequest(input=input_, options=options_),
1255
+ handler=_handler,
1256
+ interceptors=list(interceptors_),
1257
+ )
1258
+ await response.response.aclose()
1259
+ return response.output
1260
+
1261
+ async def delete_deployment_group(
1262
+ self,
1263
+ application_name: "capo_codedeploy.types.application_name.ApplicationName",
1264
+ deployment_group_name: "capo_codedeploy.types.deployment_group_name.DeploymentGroupName",
1265
+ *,
1266
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
1267
+ ) -> "capo_codedeploy.types.delete_deployment_group_output.DeleteDeploymentGroupOutput":
1268
+ """<p>Deletes a deployment group.</p>
1269
+
1270
+ Args:
1271
+ application_name: <p>The name of an CodeDeploy application associated with the user or Amazon Web Services account.</p>
1272
+ deployment_group_name: <p>The name of a deployment group for the specified application.</p>
1273
+
1274
+ Raises:
1275
+ capo_codedeploy.errors.application_name_required_exception.ApplicationNameRequiredException: <p>The minimum number of required application names was not specified.</p>
1276
+ capo_codedeploy.errors.deployment_group_name_required_exception.DeploymentGroupNameRequiredException: <p>The deployment group name was not specified.</p>
1277
+ capo_codedeploy.errors.invalid_application_name_exception.InvalidApplicationNameException: <p>The application name was specified in an invalid format.</p>
1278
+ capo_codedeploy.errors.invalid_deployment_group_name_exception.InvalidDeploymentGroupNameException: <p>The deployment group name was specified in an invalid format.</p>
1279
+ capo_codedeploy.errors.invalid_role_exception.InvalidRoleException: <p>The service role ARN was specified in an invalid format. Or, if an Auto Scaling group was specified, the specified service role does not grant the appropriate permissions to Amazon EC2 Auto Scaling.</p>
1280
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
1281
+ """
1282
+
1283
+ async def _handler(
1284
+ req: "AsyncOperationRequest[capo_codedeploy.types.delete_deployment_group_input.DeleteDeploymentGroupInput]",
1285
+ ) -> AsyncOperationResponse[
1286
+ "capo_codedeploy.types.delete_deployment_group_output.DeleteDeploymentGroupOutput"
1287
+ ]:
1288
+ import capo_codedeploy._operations.code_deploy_20141006.delete_deployment_group
1289
+
1290
+ (
1291
+ output,
1292
+ http_response,
1293
+ ) = await capo_codedeploy._operations.code_deploy_20141006.delete_deployment_group.async_delete_deployment_group(
1294
+ req.options, req.input
1295
+ )
1296
+ return AsyncOperationResponse(output=output, response=http_response)
1297
+
1298
+ interceptors_, options_ = self.operation_options(config_overrides)
1299
+ input_: capo_codedeploy.types.delete_deployment_group_input.DeleteDeploymentGroupInput = {
1300
+ "application_name": application_name,
1301
+ "deployment_group_name": deployment_group_name,
1302
+ }
1303
+
1304
+ response = await aexecute_pipeline(
1305
+ AsyncOperationRequest(input=input_, options=options_),
1306
+ handler=_handler,
1307
+ interceptors=list(interceptors_),
1308
+ )
1309
+ await response.response.aclose()
1310
+ return response.output
1311
+
1312
+ async def delete_git_hub_account_token(
1313
+ self,
1314
+ *,
1315
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
1316
+ token_name: Optional[
1317
+ "capo_codedeploy.types.git_hub_account_token_name.GitHubAccountTokenName"
1318
+ ] = None,
1319
+ ) -> "capo_codedeploy.types.delete_git_hub_account_token_output.DeleteGitHubAccountTokenOutput":
1320
+ """<p>Deletes a GitHub account connection.</p>
1321
+
1322
+ Args:
1323
+ token_name: <p>The name of the GitHub account connection to delete.</p>
1324
+
1325
+ Raises:
1326
+ capo_codedeploy.errors.git_hub_account_token_does_not_exist_exception.GitHubAccountTokenDoesNotExistException: <p>No GitHub account connection exists with the named specified in the call.</p>
1327
+ capo_codedeploy.errors.git_hub_account_token_name_required_exception.GitHubAccountTokenNameRequiredException: <p>The call is missing a required GitHub account connection name.</p>
1328
+ capo_codedeploy.errors.invalid_git_hub_account_token_name_exception.InvalidGitHubAccountTokenNameException: <p>The format of the specified GitHub account connection name is invalid.</p>
1329
+ capo_codedeploy.errors.operation_not_supported_exception.OperationNotSupportedException: <p>The API used does not support the deployment.</p>
1330
+ capo_codedeploy.errors.resource_validation_exception.ResourceValidationException: <p>The specified resource could not be validated.</p>
1331
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
1332
+ """
1333
+
1334
+ async def _handler(
1335
+ req: "AsyncOperationRequest[capo_codedeploy.types.delete_git_hub_account_token_input.DeleteGitHubAccountTokenInput]",
1336
+ ) -> AsyncOperationResponse[
1337
+ "capo_codedeploy.types.delete_git_hub_account_token_output.DeleteGitHubAccountTokenOutput"
1338
+ ]:
1339
+ import capo_codedeploy._operations.code_deploy_20141006.delete_git_hub_account_token
1340
+
1341
+ (
1342
+ output,
1343
+ http_response,
1344
+ ) = await capo_codedeploy._operations.code_deploy_20141006.delete_git_hub_account_token.async_delete_git_hub_account_token(
1345
+ req.options, req.input
1346
+ )
1347
+ return AsyncOperationResponse(output=output, response=http_response)
1348
+
1349
+ interceptors_, options_ = self.operation_options(config_overrides)
1350
+ input_: capo_codedeploy.types.delete_git_hub_account_token_input.DeleteGitHubAccountTokenInput = {}
1351
+ if token_name is not None:
1352
+ input_["token_name"] = token_name
1353
+
1354
+ response = await aexecute_pipeline(
1355
+ AsyncOperationRequest(input=input_, options=options_),
1356
+ handler=_handler,
1357
+ interceptors=list(interceptors_),
1358
+ )
1359
+ await response.response.aclose()
1360
+ return response.output
1361
+
1362
+ async def delete_resources_by_external_id(
1363
+ self,
1364
+ *,
1365
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
1366
+ external_id: Optional["capo_codedeploy.types.external_id.ExternalId"] = None,
1367
+ ) -> "capo_codedeploy.types.delete_resources_by_external_id_output.DeleteResourcesByExternalIdOutput":
1368
+ """<p>Deletes resources linked to an external ID. This action only applies if you have configured blue/green deployments through CloudFormation. </p> <note> <p>It is not necessary to call this action directly. CloudFormation calls it on your behalf when it needs to delete stack resources. This action is offered publicly in case you need to delete resources to comply with General Data Protection Regulation (GDPR) requirements.</p> </note>
1369
+
1370
+ Args:
1371
+ external_id: <p>The unique ID of an external resource (for example, a CloudFormation stack ID) that is linked to one or more CodeDeploy resources.</p>
1372
+
1373
+ Raises:
1374
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
1375
+ """
1376
+
1377
+ async def _handler(
1378
+ req: "AsyncOperationRequest[capo_codedeploy.types.delete_resources_by_external_id_input.DeleteResourcesByExternalIdInput]",
1379
+ ) -> AsyncOperationResponse[
1380
+ "capo_codedeploy.types.delete_resources_by_external_id_output.DeleteResourcesByExternalIdOutput"
1381
+ ]:
1382
+ import capo_codedeploy._operations.code_deploy_20141006.delete_resources_by_external_id
1383
+
1384
+ (
1385
+ output,
1386
+ http_response,
1387
+ ) = await capo_codedeploy._operations.code_deploy_20141006.delete_resources_by_external_id.async_delete_resources_by_external_id(
1388
+ req.options, req.input
1389
+ )
1390
+ return AsyncOperationResponse(output=output, response=http_response)
1391
+
1392
+ interceptors_, options_ = self.operation_options(config_overrides)
1393
+ input_: capo_codedeploy.types.delete_resources_by_external_id_input.DeleteResourcesByExternalIdInput = {}
1394
+ if external_id is not None:
1395
+ input_["external_id"] = external_id
1396
+
1397
+ response = await aexecute_pipeline(
1398
+ AsyncOperationRequest(input=input_, options=options_),
1399
+ handler=_handler,
1400
+ interceptors=list(interceptors_),
1401
+ )
1402
+ await response.response.aclose()
1403
+ return response.output
1404
+
1405
+ async def deregister_on_premises_instance(
1406
+ self,
1407
+ instance_name: "capo_codedeploy.types.instance_name.InstanceName",
1408
+ *,
1409
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
1410
+ ) -> None:
1411
+ """<p>Deregisters an on-premises instance.</p>
1412
+
1413
+ Args:
1414
+ instance_name: <p>The name of the on-premises instance to deregister.</p>
1415
+
1416
+ Raises:
1417
+ capo_codedeploy.errors.instance_name_required_exception.InstanceNameRequiredException: <p>An on-premises instance name was not specified.</p>
1418
+ capo_codedeploy.errors.invalid_instance_name_exception.InvalidInstanceNameException: <p>The on-premises instance name was specified in an invalid format.</p>
1419
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
1420
+ """
1421
+
1422
+ async def _handler(
1423
+ req: "AsyncOperationRequest[capo_codedeploy.types.deregister_on_premises_instance_input.DeregisterOnPremisesInstanceInput]",
1424
+ ) -> AsyncOperationResponse[None]:
1425
+ import capo_codedeploy._operations.code_deploy_20141006.deregister_on_premises_instance
1426
+
1427
+ (
1428
+ output,
1429
+ http_response,
1430
+ ) = await capo_codedeploy._operations.code_deploy_20141006.deregister_on_premises_instance.async_deregister_on_premises_instance(
1431
+ req.options, req.input
1432
+ )
1433
+ return AsyncOperationResponse(output=output, response=http_response)
1434
+
1435
+ interceptors_, options_ = self.operation_options(config_overrides)
1436
+ input_: capo_codedeploy.types.deregister_on_premises_instance_input.DeregisterOnPremisesInstanceInput = {
1437
+ "instance_name": instance_name
1438
+ }
1439
+
1440
+ response = await aexecute_pipeline(
1441
+ AsyncOperationRequest(input=input_, options=options_),
1442
+ handler=_handler,
1443
+ interceptors=list(interceptors_),
1444
+ )
1445
+ await response.response.aclose()
1446
+ return response.output
1447
+
1448
+ async def get_application(
1449
+ self,
1450
+ application_name: "capo_codedeploy.types.application_name.ApplicationName",
1451
+ *,
1452
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
1453
+ ) -> "capo_codedeploy.types.get_application_output.GetApplicationOutput":
1454
+ """<p>Gets information about an application.</p>
1455
+
1456
+ Args:
1457
+ application_name: <p>The name of an CodeDeploy application associated with the user or Amazon Web Services account.</p>
1458
+
1459
+ Raises:
1460
+ capo_codedeploy.errors.application_does_not_exist_exception.ApplicationDoesNotExistException: <p>The application does not exist with the user or Amazon Web Services account.</p>
1461
+ capo_codedeploy.errors.application_name_required_exception.ApplicationNameRequiredException: <p>The minimum number of required application names was not specified.</p>
1462
+ capo_codedeploy.errors.invalid_application_name_exception.InvalidApplicationNameException: <p>The application name was specified in an invalid format.</p>
1463
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
1464
+ """
1465
+
1466
+ async def _handler(
1467
+ req: "AsyncOperationRequest[capo_codedeploy.types.get_application_input.GetApplicationInput]",
1468
+ ) -> AsyncOperationResponse[
1469
+ "capo_codedeploy.types.get_application_output.GetApplicationOutput"
1470
+ ]:
1471
+ import capo_codedeploy._operations.code_deploy_20141006.get_application
1472
+
1473
+ (
1474
+ output,
1475
+ http_response,
1476
+ ) = await capo_codedeploy._operations.code_deploy_20141006.get_application.async_get_application(
1477
+ req.options, req.input
1478
+ )
1479
+ return AsyncOperationResponse(output=output, response=http_response)
1480
+
1481
+ interceptors_, options_ = self.operation_options(config_overrides)
1482
+ input_: capo_codedeploy.types.get_application_input.GetApplicationInput = {
1483
+ "application_name": application_name
1484
+ }
1485
+
1486
+ response = await aexecute_pipeline(
1487
+ AsyncOperationRequest(input=input_, options=options_),
1488
+ handler=_handler,
1489
+ interceptors=list(interceptors_),
1490
+ )
1491
+ await response.response.aclose()
1492
+ return response.output
1493
+
1494
+ async def get_application_revision(
1495
+ self,
1496
+ application_name: "capo_codedeploy.types.application_name.ApplicationName",
1497
+ revision: "capo_codedeploy.types.revision_location.RevisionLocation",
1498
+ *,
1499
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
1500
+ ) -> "capo_codedeploy.types.get_application_revision_output.GetApplicationRevisionOutput":
1501
+ """<p>Gets information about an application revision.</p>
1502
+
1503
+ Args:
1504
+ application_name: <p>The name of the application that corresponds to the revision.</p>
1505
+ revision: <p>Information about the application revision to get, including type and location.</p>
1506
+
1507
+ Raises:
1508
+ capo_codedeploy.errors.application_does_not_exist_exception.ApplicationDoesNotExistException: <p>The application does not exist with the user or Amazon Web Services account.</p>
1509
+ capo_codedeploy.errors.application_name_required_exception.ApplicationNameRequiredException: <p>The minimum number of required application names was not specified.</p>
1510
+ capo_codedeploy.errors.invalid_application_name_exception.InvalidApplicationNameException: <p>The application name was specified in an invalid format.</p>
1511
+ capo_codedeploy.errors.invalid_revision_exception.InvalidRevisionException: <p>The revision was specified in an invalid format.</p>
1512
+ capo_codedeploy.errors.revision_does_not_exist_exception.RevisionDoesNotExistException: <p>The named revision does not exist with the user or Amazon Web Services account.</p>
1513
+ capo_codedeploy.errors.revision_required_exception.RevisionRequiredException: <p>The revision ID was not specified.</p>
1514
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
1515
+ """
1516
+
1517
+ async def _handler(
1518
+ req: "AsyncOperationRequest[capo_codedeploy.types.get_application_revision_input.GetApplicationRevisionInput]",
1519
+ ) -> AsyncOperationResponse[
1520
+ "capo_codedeploy.types.get_application_revision_output.GetApplicationRevisionOutput"
1521
+ ]:
1522
+ import capo_codedeploy._operations.code_deploy_20141006.get_application_revision
1523
+
1524
+ (
1525
+ output,
1526
+ http_response,
1527
+ ) = await capo_codedeploy._operations.code_deploy_20141006.get_application_revision.async_get_application_revision(
1528
+ req.options, req.input
1529
+ )
1530
+ return AsyncOperationResponse(output=output, response=http_response)
1531
+
1532
+ interceptors_, options_ = self.operation_options(config_overrides)
1533
+ input_: capo_codedeploy.types.get_application_revision_input.GetApplicationRevisionInput = {
1534
+ "application_name": application_name,
1535
+ "revision": revision,
1536
+ }
1537
+
1538
+ response = await aexecute_pipeline(
1539
+ AsyncOperationRequest(input=input_, options=options_),
1540
+ handler=_handler,
1541
+ interceptors=list(interceptors_),
1542
+ )
1543
+ await response.response.aclose()
1544
+ return response.output
1545
+
1546
+ async def get_deployment(
1547
+ self,
1548
+ deployment_id: "capo_codedeploy.types.deployment_id.DeploymentId",
1549
+ *,
1550
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
1551
+ ) -> "capo_codedeploy.types.get_deployment_output.GetDeploymentOutput":
1552
+ """<p>Gets information about a deployment.</p> <note> <p> The <code>content</code> property of the <code>appSpecContent</code> object in the returned revision is always null. Use <code>GetApplicationRevision</code> and the <code>sha256</code> property of the returned <code>appSpecContent</code> object to get the content of the deployment’s AppSpec file. </p> </note>
1553
+
1554
+ Args:
1555
+ deployment_id: <p> The unique ID of a deployment associated with the user or Amazon Web Services account. </p>
1556
+
1557
+ Raises:
1558
+ capo_codedeploy.errors.deployment_does_not_exist_exception.DeploymentDoesNotExistException: <p>The deployment with the user or Amazon Web Services account does not exist.</p>
1559
+ capo_codedeploy.errors.deployment_id_required_exception.DeploymentIdRequiredException: <p>At least one deployment ID must be specified.</p>
1560
+ capo_codedeploy.errors.invalid_deployment_id_exception.InvalidDeploymentIdException: <p>At least one of the deployment IDs was specified in an invalid format.</p>
1561
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
1562
+ """
1563
+
1564
+ async def _handler(
1565
+ req: "AsyncOperationRequest[capo_codedeploy.types.get_deployment_input.GetDeploymentInput]",
1566
+ ) -> AsyncOperationResponse[
1567
+ "capo_codedeploy.types.get_deployment_output.GetDeploymentOutput"
1568
+ ]:
1569
+ import capo_codedeploy._operations.code_deploy_20141006.get_deployment
1570
+
1571
+ (
1572
+ output,
1573
+ http_response,
1574
+ ) = await capo_codedeploy._operations.code_deploy_20141006.get_deployment.async_get_deployment(
1575
+ req.options, req.input
1576
+ )
1577
+ return AsyncOperationResponse(output=output, response=http_response)
1578
+
1579
+ interceptors_, options_ = self.operation_options(config_overrides)
1580
+ input_: capo_codedeploy.types.get_deployment_input.GetDeploymentInput = {
1581
+ "deployment_id": deployment_id
1582
+ }
1583
+
1584
+ response = await aexecute_pipeline(
1585
+ AsyncOperationRequest(input=input_, options=options_),
1586
+ handler=_handler,
1587
+ interceptors=list(interceptors_),
1588
+ )
1589
+ await response.response.aclose()
1590
+ return response.output
1591
+
1592
+ async def get_deployment_config(
1593
+ self,
1594
+ deployment_config_name: "capo_codedeploy.types.deployment_config_name.DeploymentConfigName",
1595
+ *,
1596
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
1597
+ ) -> "capo_codedeploy.types.get_deployment_config_output.GetDeploymentConfigOutput":
1598
+ """<p>Gets information about a deployment configuration.</p>
1599
+
1600
+ Args:
1601
+ deployment_config_name: <p>The name of a deployment configuration associated with the user or Amazon Web Services account.</p>
1602
+
1603
+ Raises:
1604
+ capo_codedeploy.errors.deployment_config_does_not_exist_exception.DeploymentConfigDoesNotExistException: <p>The deployment configuration does not exist with the user or Amazon Web Services account.</p>
1605
+ capo_codedeploy.errors.deployment_config_name_required_exception.DeploymentConfigNameRequiredException: <p>The deployment configuration name was not specified.</p>
1606
+ capo_codedeploy.errors.invalid_compute_platform_exception.InvalidComputePlatformException: <p>The computePlatform is invalid. The computePlatform should be <code>Lambda</code>, <code>Server</code>, or <code>ECS</code>.</p>
1607
+ capo_codedeploy.errors.invalid_deployment_config_name_exception.InvalidDeploymentConfigNameException: <p>The deployment configuration name was specified in an invalid format.</p>
1608
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
1609
+ """
1610
+
1611
+ async def _handler(
1612
+ req: "AsyncOperationRequest[capo_codedeploy.types.get_deployment_config_input.GetDeploymentConfigInput]",
1613
+ ) -> AsyncOperationResponse[
1614
+ "capo_codedeploy.types.get_deployment_config_output.GetDeploymentConfigOutput"
1615
+ ]:
1616
+ import capo_codedeploy._operations.code_deploy_20141006.get_deployment_config
1617
+
1618
+ (
1619
+ output,
1620
+ http_response,
1621
+ ) = await capo_codedeploy._operations.code_deploy_20141006.get_deployment_config.async_get_deployment_config(
1622
+ req.options, req.input
1623
+ )
1624
+ return AsyncOperationResponse(output=output, response=http_response)
1625
+
1626
+ interceptors_, options_ = self.operation_options(config_overrides)
1627
+ input_: capo_codedeploy.types.get_deployment_config_input.GetDeploymentConfigInput = {
1628
+ "deployment_config_name": deployment_config_name
1629
+ }
1630
+
1631
+ response = await aexecute_pipeline(
1632
+ AsyncOperationRequest(input=input_, options=options_),
1633
+ handler=_handler,
1634
+ interceptors=list(interceptors_),
1635
+ )
1636
+ await response.response.aclose()
1637
+ return response.output
1638
+
1639
+ async def get_deployment_group(
1640
+ self,
1641
+ application_name: "capo_codedeploy.types.application_name.ApplicationName",
1642
+ deployment_group_name: "capo_codedeploy.types.deployment_group_name.DeploymentGroupName",
1643
+ *,
1644
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
1645
+ ) -> "capo_codedeploy.types.get_deployment_group_output.GetDeploymentGroupOutput":
1646
+ """<p>Gets information about a deployment group.</p>
1647
+
1648
+ Args:
1649
+ application_name: <p>The name of an CodeDeploy application associated with the user or Amazon Web Services account.</p>
1650
+ deployment_group_name: <p>The name of a deployment group for the specified application.</p>
1651
+
1652
+ Raises:
1653
+ capo_codedeploy.errors.application_does_not_exist_exception.ApplicationDoesNotExistException: <p>The application does not exist with the user or Amazon Web Services account.</p>
1654
+ capo_codedeploy.errors.application_name_required_exception.ApplicationNameRequiredException: <p>The minimum number of required application names was not specified.</p>
1655
+ capo_codedeploy.errors.deployment_config_does_not_exist_exception.DeploymentConfigDoesNotExistException: <p>The deployment configuration does not exist with the user or Amazon Web Services account.</p>
1656
+ capo_codedeploy.errors.deployment_group_does_not_exist_exception.DeploymentGroupDoesNotExistException: <p>The named deployment group with the user or Amazon Web Services account does not exist.</p>
1657
+ capo_codedeploy.errors.deployment_group_name_required_exception.DeploymentGroupNameRequiredException: <p>The deployment group name was not specified.</p>
1658
+ capo_codedeploy.errors.invalid_application_name_exception.InvalidApplicationNameException: <p>The application name was specified in an invalid format.</p>
1659
+ capo_codedeploy.errors.invalid_deployment_group_name_exception.InvalidDeploymentGroupNameException: <p>The deployment group name was specified in an invalid format.</p>
1660
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
1661
+ """
1662
+
1663
+ async def _handler(
1664
+ req: "AsyncOperationRequest[capo_codedeploy.types.get_deployment_group_input.GetDeploymentGroupInput]",
1665
+ ) -> AsyncOperationResponse[
1666
+ "capo_codedeploy.types.get_deployment_group_output.GetDeploymentGroupOutput"
1667
+ ]:
1668
+ import capo_codedeploy._operations.code_deploy_20141006.get_deployment_group
1669
+
1670
+ (
1671
+ output,
1672
+ http_response,
1673
+ ) = await capo_codedeploy._operations.code_deploy_20141006.get_deployment_group.async_get_deployment_group(
1674
+ req.options, req.input
1675
+ )
1676
+ return AsyncOperationResponse(output=output, response=http_response)
1677
+
1678
+ interceptors_, options_ = self.operation_options(config_overrides)
1679
+ input_: capo_codedeploy.types.get_deployment_group_input.GetDeploymentGroupInput = {
1680
+ "application_name": application_name,
1681
+ "deployment_group_name": deployment_group_name,
1682
+ }
1683
+
1684
+ response = await aexecute_pipeline(
1685
+ AsyncOperationRequest(input=input_, options=options_),
1686
+ handler=_handler,
1687
+ interceptors=list(interceptors_),
1688
+ )
1689
+ await response.response.aclose()
1690
+ return response.output
1691
+
1692
+ async def get_deployment_instance(
1693
+ self,
1694
+ deployment_id: "capo_codedeploy.types.deployment_id.DeploymentId",
1695
+ instance_id: "capo_codedeploy.types.instance_id.InstanceId",
1696
+ *,
1697
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
1698
+ ) -> "capo_codedeploy.types.get_deployment_instance_output.GetDeploymentInstanceOutput":
1699
+ """<p>Gets information about an instance as part of a deployment.</p>
1700
+
1701
+ Args:
1702
+ deployment_id: <p> The unique ID of a deployment. </p>
1703
+ instance_id: <p> The unique ID of an instance in the deployment group. </p>
1704
+
1705
+ Raises:
1706
+ capo_codedeploy.errors.deployment_does_not_exist_exception.DeploymentDoesNotExistException: <p>The deployment with the user or Amazon Web Services account does not exist.</p>
1707
+ capo_codedeploy.errors.deployment_id_required_exception.DeploymentIdRequiredException: <p>At least one deployment ID must be specified.</p>
1708
+ capo_codedeploy.errors.instance_does_not_exist_exception.InstanceDoesNotExistException: <p>The specified instance does not exist in the deployment group.</p>
1709
+ capo_codedeploy.errors.instance_id_required_exception.InstanceIdRequiredException: <p>The instance ID was not specified.</p>
1710
+ capo_codedeploy.errors.invalid_compute_platform_exception.InvalidComputePlatformException: <p>The computePlatform is invalid. The computePlatform should be <code>Lambda</code>, <code>Server</code>, or <code>ECS</code>.</p>
1711
+ capo_codedeploy.errors.invalid_deployment_id_exception.InvalidDeploymentIdException: <p>At least one of the deployment IDs was specified in an invalid format.</p>
1712
+ capo_codedeploy.errors.invalid_instance_name_exception.InvalidInstanceNameException: <p>The on-premises instance name was specified in an invalid format.</p>
1713
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
1714
+ """
1715
+
1716
+ async def _handler(
1717
+ req: "AsyncOperationRequest[capo_codedeploy.types.get_deployment_instance_input.GetDeploymentInstanceInput]",
1718
+ ) -> AsyncOperationResponse[
1719
+ "capo_codedeploy.types.get_deployment_instance_output.GetDeploymentInstanceOutput"
1720
+ ]:
1721
+ import capo_codedeploy._operations.code_deploy_20141006.get_deployment_instance
1722
+
1723
+ (
1724
+ output,
1725
+ http_response,
1726
+ ) = await capo_codedeploy._operations.code_deploy_20141006.get_deployment_instance.async_get_deployment_instance(
1727
+ req.options, req.input
1728
+ )
1729
+ return AsyncOperationResponse(output=output, response=http_response)
1730
+
1731
+ interceptors_, options_ = self.operation_options(config_overrides)
1732
+ input_: capo_codedeploy.types.get_deployment_instance_input.GetDeploymentInstanceInput = {
1733
+ "deployment_id": deployment_id,
1734
+ "instance_id": instance_id,
1735
+ }
1736
+
1737
+ response = await aexecute_pipeline(
1738
+ AsyncOperationRequest(input=input_, options=options_),
1739
+ handler=_handler,
1740
+ interceptors=list(interceptors_),
1741
+ )
1742
+ await response.response.aclose()
1743
+ return response.output
1744
+
1745
+ async def get_deployment_target(
1746
+ self,
1747
+ deployment_id: "capo_codedeploy.types.deployment_id.DeploymentId",
1748
+ target_id: "capo_codedeploy.types.target_id.TargetId",
1749
+ *,
1750
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
1751
+ ) -> "capo_codedeploy.types.get_deployment_target_output.GetDeploymentTargetOutput":
1752
+ """<p> Returns information about a deployment target. </p>
1753
+
1754
+ Args:
1755
+ deployment_id: <p> The unique ID of a deployment. </p>
1756
+ target_id: <p> The unique ID of a deployment target. </p>
1757
+
1758
+ Raises:
1759
+ capo_codedeploy.errors.deployment_does_not_exist_exception.DeploymentDoesNotExistException: <p>The deployment with the user or Amazon Web Services account does not exist.</p>
1760
+ capo_codedeploy.errors.deployment_id_required_exception.DeploymentIdRequiredException: <p>At least one deployment ID must be specified.</p>
1761
+ capo_codedeploy.errors.deployment_not_started_exception.DeploymentNotStartedException: <p>The specified deployment has not started.</p>
1762
+ capo_codedeploy.errors.deployment_target_does_not_exist_exception.DeploymentTargetDoesNotExistException: <p> The provided target ID does not belong to the attempted deployment. </p>
1763
+ capo_codedeploy.errors.deployment_target_id_required_exception.DeploymentTargetIdRequiredException: <p> A deployment target ID was not provided. </p>
1764
+ capo_codedeploy.errors.invalid_deployment_id_exception.InvalidDeploymentIdException: <p>At least one of the deployment IDs was specified in an invalid format.</p>
1765
+ capo_codedeploy.errors.invalid_deployment_target_id_exception.InvalidDeploymentTargetIdException: <p> The target ID provided was not valid. </p>
1766
+ capo_codedeploy.errors.invalid_instance_name_exception.InvalidInstanceNameException: <p>The on-premises instance name was specified in an invalid format.</p>
1767
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
1768
+ """
1769
+
1770
+ async def _handler(
1771
+ req: "AsyncOperationRequest[capo_codedeploy.types.get_deployment_target_input.GetDeploymentTargetInput]",
1772
+ ) -> AsyncOperationResponse[
1773
+ "capo_codedeploy.types.get_deployment_target_output.GetDeploymentTargetOutput"
1774
+ ]:
1775
+ import capo_codedeploy._operations.code_deploy_20141006.get_deployment_target
1776
+
1777
+ (
1778
+ output,
1779
+ http_response,
1780
+ ) = await capo_codedeploy._operations.code_deploy_20141006.get_deployment_target.async_get_deployment_target(
1781
+ req.options, req.input
1782
+ )
1783
+ return AsyncOperationResponse(output=output, response=http_response)
1784
+
1785
+ interceptors_, options_ = self.operation_options(config_overrides)
1786
+ input_: capo_codedeploy.types.get_deployment_target_input.GetDeploymentTargetInput = {
1787
+ "deployment_id": deployment_id,
1788
+ "target_id": target_id,
1789
+ }
1790
+
1791
+ response = await aexecute_pipeline(
1792
+ AsyncOperationRequest(input=input_, options=options_),
1793
+ handler=_handler,
1794
+ interceptors=list(interceptors_),
1795
+ )
1796
+ await response.response.aclose()
1797
+ return response.output
1798
+
1799
+ async def get_on_premises_instance(
1800
+ self,
1801
+ instance_name: "capo_codedeploy.types.instance_name.InstanceName",
1802
+ *,
1803
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
1804
+ ) -> "capo_codedeploy.types.get_on_premises_instance_output.GetOnPremisesInstanceOutput":
1805
+ """<p> Gets information about an on-premises instance. </p>
1806
+
1807
+ Args:
1808
+ instance_name: <p> The name of the on-premises instance about which to get information. </p>
1809
+
1810
+ Raises:
1811
+ capo_codedeploy.errors.instance_name_required_exception.InstanceNameRequiredException: <p>An on-premises instance name was not specified.</p>
1812
+ capo_codedeploy.errors.instance_not_registered_exception.InstanceNotRegisteredException: <p>The specified on-premises instance is not registered.</p>
1813
+ capo_codedeploy.errors.invalid_instance_name_exception.InvalidInstanceNameException: <p>The on-premises instance name was specified in an invalid format.</p>
1814
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
1815
+ """
1816
+
1817
+ async def _handler(
1818
+ req: "AsyncOperationRequest[capo_codedeploy.types.get_on_premises_instance_input.GetOnPremisesInstanceInput]",
1819
+ ) -> AsyncOperationResponse[
1820
+ "capo_codedeploy.types.get_on_premises_instance_output.GetOnPremisesInstanceOutput"
1821
+ ]:
1822
+ import capo_codedeploy._operations.code_deploy_20141006.get_on_premises_instance
1823
+
1824
+ (
1825
+ output,
1826
+ http_response,
1827
+ ) = await capo_codedeploy._operations.code_deploy_20141006.get_on_premises_instance.async_get_on_premises_instance(
1828
+ req.options, req.input
1829
+ )
1830
+ return AsyncOperationResponse(output=output, response=http_response)
1831
+
1832
+ interceptors_, options_ = self.operation_options(config_overrides)
1833
+ input_: capo_codedeploy.types.get_on_premises_instance_input.GetOnPremisesInstanceInput = {
1834
+ "instance_name": instance_name
1835
+ }
1836
+
1837
+ response = await aexecute_pipeline(
1838
+ AsyncOperationRequest(input=input_, options=options_),
1839
+ handler=_handler,
1840
+ interceptors=list(interceptors_),
1841
+ )
1842
+ await response.response.aclose()
1843
+ return response.output
1844
+
1845
+ async def list_application_revisions(
1846
+ self,
1847
+ application_name: "capo_codedeploy.types.application_name.ApplicationName",
1848
+ *,
1849
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
1850
+ sort_by: Optional[
1851
+ "capo_codedeploy.types.application_revision_sort_by.ApplicationRevisionSortBy"
1852
+ ] = None,
1853
+ sort_order: Optional["capo_codedeploy.types.sort_order.SortOrder"] = None,
1854
+ s3_bucket: Optional["capo_codedeploy.types.s3_bucket.S3Bucket"] = None,
1855
+ s3_key_prefix: Optional["capo_codedeploy.types.s3_key.S3Key"] = None,
1856
+ deployed: Optional[
1857
+ "capo_codedeploy.types.list_state_filter_action.ListStateFilterAction"
1858
+ ] = None,
1859
+ next_token: Optional["capo_codedeploy.types.next_token.NextToken"] = None,
1860
+ ) -> "capo_codedeploy.types.list_application_revisions_output.ListApplicationRevisionsOutput":
1861
+ """<p>Lists information about revisions for an application.</p>
1862
+
1863
+ Args:
1864
+ application_name: <p> The name of an CodeDeploy application associated with the user or Amazon Web Services account. </p>
1865
+ sort_by: <p>The column name to use to sort the list results:</p> <ul> <li> <p> <code>registerTime</code>: Sort by the time the revisions were registered with CodeDeploy.</p> </li> <li> <p> <code>firstUsedTime</code>: Sort by the time the revisions were first used in a deployment.</p> </li> <li> <p> <code>lastUsedTime</code>: Sort by the time the revisions were last used in a deployment.</p> </li> </ul> <p> If not specified or set to null, the results are returned in an arbitrary order. </p>
1866
+ sort_order: <p> The order in which to sort the list results: </p> <ul> <li> <p> <code>ascending</code>: ascending order.</p> </li> <li> <p> <code>descending</code>: descending order.</p> </li> </ul> <p>If not specified, the results are sorted in ascending order.</p> <p>If set to null, the results are sorted in an arbitrary order.</p>
1867
+ s3_bucket: <p> An Amazon S3 bucket name to limit the search for revisions. </p> <p> If set to null, all of the user's buckets are searched. </p>
1868
+ s3_key_prefix: <p> A key prefix for the set of Amazon S3 objects to limit the search for revisions. </p>
1869
+ deployed: <p> Whether to list revisions based on whether the revision is the target revision of a deployment group: </p> <ul> <li> <p> <code>include</code>: List revisions that are target revisions of a deployment group.</p> </li> <li> <p> <code>exclude</code>: Do not list revisions that are target revisions of a deployment group.</p> </li> <li> <p> <code>ignore</code>: List all revisions.</p> </li> </ul>
1870
+ next_token: <p>An identifier returned from the previous <code>ListApplicationRevisions</code> call. It can be used to return the next set of applications in the list.</p>
1871
+
1872
+ Raises:
1873
+ capo_codedeploy.errors.application_does_not_exist_exception.ApplicationDoesNotExistException: <p>The application does not exist with the user or Amazon Web Services account.</p>
1874
+ capo_codedeploy.errors.application_name_required_exception.ApplicationNameRequiredException: <p>The minimum number of required application names was not specified.</p>
1875
+ capo_codedeploy.errors.bucket_name_filter_required_exception.BucketNameFilterRequiredException: <p>A bucket name is required, but was not provided.</p>
1876
+ capo_codedeploy.errors.invalid_application_name_exception.InvalidApplicationNameException: <p>The application name was specified in an invalid format.</p>
1877
+ capo_codedeploy.errors.invalid_bucket_name_filter_exception.InvalidBucketNameFilterException: <p>The bucket name either doesn't exist or was specified in an invalid format.</p>
1878
+ capo_codedeploy.errors.invalid_deployed_state_filter_exception.InvalidDeployedStateFilterException: <p>The deployed state filter was specified in an invalid format.</p>
1879
+ capo_codedeploy.errors.invalid_key_prefix_filter_exception.InvalidKeyPrefixFilterException: <p>The specified key prefix filter was specified in an invalid format.</p>
1880
+ capo_codedeploy.errors.invalid_next_token_exception.InvalidNextTokenException: <p>The next token was specified in an invalid format.</p>
1881
+ capo_codedeploy.errors.invalid_sort_by_exception.InvalidSortByException: <p>The column name to sort by is either not present or was specified in an invalid format.</p>
1882
+ capo_codedeploy.errors.invalid_sort_order_exception.InvalidSortOrderException: <p>The sort order was specified in an invalid format.</p>
1883
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
1884
+ """
1885
+
1886
+ async def _handler(
1887
+ req: "AsyncOperationRequest[capo_codedeploy.types.list_application_revisions_input.ListApplicationRevisionsInput]",
1888
+ ) -> AsyncOperationResponse[
1889
+ "capo_codedeploy.types.list_application_revisions_output.ListApplicationRevisionsOutput"
1890
+ ]:
1891
+ import capo_codedeploy._operations.code_deploy_20141006.list_application_revisions
1892
+
1893
+ (
1894
+ output,
1895
+ http_response,
1896
+ ) = await capo_codedeploy._operations.code_deploy_20141006.list_application_revisions.async_list_application_revisions(
1897
+ req.options, req.input
1898
+ )
1899
+ return AsyncOperationResponse(output=output, response=http_response)
1900
+
1901
+ interceptors_, options_ = self.operation_options(config_overrides)
1902
+ input_: capo_codedeploy.types.list_application_revisions_input.ListApplicationRevisionsInput = {
1903
+ "application_name": application_name
1904
+ }
1905
+ if sort_by is not None:
1906
+ input_["sort_by"] = sort_by
1907
+ if sort_order is not None:
1908
+ input_["sort_order"] = sort_order
1909
+ if s3_bucket is not None:
1910
+ input_["s3_bucket"] = s3_bucket
1911
+ if s3_key_prefix is not None:
1912
+ input_["s3_key_prefix"] = s3_key_prefix
1913
+ if deployed is not None:
1914
+ input_["deployed"] = deployed
1915
+ if next_token is not None:
1916
+ input_["next_token"] = next_token
1917
+
1918
+ response = await aexecute_pipeline(
1919
+ AsyncOperationRequest(input=input_, options=options_),
1920
+ handler=_handler,
1921
+ interceptors=list(interceptors_),
1922
+ )
1923
+ await response.response.aclose()
1924
+ return response.output
1925
+
1926
+ async def iter_list_application_revisions(
1927
+ self,
1928
+ application_name: "capo_codedeploy.types.application_name.ApplicationName",
1929
+ *,
1930
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
1931
+ sort_by: Optional[
1932
+ "capo_codedeploy.types.application_revision_sort_by.ApplicationRevisionSortBy"
1933
+ ] = None,
1934
+ sort_order: Optional["capo_codedeploy.types.sort_order.SortOrder"] = None,
1935
+ s3_bucket: Optional["capo_codedeploy.types.s3_bucket.S3Bucket"] = None,
1936
+ s3_key_prefix: Optional["capo_codedeploy.types.s3_key.S3Key"] = None,
1937
+ deployed: Optional[
1938
+ "capo_codedeploy.types.list_state_filter_action.ListStateFilterAction"
1939
+ ] = None,
1940
+ next_token: Optional["capo_codedeploy.types.next_token.NextToken"] = None,
1941
+ ) -> "AsyncIterator[capo_codedeploy.types.revision_location.RevisionLocation]":
1942
+ _token = next_token
1943
+ while True:
1944
+ _response = await self.list_application_revisions(
1945
+ application_name,
1946
+ config_overrides=config_overrides,
1947
+ sort_by=sort_by,
1948
+ sort_order=sort_order,
1949
+ s3_bucket=s3_bucket,
1950
+ s3_key_prefix=s3_key_prefix,
1951
+ deployed=deployed,
1952
+ next_token=_token,
1953
+ )
1954
+ _page = _resolve_path(_response, ("revisions",))
1955
+ for _item in _page or []:
1956
+ yield _item
1957
+ _token = _resolve_path(_response, ("next_token",))
1958
+ if not _token:
1959
+ break
1960
+
1961
+ async def list_applications(
1962
+ self,
1963
+ *,
1964
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
1965
+ next_token: Optional["capo_codedeploy.types.next_token.NextToken"] = None,
1966
+ ) -> "capo_codedeploy.types.list_applications_output.ListApplicationsOutput":
1967
+ """<p>Lists the applications registered with the user or Amazon Web Services account.</p>
1968
+
1969
+ Args:
1970
+ next_token: <p>An identifier returned from the previous list applications call. It can be used to return the next set of applications in the list.</p>
1971
+
1972
+ Raises:
1973
+ capo_codedeploy.errors.invalid_next_token_exception.InvalidNextTokenException: <p>The next token was specified in an invalid format.</p>
1974
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
1975
+ """
1976
+
1977
+ async def _handler(
1978
+ req: "AsyncOperationRequest[capo_codedeploy.types.list_applications_input.ListApplicationsInput]",
1979
+ ) -> AsyncOperationResponse[
1980
+ "capo_codedeploy.types.list_applications_output.ListApplicationsOutput"
1981
+ ]:
1982
+ import capo_codedeploy._operations.code_deploy_20141006.list_applications
1983
+
1984
+ (
1985
+ output,
1986
+ http_response,
1987
+ ) = await capo_codedeploy._operations.code_deploy_20141006.list_applications.async_list_applications(
1988
+ req.options, req.input
1989
+ )
1990
+ return AsyncOperationResponse(output=output, response=http_response)
1991
+
1992
+ interceptors_, options_ = self.operation_options(config_overrides)
1993
+ input_: capo_codedeploy.types.list_applications_input.ListApplicationsInput = {}
1994
+ if next_token is not None:
1995
+ input_["next_token"] = next_token
1996
+
1997
+ response = await aexecute_pipeline(
1998
+ AsyncOperationRequest(input=input_, options=options_),
1999
+ handler=_handler,
2000
+ interceptors=list(interceptors_),
2001
+ )
2002
+ await response.response.aclose()
2003
+ return response.output
2004
+
2005
+ async def iter_list_applications(
2006
+ self,
2007
+ *,
2008
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2009
+ next_token: Optional["capo_codedeploy.types.next_token.NextToken"] = None,
2010
+ ) -> "AsyncIterator[capo_codedeploy.types.application_name.ApplicationName]":
2011
+ _token = next_token
2012
+ while True:
2013
+ _response = await self.list_applications(
2014
+ config_overrides=config_overrides,
2015
+ next_token=_token,
2016
+ )
2017
+ _page = _resolve_path(_response, ("applications",))
2018
+ for _item in _page or []:
2019
+ yield _item
2020
+ _token = _resolve_path(_response, ("next_token",))
2021
+ if not _token:
2022
+ break
2023
+
2024
+ async def list_deployment_configs(
2025
+ self,
2026
+ *,
2027
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2028
+ next_token: Optional["capo_codedeploy.types.next_token.NextToken"] = None,
2029
+ ) -> "capo_codedeploy.types.list_deployment_configs_output.ListDeploymentConfigsOutput":
2030
+ """<p>Lists the deployment configurations with the user or Amazon Web Services account.</p>
2031
+
2032
+ Args:
2033
+ next_token: <p>An identifier returned from the previous <code>ListDeploymentConfigs</code> call. It can be used to return the next set of deployment configurations in the list. </p>
2034
+
2035
+ Raises:
2036
+ capo_codedeploy.errors.invalid_next_token_exception.InvalidNextTokenException: <p>The next token was specified in an invalid format.</p>
2037
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
2038
+ """
2039
+
2040
+ async def _handler(
2041
+ req: "AsyncOperationRequest[capo_codedeploy.types.list_deployment_configs_input.ListDeploymentConfigsInput]",
2042
+ ) -> AsyncOperationResponse[
2043
+ "capo_codedeploy.types.list_deployment_configs_output.ListDeploymentConfigsOutput"
2044
+ ]:
2045
+ import capo_codedeploy._operations.code_deploy_20141006.list_deployment_configs
2046
+
2047
+ (
2048
+ output,
2049
+ http_response,
2050
+ ) = await capo_codedeploy._operations.code_deploy_20141006.list_deployment_configs.async_list_deployment_configs(
2051
+ req.options, req.input
2052
+ )
2053
+ return AsyncOperationResponse(output=output, response=http_response)
2054
+
2055
+ interceptors_, options_ = self.operation_options(config_overrides)
2056
+ input_: capo_codedeploy.types.list_deployment_configs_input.ListDeploymentConfigsInput = {}
2057
+ if next_token is not None:
2058
+ input_["next_token"] = next_token
2059
+
2060
+ response = await aexecute_pipeline(
2061
+ AsyncOperationRequest(input=input_, options=options_),
2062
+ handler=_handler,
2063
+ interceptors=list(interceptors_),
2064
+ )
2065
+ await response.response.aclose()
2066
+ return response.output
2067
+
2068
+ async def iter_list_deployment_configs(
2069
+ self,
2070
+ *,
2071
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2072
+ next_token: Optional["capo_codedeploy.types.next_token.NextToken"] = None,
2073
+ ) -> "AsyncIterator[capo_codedeploy.types.deployment_config_name.DeploymentConfigName]":
2074
+ _token = next_token
2075
+ while True:
2076
+ _response = await self.list_deployment_configs(
2077
+ config_overrides=config_overrides,
2078
+ next_token=_token,
2079
+ )
2080
+ _page = _resolve_path(_response, ("deployment_configs_list",))
2081
+ for _item in _page or []:
2082
+ yield _item
2083
+ _token = _resolve_path(_response, ("next_token",))
2084
+ if not _token:
2085
+ break
2086
+
2087
+ async def list_deployment_groups(
2088
+ self,
2089
+ application_name: "capo_codedeploy.types.application_name.ApplicationName",
2090
+ *,
2091
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2092
+ next_token: Optional["capo_codedeploy.types.next_token.NextToken"] = None,
2093
+ ) -> (
2094
+ "capo_codedeploy.types.list_deployment_groups_output.ListDeploymentGroupsOutput"
2095
+ ):
2096
+ """<p>Lists the deployment groups for an application registered with the Amazon Web Services user or Amazon Web Services account.</p>
2097
+
2098
+ Args:
2099
+ application_name: <p>The name of an CodeDeploy application associated with the user or Amazon Web Services account.</p>
2100
+ next_token: <p>An identifier returned from the previous list deployment groups call. It can be used to return the next set of deployment groups in the list.</p>
2101
+
2102
+ Raises:
2103
+ capo_codedeploy.errors.application_does_not_exist_exception.ApplicationDoesNotExistException: <p>The application does not exist with the user or Amazon Web Services account.</p>
2104
+ capo_codedeploy.errors.application_name_required_exception.ApplicationNameRequiredException: <p>The minimum number of required application names was not specified.</p>
2105
+ capo_codedeploy.errors.invalid_application_name_exception.InvalidApplicationNameException: <p>The application name was specified in an invalid format.</p>
2106
+ capo_codedeploy.errors.invalid_next_token_exception.InvalidNextTokenException: <p>The next token was specified in an invalid format.</p>
2107
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
2108
+ """
2109
+
2110
+ async def _handler(
2111
+ req: "AsyncOperationRequest[capo_codedeploy.types.list_deployment_groups_input.ListDeploymentGroupsInput]",
2112
+ ) -> AsyncOperationResponse[
2113
+ "capo_codedeploy.types.list_deployment_groups_output.ListDeploymentGroupsOutput"
2114
+ ]:
2115
+ import capo_codedeploy._operations.code_deploy_20141006.list_deployment_groups
2116
+
2117
+ (
2118
+ output,
2119
+ http_response,
2120
+ ) = await capo_codedeploy._operations.code_deploy_20141006.list_deployment_groups.async_list_deployment_groups(
2121
+ req.options, req.input
2122
+ )
2123
+ return AsyncOperationResponse(output=output, response=http_response)
2124
+
2125
+ interceptors_, options_ = self.operation_options(config_overrides)
2126
+ input_: capo_codedeploy.types.list_deployment_groups_input.ListDeploymentGroupsInput = {
2127
+ "application_name": application_name
2128
+ }
2129
+ if next_token is not None:
2130
+ input_["next_token"] = next_token
2131
+
2132
+ response = await aexecute_pipeline(
2133
+ AsyncOperationRequest(input=input_, options=options_),
2134
+ handler=_handler,
2135
+ interceptors=list(interceptors_),
2136
+ )
2137
+ await response.response.aclose()
2138
+ return response.output
2139
+
2140
+ async def iter_list_deployment_groups(
2141
+ self,
2142
+ application_name: "capo_codedeploy.types.application_name.ApplicationName",
2143
+ *,
2144
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2145
+ next_token: Optional["capo_codedeploy.types.next_token.NextToken"] = None,
2146
+ ) -> (
2147
+ "AsyncIterator[capo_codedeploy.types.deployment_group_name.DeploymentGroupName]"
2148
+ ):
2149
+ _token = next_token
2150
+ while True:
2151
+ _response = await self.list_deployment_groups(
2152
+ application_name,
2153
+ config_overrides=config_overrides,
2154
+ next_token=_token,
2155
+ )
2156
+ _page = _resolve_path(_response, ("deployment_groups",))
2157
+ for _item in _page or []:
2158
+ yield _item
2159
+ _token = _resolve_path(_response, ("next_token",))
2160
+ if not _token:
2161
+ break
2162
+
2163
+ async def list_deployment_instances(
2164
+ self,
2165
+ deployment_id: "capo_codedeploy.types.deployment_id.DeploymentId",
2166
+ *,
2167
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2168
+ next_token: Optional["capo_codedeploy.types.next_token.NextToken"] = None,
2169
+ instance_status_filter: Optional[
2170
+ "capo_codedeploy.types.instance_status_list.InstanceStatusList"
2171
+ ] = None,
2172
+ instance_type_filter: Optional[
2173
+ "capo_codedeploy.types.instance_type_list.InstanceTypeList"
2174
+ ] = None,
2175
+ ) -> "capo_codedeploy.types.list_deployment_instances_output.ListDeploymentInstancesOutput":
2176
+ r"""<note> <p> The newer <code>BatchGetDeploymentTargets</code> should be used instead because it works with all compute types. <code>ListDeploymentInstances</code> throws an exception if it is used with a compute platform other than EC2/On-premises or Lambda. </p> </note> <p> Lists the instance for a deployment associated with the user or Amazon Web Services account. </p>
2177
+
2178
+ Args:
2179
+ deployment_id: <p> The unique ID of a deployment. </p>
2180
+ next_token: <p>An identifier returned from the previous list deployment instances call. It can be used to return the next set of deployment instances in the list.</p>
2181
+ instance_status_filter: <p>A subset of instances to list by status:</p> <ul> <li> <p> <code>Pending</code>: Include those instances with pending deployments.</p> </li> <li> <p> <code>InProgress</code>: Include those instances where deployments are still in progress.</p> </li> <li> <p> <code>Succeeded</code>: Include those instances with successful deployments.</p> </li> <li> <p> <code>Failed</code>: Include those instances with failed deployments.</p> </li> <li> <p> <code>Skipped</code>: Include those instances with skipped deployments.</p> </li> <li> <p> <code>Unknown</code>: Include those instances with deployments in an unknown state.</p> </li> </ul>
2182
+ instance_type_filter: <p>The set of instances in a blue/green deployment, either those in the original environment (\"BLUE\") or those in the replacement environment (\"GREEN\"), for which you want to view instance information.</p>
2183
+
2184
+ Raises:
2185
+ capo_codedeploy.errors.deployment_does_not_exist_exception.DeploymentDoesNotExistException: <p>The deployment with the user or Amazon Web Services account does not exist.</p>
2186
+ capo_codedeploy.errors.deployment_id_required_exception.DeploymentIdRequiredException: <p>At least one deployment ID must be specified.</p>
2187
+ capo_codedeploy.errors.deployment_not_started_exception.DeploymentNotStartedException: <p>The specified deployment has not started.</p>
2188
+ capo_codedeploy.errors.invalid_compute_platform_exception.InvalidComputePlatformException: <p>The computePlatform is invalid. The computePlatform should be <code>Lambda</code>, <code>Server</code>, or <code>ECS</code>.</p>
2189
+ capo_codedeploy.errors.invalid_deployment_id_exception.InvalidDeploymentIdException: <p>At least one of the deployment IDs was specified in an invalid format.</p>
2190
+ capo_codedeploy.errors.invalid_deployment_instance_type_exception.InvalidDeploymentInstanceTypeException: <p>An instance type was specified for an in-place deployment. Instance types are supported for blue/green deployments only.</p>
2191
+ capo_codedeploy.errors.invalid_instance_status_exception.InvalidInstanceStatusException: <p>The specified instance status does not exist.</p>
2192
+ capo_codedeploy.errors.invalid_instance_type_exception.InvalidInstanceTypeException: <p>An invalid instance type was specified for instances in a blue/green deployment. Valid values include \"Blue\" for an original environment and \"Green\" for a replacement environment.</p>
2193
+ capo_codedeploy.errors.invalid_next_token_exception.InvalidNextTokenException: <p>The next token was specified in an invalid format.</p>
2194
+ capo_codedeploy.errors.invalid_target_filter_name_exception.InvalidTargetFilterNameException: <p> The target filter name is invalid. </p>
2195
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
2196
+ """
2197
+
2198
+ async def _handler(
2199
+ req: "AsyncOperationRequest[capo_codedeploy.types.list_deployment_instances_input.ListDeploymentInstancesInput]",
2200
+ ) -> AsyncOperationResponse[
2201
+ "capo_codedeploy.types.list_deployment_instances_output.ListDeploymentInstancesOutput"
2202
+ ]:
2203
+ import capo_codedeploy._operations.code_deploy_20141006.list_deployment_instances
2204
+
2205
+ (
2206
+ output,
2207
+ http_response,
2208
+ ) = await capo_codedeploy._operations.code_deploy_20141006.list_deployment_instances.async_list_deployment_instances(
2209
+ req.options, req.input
2210
+ )
2211
+ return AsyncOperationResponse(output=output, response=http_response)
2212
+
2213
+ interceptors_, options_ = self.operation_options(config_overrides)
2214
+ input_: capo_codedeploy.types.list_deployment_instances_input.ListDeploymentInstancesInput = {
2215
+ "deployment_id": deployment_id
2216
+ }
2217
+ if next_token is not None:
2218
+ input_["next_token"] = next_token
2219
+ if instance_status_filter is not None:
2220
+ input_["instance_status_filter"] = instance_status_filter
2221
+ if instance_type_filter is not None:
2222
+ input_["instance_type_filter"] = instance_type_filter
2223
+
2224
+ response = await aexecute_pipeline(
2225
+ AsyncOperationRequest(input=input_, options=options_),
2226
+ handler=_handler,
2227
+ interceptors=list(interceptors_),
2228
+ )
2229
+ await response.response.aclose()
2230
+ return response.output
2231
+
2232
+ async def iter_list_deployment_instances(
2233
+ self,
2234
+ deployment_id: "capo_codedeploy.types.deployment_id.DeploymentId",
2235
+ *,
2236
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2237
+ next_token: Optional["capo_codedeploy.types.next_token.NextToken"] = None,
2238
+ instance_status_filter: Optional[
2239
+ "capo_codedeploy.types.instance_status_list.InstanceStatusList"
2240
+ ] = None,
2241
+ instance_type_filter: Optional[
2242
+ "capo_codedeploy.types.instance_type_list.InstanceTypeList"
2243
+ ] = None,
2244
+ ) -> "AsyncIterator[capo_codedeploy.types.instance_id.InstanceId]":
2245
+ _token = next_token
2246
+ while True:
2247
+ _response = await self.list_deployment_instances(
2248
+ deployment_id,
2249
+ config_overrides=config_overrides,
2250
+ next_token=_token,
2251
+ instance_status_filter=instance_status_filter,
2252
+ instance_type_filter=instance_type_filter,
2253
+ )
2254
+ _page = _resolve_path(_response, ("instances_list",))
2255
+ for _item in _page or []:
2256
+ yield _item
2257
+ _token = _resolve_path(_response, ("next_token",))
2258
+ if not _token:
2259
+ break
2260
+
2261
+ async def list_deployments(
2262
+ self,
2263
+ *,
2264
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2265
+ application_name: Optional[
2266
+ "capo_codedeploy.types.application_name.ApplicationName"
2267
+ ] = None,
2268
+ deployment_group_name: Optional[
2269
+ "capo_codedeploy.types.deployment_group_name.DeploymentGroupName"
2270
+ ] = None,
2271
+ external_id: Optional["capo_codedeploy.types.external_id.ExternalId"] = None,
2272
+ include_only_statuses: Optional[
2273
+ "capo_codedeploy.types.deployment_status_list.DeploymentStatusList"
2274
+ ] = None,
2275
+ create_time_range: Optional[
2276
+ "capo_codedeploy.types.time_range.TimeRange"
2277
+ ] = None,
2278
+ next_token: Optional["capo_codedeploy.types.next_token.NextToken"] = None,
2279
+ ) -> "capo_codedeploy.types.list_deployments_output.ListDeploymentsOutput":
2280
+ """<p>Lists the deployments in a deployment group for an application registered with the user or Amazon Web Services account.</p>
2281
+
2282
+ Args:
2283
+ application_name: <p>The name of an CodeDeploy application associated with the user or Amazon Web Services account.</p> <note> <p>If <code>applicationName</code> is specified, then <code>deploymentGroupName</code> must be specified. If it is not specified, then <code>deploymentGroupName</code> must not be specified. </p> </note>
2284
+ deployment_group_name: <p>The name of a deployment group for the specified application.</p> <note> <p>If <code>deploymentGroupName</code> is specified, then <code>applicationName</code> must be specified. If it is not specified, then <code>applicationName</code> must not be specified. </p> </note>
2285
+ external_id: <p>The unique ID of an external resource for returning deployments linked to the external resource.</p>
2286
+ include_only_statuses: <p>A subset of deployments to list by status:</p> <ul> <li> <p> <code>Created</code>: Include created deployments in the resulting list.</p> </li> <li> <p> <code>Queued</code>: Include queued deployments in the resulting list.</p> </li> <li> <p> <code>In Progress</code>: Include in-progress deployments in the resulting list.</p> </li> <li> <p> <code>Succeeded</code>: Include successful deployments in the resulting list.</p> </li> <li> <p> <code>Failed</code>: Include failed deployments in the resulting list.</p> </li> <li> <p> <code>Stopped</code>: Include stopped deployments in the resulting list.</p> </li> </ul>
2287
+ create_time_range: <p>A time range (start and end) for returning a subset of the list of deployments.</p>
2288
+ next_token: <p>An identifier returned from the previous list deployments call. It can be used to return the next set of deployments in the list.</p>
2289
+
2290
+ Raises:
2291
+ capo_codedeploy.errors.application_does_not_exist_exception.ApplicationDoesNotExistException: <p>The application does not exist with the user or Amazon Web Services account.</p>
2292
+ capo_codedeploy.errors.application_name_required_exception.ApplicationNameRequiredException: <p>The minimum number of required application names was not specified.</p>
2293
+ capo_codedeploy.errors.deployment_group_does_not_exist_exception.DeploymentGroupDoesNotExistException: <p>The named deployment group with the user or Amazon Web Services account does not exist.</p>
2294
+ capo_codedeploy.errors.deployment_group_name_required_exception.DeploymentGroupNameRequiredException: <p>The deployment group name was not specified.</p>
2295
+ capo_codedeploy.errors.invalid_application_name_exception.InvalidApplicationNameException: <p>The application name was specified in an invalid format.</p>
2296
+ capo_codedeploy.errors.invalid_deployment_group_name_exception.InvalidDeploymentGroupNameException: <p>The deployment group name was specified in an invalid format.</p>
2297
+ capo_codedeploy.errors.invalid_deployment_status_exception.InvalidDeploymentStatusException: <p>The specified deployment status doesn't exist or cannot be determined.</p>
2298
+ capo_codedeploy.errors.invalid_external_id_exception.InvalidExternalIdException: <p>The external ID was specified in an invalid format.</p>
2299
+ capo_codedeploy.errors.invalid_input_exception.InvalidInputException: <p>The input was specified in an invalid format.</p>
2300
+ capo_codedeploy.errors.invalid_next_token_exception.InvalidNextTokenException: <p>The next token was specified in an invalid format.</p>
2301
+ capo_codedeploy.errors.invalid_time_range_exception.InvalidTimeRangeException: <p>The specified time range was specified in an invalid format.</p>
2302
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
2303
+ """
2304
+
2305
+ async def _handler(
2306
+ req: "AsyncOperationRequest[capo_codedeploy.types.list_deployments_input.ListDeploymentsInput]",
2307
+ ) -> AsyncOperationResponse[
2308
+ "capo_codedeploy.types.list_deployments_output.ListDeploymentsOutput"
2309
+ ]:
2310
+ import capo_codedeploy._operations.code_deploy_20141006.list_deployments
2311
+
2312
+ (
2313
+ output,
2314
+ http_response,
2315
+ ) = await capo_codedeploy._operations.code_deploy_20141006.list_deployments.async_list_deployments(
2316
+ req.options, req.input
2317
+ )
2318
+ return AsyncOperationResponse(output=output, response=http_response)
2319
+
2320
+ interceptors_, options_ = self.operation_options(config_overrides)
2321
+ input_: capo_codedeploy.types.list_deployments_input.ListDeploymentsInput = {}
2322
+ if application_name is not None:
2323
+ input_["application_name"] = application_name
2324
+ if deployment_group_name is not None:
2325
+ input_["deployment_group_name"] = deployment_group_name
2326
+ if external_id is not None:
2327
+ input_["external_id"] = external_id
2328
+ if include_only_statuses is not None:
2329
+ input_["include_only_statuses"] = include_only_statuses
2330
+ if create_time_range is not None:
2331
+ input_["create_time_range"] = create_time_range
2332
+ if next_token is not None:
2333
+ input_["next_token"] = next_token
2334
+
2335
+ response = await aexecute_pipeline(
2336
+ AsyncOperationRequest(input=input_, options=options_),
2337
+ handler=_handler,
2338
+ interceptors=list(interceptors_),
2339
+ )
2340
+ await response.response.aclose()
2341
+ return response.output
2342
+
2343
+ async def iter_list_deployments(
2344
+ self,
2345
+ *,
2346
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2347
+ application_name: Optional[
2348
+ "capo_codedeploy.types.application_name.ApplicationName"
2349
+ ] = None,
2350
+ deployment_group_name: Optional[
2351
+ "capo_codedeploy.types.deployment_group_name.DeploymentGroupName"
2352
+ ] = None,
2353
+ external_id: Optional["capo_codedeploy.types.external_id.ExternalId"] = None,
2354
+ include_only_statuses: Optional[
2355
+ "capo_codedeploy.types.deployment_status_list.DeploymentStatusList"
2356
+ ] = None,
2357
+ create_time_range: Optional[
2358
+ "capo_codedeploy.types.time_range.TimeRange"
2359
+ ] = None,
2360
+ next_token: Optional["capo_codedeploy.types.next_token.NextToken"] = None,
2361
+ ) -> "AsyncIterator[capo_codedeploy.types.deployment_id.DeploymentId]":
2362
+ _token = next_token
2363
+ while True:
2364
+ _response = await self.list_deployments(
2365
+ config_overrides=config_overrides,
2366
+ application_name=application_name,
2367
+ deployment_group_name=deployment_group_name,
2368
+ external_id=external_id,
2369
+ include_only_statuses=include_only_statuses,
2370
+ create_time_range=create_time_range,
2371
+ next_token=_token,
2372
+ )
2373
+ _page = _resolve_path(_response, ("deployments",))
2374
+ for _item in _page or []:
2375
+ yield _item
2376
+ _token = _resolve_path(_response, ("next_token",))
2377
+ if not _token:
2378
+ break
2379
+
2380
+ async def list_deployment_targets(
2381
+ self,
2382
+ deployment_id: "capo_codedeploy.types.deployment_id.DeploymentId",
2383
+ *,
2384
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2385
+ next_token: Optional["capo_codedeploy.types.next_token.NextToken"] = None,
2386
+ target_filters: Optional[
2387
+ "capo_codedeploy.types.target_filters.TargetFilters"
2388
+ ] = None,
2389
+ ) -> "capo_codedeploy.types.list_deployment_targets_output.ListDeploymentTargetsOutput":
2390
+ """<p> Returns an array of target IDs that are associated a deployment. </p>
2391
+
2392
+ Args:
2393
+ deployment_id: <p> The unique ID of a deployment. </p>
2394
+ next_token: <p> A token identifier returned from the previous <code>ListDeploymentTargets</code> call. It can be used to return the next set of deployment targets in the list. </p>
2395
+ target_filters: <p> A key used to filter the returned targets. The two valid values are:</p> <ul> <li> <p> <code>TargetStatus</code> - A <code>TargetStatus</code> filter string can be <code>Failed</code>, <code>InProgress</code>, <code>Pending</code>, <code>Ready</code>, <code>Skipped</code>, <code>Succeeded</code>, or <code>Unknown</code>. </p> </li> <li> <p> <code>ServerInstanceLabel</code> - A <code>ServerInstanceLabel</code> filter string can be <code>Blue</code> or <code>Green</code>. </p> </li> </ul>
2396
+
2397
+ Raises:
2398
+ capo_codedeploy.errors.deployment_does_not_exist_exception.DeploymentDoesNotExistException: <p>The deployment with the user or Amazon Web Services account does not exist.</p>
2399
+ capo_codedeploy.errors.deployment_id_required_exception.DeploymentIdRequiredException: <p>At least one deployment ID must be specified.</p>
2400
+ capo_codedeploy.errors.deployment_not_started_exception.DeploymentNotStartedException: <p>The specified deployment has not started.</p>
2401
+ capo_codedeploy.errors.invalid_deployment_id_exception.InvalidDeploymentIdException: <p>At least one of the deployment IDs was specified in an invalid format.</p>
2402
+ capo_codedeploy.errors.invalid_deployment_instance_type_exception.InvalidDeploymentInstanceTypeException: <p>An instance type was specified for an in-place deployment. Instance types are supported for blue/green deployments only.</p>
2403
+ capo_codedeploy.errors.invalid_instance_status_exception.InvalidInstanceStatusException: <p>The specified instance status does not exist.</p>
2404
+ capo_codedeploy.errors.invalid_instance_type_exception.InvalidInstanceTypeException: <p>An invalid instance type was specified for instances in a blue/green deployment. Valid values include \"Blue\" for an original environment and \"Green\" for a replacement environment.</p>
2405
+ capo_codedeploy.errors.invalid_next_token_exception.InvalidNextTokenException: <p>The next token was specified in an invalid format.</p>
2406
+ capo_codedeploy.errors.invalid_target_filter_name_exception.InvalidTargetFilterNameException: <p> The target filter name is invalid. </p>
2407
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
2408
+ """
2409
+
2410
+ async def _handler(
2411
+ req: "AsyncOperationRequest[capo_codedeploy.types.list_deployment_targets_input.ListDeploymentTargetsInput]",
2412
+ ) -> AsyncOperationResponse[
2413
+ "capo_codedeploy.types.list_deployment_targets_output.ListDeploymentTargetsOutput"
2414
+ ]:
2415
+ import capo_codedeploy._operations.code_deploy_20141006.list_deployment_targets
2416
+
2417
+ (
2418
+ output,
2419
+ http_response,
2420
+ ) = await capo_codedeploy._operations.code_deploy_20141006.list_deployment_targets.async_list_deployment_targets(
2421
+ req.options, req.input
2422
+ )
2423
+ return AsyncOperationResponse(output=output, response=http_response)
2424
+
2425
+ interceptors_, options_ = self.operation_options(config_overrides)
2426
+ input_: capo_codedeploy.types.list_deployment_targets_input.ListDeploymentTargetsInput = {
2427
+ "deployment_id": deployment_id
2428
+ }
2429
+ if next_token is not None:
2430
+ input_["next_token"] = next_token
2431
+ if target_filters is not None:
2432
+ input_["target_filters"] = target_filters
2433
+
2434
+ response = await aexecute_pipeline(
2435
+ AsyncOperationRequest(input=input_, options=options_),
2436
+ handler=_handler,
2437
+ interceptors=list(interceptors_),
2438
+ )
2439
+ await response.response.aclose()
2440
+ return response.output
2441
+
2442
+ async def list_git_hub_account_token_names(
2443
+ self,
2444
+ *,
2445
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2446
+ next_token: Optional["capo_codedeploy.types.next_token.NextToken"] = None,
2447
+ ) -> "capo_codedeploy.types.list_git_hub_account_token_names_output.ListGitHubAccountTokenNamesOutput":
2448
+ """<p>Lists the names of stored connections to GitHub accounts.</p>
2449
+
2450
+ Args:
2451
+ next_token: <p>An identifier returned from the previous <code>ListGitHubAccountTokenNames</code> call. It can be used to return the next set of names in the list. </p>
2452
+
2453
+ Raises:
2454
+ capo_codedeploy.errors.invalid_next_token_exception.InvalidNextTokenException: <p>The next token was specified in an invalid format.</p>
2455
+ capo_codedeploy.errors.operation_not_supported_exception.OperationNotSupportedException: <p>The API used does not support the deployment.</p>
2456
+ capo_codedeploy.errors.resource_validation_exception.ResourceValidationException: <p>The specified resource could not be validated.</p>
2457
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
2458
+ """
2459
+
2460
+ async def _handler(
2461
+ req: "AsyncOperationRequest[capo_codedeploy.types.list_git_hub_account_token_names_input.ListGitHubAccountTokenNamesInput]",
2462
+ ) -> AsyncOperationResponse[
2463
+ "capo_codedeploy.types.list_git_hub_account_token_names_output.ListGitHubAccountTokenNamesOutput"
2464
+ ]:
2465
+ import capo_codedeploy._operations.code_deploy_20141006.list_git_hub_account_token_names
2466
+
2467
+ (
2468
+ output,
2469
+ http_response,
2470
+ ) = await capo_codedeploy._operations.code_deploy_20141006.list_git_hub_account_token_names.async_list_git_hub_account_token_names(
2471
+ req.options, req.input
2472
+ )
2473
+ return AsyncOperationResponse(output=output, response=http_response)
2474
+
2475
+ interceptors_, options_ = self.operation_options(config_overrides)
2476
+ input_: capo_codedeploy.types.list_git_hub_account_token_names_input.ListGitHubAccountTokenNamesInput = {}
2477
+ if next_token is not None:
2478
+ input_["next_token"] = next_token
2479
+
2480
+ response = await aexecute_pipeline(
2481
+ AsyncOperationRequest(input=input_, options=options_),
2482
+ handler=_handler,
2483
+ interceptors=list(interceptors_),
2484
+ )
2485
+ await response.response.aclose()
2486
+ return response.output
2487
+
2488
+ async def list_on_premises_instances(
2489
+ self,
2490
+ *,
2491
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2492
+ registration_status: Optional[
2493
+ "capo_codedeploy.types.registration_status.RegistrationStatus"
2494
+ ] = None,
2495
+ tag_filters: Optional[
2496
+ "capo_codedeploy.types.tag_filter_list.TagFilterList"
2497
+ ] = None,
2498
+ next_token: Optional["capo_codedeploy.types.next_token.NextToken"] = None,
2499
+ ) -> "capo_codedeploy.types.list_on_premises_instances_output.ListOnPremisesInstancesOutput":
2500
+ """<p>Gets a list of names for one or more on-premises instances.</p> <p>Unless otherwise specified, both registered and deregistered on-premises instance names are listed. To list only registered or deregistered on-premises instance names, use the registration status parameter.</p>
2501
+
2502
+ Args:
2503
+ registration_status: <p>The registration status of the on-premises instances:</p> <ul> <li> <p> <code>Deregistered</code>: Include deregistered on-premises instances in the resulting list.</p> </li> <li> <p> <code>Registered</code>: Include registered on-premises instances in the resulting list.</p> </li> </ul>
2504
+ tag_filters: <p>The on-premises instance tags that are used to restrict the on-premises instance names returned.</p>
2505
+ next_token: <p>An identifier returned from the previous list on-premises instances call. It can be used to return the next set of on-premises instances in the list.</p>
2506
+
2507
+ Raises:
2508
+ capo_codedeploy.errors.invalid_next_token_exception.InvalidNextTokenException: <p>The next token was specified in an invalid format.</p>
2509
+ capo_codedeploy.errors.invalid_registration_status_exception.InvalidRegistrationStatusException: <p>The registration status was specified in an invalid format.</p>
2510
+ capo_codedeploy.errors.invalid_tag_filter_exception.InvalidTagFilterException: <p>The tag filter was specified in an invalid format.</p>
2511
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
2512
+ """
2513
+
2514
+ async def _handler(
2515
+ req: "AsyncOperationRequest[capo_codedeploy.types.list_on_premises_instances_input.ListOnPremisesInstancesInput]",
2516
+ ) -> AsyncOperationResponse[
2517
+ "capo_codedeploy.types.list_on_premises_instances_output.ListOnPremisesInstancesOutput"
2518
+ ]:
2519
+ import capo_codedeploy._operations.code_deploy_20141006.list_on_premises_instances
2520
+
2521
+ (
2522
+ output,
2523
+ http_response,
2524
+ ) = await capo_codedeploy._operations.code_deploy_20141006.list_on_premises_instances.async_list_on_premises_instances(
2525
+ req.options, req.input
2526
+ )
2527
+ return AsyncOperationResponse(output=output, response=http_response)
2528
+
2529
+ interceptors_, options_ = self.operation_options(config_overrides)
2530
+ input_: capo_codedeploy.types.list_on_premises_instances_input.ListOnPremisesInstancesInput = {}
2531
+ if registration_status is not None:
2532
+ input_["registration_status"] = registration_status
2533
+ if tag_filters is not None:
2534
+ input_["tag_filters"] = tag_filters
2535
+ if next_token is not None:
2536
+ input_["next_token"] = next_token
2537
+
2538
+ response = await aexecute_pipeline(
2539
+ AsyncOperationRequest(input=input_, options=options_),
2540
+ handler=_handler,
2541
+ interceptors=list(interceptors_),
2542
+ )
2543
+ await response.response.aclose()
2544
+ return response.output
2545
+
2546
+ async def list_tags_for_resource(
2547
+ self,
2548
+ resource_arn: "capo_codedeploy.types.arn.Arn",
2549
+ *,
2550
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2551
+ next_token: Optional["capo_codedeploy.types.next_token.NextToken"] = None,
2552
+ ) -> (
2553
+ "capo_codedeploy.types.list_tags_for_resource_output.ListTagsForResourceOutput"
2554
+ ):
2555
+ """<p> Returns a list of tags for the resource identified by a specified Amazon Resource Name (ARN). Tags are used to organize and categorize your CodeDeploy resources. </p>
2556
+
2557
+ Args:
2558
+ resource_arn: <p> The ARN of a CodeDeploy resource. <code>ListTagsForResource</code> returns all the tags associated with the resource that is identified by the <code>ResourceArn</code>. </p>
2559
+ next_token: <p>An identifier returned from the previous <code>ListTagsForResource</code> call. It can be used to return the next set of applications in the list.</p>
2560
+
2561
+ Raises:
2562
+ capo_codedeploy.errors.arn_not_supported_exception.ArnNotSupportedException: <p> The specified ARN is not supported. For example, it might be an ARN for a resource that is not expected. </p>
2563
+ capo_codedeploy.errors.invalid_arn_exception.InvalidArnException: <p> The specified ARN is not in a valid format. </p>
2564
+ capo_codedeploy.errors.resource_arn_required_exception.ResourceArnRequiredException: <p> The ARN of a resource is required, but was not found. </p>
2565
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
2566
+ """
2567
+
2568
+ async def _handler(
2569
+ req: "AsyncOperationRequest[capo_codedeploy.types.list_tags_for_resource_input.ListTagsForResourceInput]",
2570
+ ) -> AsyncOperationResponse[
2571
+ "capo_codedeploy.types.list_tags_for_resource_output.ListTagsForResourceOutput"
2572
+ ]:
2573
+ import capo_codedeploy._operations.code_deploy_20141006.list_tags_for_resource
2574
+
2575
+ (
2576
+ output,
2577
+ http_response,
2578
+ ) = await capo_codedeploy._operations.code_deploy_20141006.list_tags_for_resource.async_list_tags_for_resource(
2579
+ req.options, req.input
2580
+ )
2581
+ return AsyncOperationResponse(output=output, response=http_response)
2582
+
2583
+ interceptors_, options_ = self.operation_options(config_overrides)
2584
+ input_: capo_codedeploy.types.list_tags_for_resource_input.ListTagsForResourceInput = {
2585
+ "resource_arn": resource_arn
2586
+ }
2587
+ if next_token is not None:
2588
+ input_["next_token"] = next_token
2589
+
2590
+ response = await aexecute_pipeline(
2591
+ AsyncOperationRequest(input=input_, options=options_),
2592
+ handler=_handler,
2593
+ interceptors=list(interceptors_),
2594
+ )
2595
+ await response.response.aclose()
2596
+ return response.output
2597
+
2598
+ async def put_lifecycle_event_hook_execution_status(
2599
+ self,
2600
+ *,
2601
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2602
+ deployment_id: Optional[
2603
+ "capo_codedeploy.types.deployment_id.DeploymentId"
2604
+ ] = None,
2605
+ lifecycle_event_hook_execution_id: Optional[
2606
+ "capo_codedeploy.types.lifecycle_event_hook_execution_id.LifecycleEventHookExecutionId"
2607
+ ] = None,
2608
+ status: Optional[
2609
+ "capo_codedeploy.types.lifecycle_event_status.LifecycleEventStatus"
2610
+ ] = None,
2611
+ ) -> "capo_codedeploy.types.put_lifecycle_event_hook_execution_status_output.PutLifecycleEventHookExecutionStatusOutput":
2612
+ r"""<p> Sets the result of a Lambda validation function. The function validates lifecycle hooks during a deployment that uses the Lambda or Amazon ECS compute platform. For Lambda deployments, the available lifecycle hooks are <code>BeforeAllowTraffic</code> and <code>AfterAllowTraffic</code>. For Amazon ECS deployments, the available lifecycle hooks are <code>BeforeInstall</code>, <code>AfterInstall</code>, <code>AfterAllowTestTraffic</code>, <code>BeforeAllowTraffic</code>, and <code>AfterAllowTraffic</code>. Lambda validation functions return <code>Succeeded</code> or <code>Failed</code>. For more information, see <a href=\"https://docs.aws.amazon.com/codedeploy/latest/userguide/reference-appspec-file-structure-hooks.html#appspec-hooks-lambda\">AppSpec 'hooks' Section for an Lambda Deployment </a> and <a href=\"https://docs.aws.amazon.com/codedeploy/latest/userguide/reference-appspec-file-structure-hooks.html#appspec-hooks-ecs\">AppSpec 'hooks' Section for an Amazon ECS Deployment</a>.</p>
2613
+
2614
+ Args:
2615
+ deployment_id: <p> The unique ID of a deployment. Pass this ID to a Lambda function that validates a deployment lifecycle event. </p>
2616
+ lifecycle_event_hook_execution_id: <p> The execution ID of a deployment's lifecycle hook. A deployment lifecycle hook is specified in the <code>hooks</code> section of the AppSpec file. </p>
2617
+ status: <p>The result of a Lambda function that validates a deployment lifecycle event. The values listed in <b>Valid Values</b> are valid for lifecycle statuses in general; however, only <code>Succeeded</code> and <code>Failed</code> can be passed successfully in your API call.</p>
2618
+
2619
+ Raises:
2620
+ capo_codedeploy.errors.deployment_does_not_exist_exception.DeploymentDoesNotExistException: <p>The deployment with the user or Amazon Web Services account does not exist.</p>
2621
+ capo_codedeploy.errors.deployment_id_required_exception.DeploymentIdRequiredException: <p>At least one deployment ID must be specified.</p>
2622
+ capo_codedeploy.errors.invalid_deployment_id_exception.InvalidDeploymentIdException: <p>At least one of the deployment IDs was specified in an invalid format.</p>
2623
+ capo_codedeploy.errors.invalid_lifecycle_event_hook_execution_id_exception.InvalidLifecycleEventHookExecutionIdException: <p>A lifecycle event hook is invalid. Review the <code>hooks</code> section in your AppSpec file to ensure the lifecycle events and <code>hooks</code> functions are valid.</p>
2624
+ capo_codedeploy.errors.invalid_lifecycle_event_hook_execution_status_exception.InvalidLifecycleEventHookExecutionStatusException: <p>The result of a Lambda validation function that verifies a lifecycle event is invalid. It should return <code>Succeeded</code> or <code>Failed</code>.</p>
2625
+ capo_codedeploy.errors.lifecycle_event_already_completed_exception.LifecycleEventAlreadyCompletedException: <p>An attempt to return the status of an already completed lifecycle event occurred.</p>
2626
+ capo_codedeploy.errors.unsupported_action_for_deployment_type_exception.UnsupportedActionForDeploymentTypeException: <p>A call was submitted that is not supported for the specified deployment type.</p>
2627
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
2628
+ """
2629
+
2630
+ async def _handler(
2631
+ req: "AsyncOperationRequest[capo_codedeploy.types.put_lifecycle_event_hook_execution_status_input.PutLifecycleEventHookExecutionStatusInput]",
2632
+ ) -> AsyncOperationResponse[
2633
+ "capo_codedeploy.types.put_lifecycle_event_hook_execution_status_output.PutLifecycleEventHookExecutionStatusOutput"
2634
+ ]:
2635
+ import capo_codedeploy._operations.code_deploy_20141006.put_lifecycle_event_hook_execution_status
2636
+
2637
+ (
2638
+ output,
2639
+ http_response,
2640
+ ) = await capo_codedeploy._operations.code_deploy_20141006.put_lifecycle_event_hook_execution_status.async_put_lifecycle_event_hook_execution_status(
2641
+ req.options, req.input
2642
+ )
2643
+ return AsyncOperationResponse(output=output, response=http_response)
2644
+
2645
+ interceptors_, options_ = self.operation_options(config_overrides)
2646
+ input_: capo_codedeploy.types.put_lifecycle_event_hook_execution_status_input.PutLifecycleEventHookExecutionStatusInput = {}
2647
+ if deployment_id is not None:
2648
+ input_["deployment_id"] = deployment_id
2649
+ if lifecycle_event_hook_execution_id is not None:
2650
+ input_["lifecycle_event_hook_execution_id"] = (
2651
+ lifecycle_event_hook_execution_id
2652
+ )
2653
+ if status is not None:
2654
+ input_["status"] = status
2655
+
2656
+ response = await aexecute_pipeline(
2657
+ AsyncOperationRequest(input=input_, options=options_),
2658
+ handler=_handler,
2659
+ interceptors=list(interceptors_),
2660
+ )
2661
+ await response.response.aclose()
2662
+ return response.output
2663
+
2664
+ async def register_application_revision(
2665
+ self,
2666
+ application_name: "capo_codedeploy.types.application_name.ApplicationName",
2667
+ revision: "capo_codedeploy.types.revision_location.RevisionLocation",
2668
+ *,
2669
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2670
+ description: Optional["capo_codedeploy.types.description.Description"] = None,
2671
+ ) -> None:
2672
+ """<p>Registers with CodeDeploy a revision for the specified application.</p>
2673
+
2674
+ Args:
2675
+ application_name: <p>The name of an CodeDeploy application associated with the user or Amazon Web Services account.</p>
2676
+ description: <p>A comment about the revision.</p>
2677
+ revision: <p>Information about the application revision to register, including type and location.</p>
2678
+
2679
+ Raises:
2680
+ capo_codedeploy.errors.application_does_not_exist_exception.ApplicationDoesNotExistException: <p>The application does not exist with the user or Amazon Web Services account.</p>
2681
+ capo_codedeploy.errors.application_name_required_exception.ApplicationNameRequiredException: <p>The minimum number of required application names was not specified.</p>
2682
+ capo_codedeploy.errors.description_too_long_exception.DescriptionTooLongException: <p>The description is too long.</p>
2683
+ capo_codedeploy.errors.invalid_application_name_exception.InvalidApplicationNameException: <p>The application name was specified in an invalid format.</p>
2684
+ capo_codedeploy.errors.invalid_revision_exception.InvalidRevisionException: <p>The revision was specified in an invalid format.</p>
2685
+ capo_codedeploy.errors.revision_required_exception.RevisionRequiredException: <p>The revision ID was not specified.</p>
2686
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
2687
+ """
2688
+
2689
+ async def _handler(
2690
+ req: "AsyncOperationRequest[capo_codedeploy.types.register_application_revision_input.RegisterApplicationRevisionInput]",
2691
+ ) -> AsyncOperationResponse[None]:
2692
+ import capo_codedeploy._operations.code_deploy_20141006.register_application_revision
2693
+
2694
+ (
2695
+ output,
2696
+ http_response,
2697
+ ) = await capo_codedeploy._operations.code_deploy_20141006.register_application_revision.async_register_application_revision(
2698
+ req.options, req.input
2699
+ )
2700
+ return AsyncOperationResponse(output=output, response=http_response)
2701
+
2702
+ interceptors_, options_ = self.operation_options(config_overrides)
2703
+ input_: capo_codedeploy.types.register_application_revision_input.RegisterApplicationRevisionInput = {
2704
+ "application_name": application_name,
2705
+ "revision": revision,
2706
+ }
2707
+ if description is not None:
2708
+ input_["description"] = description
2709
+
2710
+ response = await aexecute_pipeline(
2711
+ AsyncOperationRequest(input=input_, options=options_),
2712
+ handler=_handler,
2713
+ interceptors=list(interceptors_),
2714
+ )
2715
+ await response.response.aclose()
2716
+ return response.output
2717
+
2718
+ async def register_on_premises_instance(
2719
+ self,
2720
+ instance_name: "capo_codedeploy.types.instance_name.InstanceName",
2721
+ *,
2722
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2723
+ iam_session_arn: Optional[
2724
+ "capo_codedeploy.types.iam_session_arn.IamSessionArn"
2725
+ ] = None,
2726
+ iam_user_arn: Optional["capo_codedeploy.types.iam_user_arn.IamUserArn"] = None,
2727
+ ) -> None:
2728
+ """<p>Registers an on-premises instance.</p> <note> <p>Only one IAM ARN (an IAM session ARN or IAM user ARN) is supported in the request. You cannot use both.</p> </note>
2729
+
2730
+ Args:
2731
+ instance_name: <p>The name of the on-premises instance to register.</p>
2732
+ iam_session_arn: <p>The ARN of the IAM session to associate with the on-premises instance.</p>
2733
+ iam_user_arn: <p>The ARN of the user to associate with the on-premises instance.</p>
2734
+
2735
+ Raises:
2736
+ capo_codedeploy.errors.iam_arn_required_exception.IamArnRequiredException: <p>No IAM ARN was included in the request. You must use an IAM session ARN or user ARN in the request.</p>
2737
+ capo_codedeploy.errors.iam_session_arn_already_registered_exception.IamSessionArnAlreadyRegisteredException: <p>The request included an IAM session ARN that has already been used to register a different instance.</p>
2738
+ capo_codedeploy.errors.iam_user_arn_already_registered_exception.IamUserArnAlreadyRegisteredException: <p>The specified user ARN is already registered with an on-premises instance.</p>
2739
+ capo_codedeploy.errors.iam_user_arn_required_exception.IamUserArnRequiredException: <p>An user ARN was not specified.</p>
2740
+ capo_codedeploy.errors.instance_name_already_registered_exception.InstanceNameAlreadyRegisteredException: <p>The specified on-premises instance name is already registered.</p>
2741
+ capo_codedeploy.errors.instance_name_required_exception.InstanceNameRequiredException: <p>An on-premises instance name was not specified.</p>
2742
+ capo_codedeploy.errors.invalid_iam_session_arn_exception.InvalidIamSessionArnException: <p>The IAM session ARN was specified in an invalid format.</p>
2743
+ capo_codedeploy.errors.invalid_iam_user_arn_exception.InvalidIamUserArnException: <p>The user ARN was specified in an invalid format.</p>
2744
+ capo_codedeploy.errors.invalid_instance_name_exception.InvalidInstanceNameException: <p>The on-premises instance name was specified in an invalid format.</p>
2745
+ capo_codedeploy.errors.multiple_iam_arns_provided_exception.MultipleIamArnsProvidedException: <p>Both an user ARN and an IAM session ARN were included in the request. Use only one ARN type.</p>
2746
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
2747
+ """
2748
+
2749
+ async def _handler(
2750
+ req: "AsyncOperationRequest[capo_codedeploy.types.register_on_premises_instance_input.RegisterOnPremisesInstanceInput]",
2751
+ ) -> AsyncOperationResponse[None]:
2752
+ import capo_codedeploy._operations.code_deploy_20141006.register_on_premises_instance
2753
+
2754
+ (
2755
+ output,
2756
+ http_response,
2757
+ ) = await capo_codedeploy._operations.code_deploy_20141006.register_on_premises_instance.async_register_on_premises_instance(
2758
+ req.options, req.input
2759
+ )
2760
+ return AsyncOperationResponse(output=output, response=http_response)
2761
+
2762
+ interceptors_, options_ = self.operation_options(config_overrides)
2763
+ input_: capo_codedeploy.types.register_on_premises_instance_input.RegisterOnPremisesInstanceInput = {
2764
+ "instance_name": instance_name
2765
+ }
2766
+ if iam_session_arn is not None:
2767
+ input_["iam_session_arn"] = iam_session_arn
2768
+ if iam_user_arn is not None:
2769
+ input_["iam_user_arn"] = iam_user_arn
2770
+
2771
+ response = await aexecute_pipeline(
2772
+ AsyncOperationRequest(input=input_, options=options_),
2773
+ handler=_handler,
2774
+ interceptors=list(interceptors_),
2775
+ )
2776
+ await response.response.aclose()
2777
+ return response.output
2778
+
2779
+ async def remove_tags_from_on_premises_instances(
2780
+ self,
2781
+ tags: "capo_codedeploy.types.tag_list.TagList",
2782
+ instance_names: "capo_codedeploy.types.instance_name_list.InstanceNameList",
2783
+ *,
2784
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2785
+ ) -> None:
2786
+ """<p>Removes one or more tags from one or more on-premises instances.</p>
2787
+
2788
+ Args:
2789
+ tags: <p>The tag key-value pairs to remove from the on-premises instances.</p>
2790
+ instance_names: <p>The names of the on-premises instances from which to remove tags.</p>
2791
+
2792
+ Raises:
2793
+ capo_codedeploy.errors.instance_limit_exceeded_exception.InstanceLimitExceededException: <p>The maximum number of allowed on-premises instances in a single call was exceeded.</p>
2794
+ capo_codedeploy.errors.instance_name_required_exception.InstanceNameRequiredException: <p>An on-premises instance name was not specified.</p>
2795
+ capo_codedeploy.errors.instance_not_registered_exception.InstanceNotRegisteredException: <p>The specified on-premises instance is not registered.</p>
2796
+ capo_codedeploy.errors.invalid_instance_name_exception.InvalidInstanceNameException: <p>The on-premises instance name was specified in an invalid format.</p>
2797
+ capo_codedeploy.errors.invalid_tag_exception.InvalidTagException: <p>The tag was specified in an invalid format.</p>
2798
+ capo_codedeploy.errors.tag_limit_exceeded_exception.TagLimitExceededException: <p>The maximum allowed number of tags was exceeded.</p>
2799
+ capo_codedeploy.errors.tag_required_exception.TagRequiredException: <p>A tag was not specified.</p>
2800
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
2801
+ """
2802
+
2803
+ async def _handler(
2804
+ req: "AsyncOperationRequest[capo_codedeploy.types.remove_tags_from_on_premises_instances_input.RemoveTagsFromOnPremisesInstancesInput]",
2805
+ ) -> AsyncOperationResponse[None]:
2806
+ import capo_codedeploy._operations.code_deploy_20141006.remove_tags_from_on_premises_instances
2807
+
2808
+ (
2809
+ output,
2810
+ http_response,
2811
+ ) = await capo_codedeploy._operations.code_deploy_20141006.remove_tags_from_on_premises_instances.async_remove_tags_from_on_premises_instances(
2812
+ req.options, req.input
2813
+ )
2814
+ return AsyncOperationResponse(output=output, response=http_response)
2815
+
2816
+ interceptors_, options_ = self.operation_options(config_overrides)
2817
+ input_: capo_codedeploy.types.remove_tags_from_on_premises_instances_input.RemoveTagsFromOnPremisesInstancesInput = {
2818
+ "tags": tags,
2819
+ "instance_names": instance_names,
2820
+ }
2821
+
2822
+ response = await aexecute_pipeline(
2823
+ AsyncOperationRequest(input=input_, options=options_),
2824
+ handler=_handler,
2825
+ interceptors=list(interceptors_),
2826
+ )
2827
+ await response.response.aclose()
2828
+ return response.output
2829
+
2830
+ async def skip_wait_time_for_instance_termination(
2831
+ self,
2832
+ *,
2833
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2834
+ deployment_id: Optional[
2835
+ "capo_codedeploy.types.deployment_id.DeploymentId"
2836
+ ] = None,
2837
+ ) -> None:
2838
+ """<p>In a blue/green deployment, overrides any specified wait time and starts terminating instances immediately after the traffic routing is complete.</p>
2839
+
2840
+ Args:
2841
+ deployment_id: <p> The unique ID of a blue/green deployment for which you want to skip the instance termination wait time. </p>
2842
+
2843
+ Raises:
2844
+ capo_codedeploy.errors.deployment_already_completed_exception.DeploymentAlreadyCompletedException: <p>The deployment is already complete.</p>
2845
+ capo_codedeploy.errors.deployment_does_not_exist_exception.DeploymentDoesNotExistException: <p>The deployment with the user or Amazon Web Services account does not exist.</p>
2846
+ capo_codedeploy.errors.deployment_id_required_exception.DeploymentIdRequiredException: <p>At least one deployment ID must be specified.</p>
2847
+ capo_codedeploy.errors.deployment_not_started_exception.DeploymentNotStartedException: <p>The specified deployment has not started.</p>
2848
+ capo_codedeploy.errors.invalid_deployment_id_exception.InvalidDeploymentIdException: <p>At least one of the deployment IDs was specified in an invalid format.</p>
2849
+ capo_codedeploy.errors.unsupported_action_for_deployment_type_exception.UnsupportedActionForDeploymentTypeException: <p>A call was submitted that is not supported for the specified deployment type.</p>
2850
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
2851
+ """
2852
+
2853
+ async def _handler(
2854
+ req: "AsyncOperationRequest[capo_codedeploy.types.skip_wait_time_for_instance_termination_input.SkipWaitTimeForInstanceTerminationInput]",
2855
+ ) -> AsyncOperationResponse[None]:
2856
+ import capo_codedeploy._operations.code_deploy_20141006.skip_wait_time_for_instance_termination
2857
+
2858
+ (
2859
+ output,
2860
+ http_response,
2861
+ ) = await capo_codedeploy._operations.code_deploy_20141006.skip_wait_time_for_instance_termination.async_skip_wait_time_for_instance_termination(
2862
+ req.options, req.input
2863
+ )
2864
+ return AsyncOperationResponse(output=output, response=http_response)
2865
+
2866
+ interceptors_, options_ = self.operation_options(config_overrides)
2867
+ input_: capo_codedeploy.types.skip_wait_time_for_instance_termination_input.SkipWaitTimeForInstanceTerminationInput = {}
2868
+ if deployment_id is not None:
2869
+ input_["deployment_id"] = deployment_id
2870
+
2871
+ response = await aexecute_pipeline(
2872
+ AsyncOperationRequest(input=input_, options=options_),
2873
+ handler=_handler,
2874
+ interceptors=list(interceptors_),
2875
+ )
2876
+ await response.response.aclose()
2877
+ return response.output
2878
+
2879
+ async def stop_deployment(
2880
+ self,
2881
+ deployment_id: "capo_codedeploy.types.deployment_id.DeploymentId",
2882
+ *,
2883
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2884
+ auto_rollback_enabled: Optional[
2885
+ "capo_codedeploy.types.nullable_boolean.NullableBoolean"
2886
+ ] = None,
2887
+ ) -> "capo_codedeploy.types.stop_deployment_output.StopDeploymentOutput":
2888
+ """<p>Attempts to stop an ongoing deployment.</p>
2889
+
2890
+ Args:
2891
+ deployment_id: <p> The unique ID of a deployment. </p>
2892
+ auto_rollback_enabled: <p> Indicates, when a deployment is stopped, whether instances that have been updated should be rolled back to the previous version of the application revision. </p>
2893
+
2894
+ Raises:
2895
+ capo_codedeploy.errors.deployment_already_completed_exception.DeploymentAlreadyCompletedException: <p>The deployment is already complete.</p>
2896
+ capo_codedeploy.errors.deployment_does_not_exist_exception.DeploymentDoesNotExistException: <p>The deployment with the user or Amazon Web Services account does not exist.</p>
2897
+ capo_codedeploy.errors.deployment_group_does_not_exist_exception.DeploymentGroupDoesNotExistException: <p>The named deployment group with the user or Amazon Web Services account does not exist.</p>
2898
+ capo_codedeploy.errors.deployment_id_required_exception.DeploymentIdRequiredException: <p>At least one deployment ID must be specified.</p>
2899
+ capo_codedeploy.errors.invalid_deployment_id_exception.InvalidDeploymentIdException: <p>At least one of the deployment IDs was specified in an invalid format.</p>
2900
+ capo_codedeploy.errors.unsupported_action_for_deployment_type_exception.UnsupportedActionForDeploymentTypeException: <p>A call was submitted that is not supported for the specified deployment type.</p>
2901
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
2902
+ """
2903
+
2904
+ async def _handler(
2905
+ req: "AsyncOperationRequest[capo_codedeploy.types.stop_deployment_input.StopDeploymentInput]",
2906
+ ) -> AsyncOperationResponse[
2907
+ "capo_codedeploy.types.stop_deployment_output.StopDeploymentOutput"
2908
+ ]:
2909
+ import capo_codedeploy._operations.code_deploy_20141006.stop_deployment
2910
+
2911
+ (
2912
+ output,
2913
+ http_response,
2914
+ ) = await capo_codedeploy._operations.code_deploy_20141006.stop_deployment.async_stop_deployment(
2915
+ req.options, req.input
2916
+ )
2917
+ return AsyncOperationResponse(output=output, response=http_response)
2918
+
2919
+ interceptors_, options_ = self.operation_options(config_overrides)
2920
+ input_: capo_codedeploy.types.stop_deployment_input.StopDeploymentInput = {
2921
+ "deployment_id": deployment_id
2922
+ }
2923
+ if auto_rollback_enabled is not None:
2924
+ input_["auto_rollback_enabled"] = auto_rollback_enabled
2925
+
2926
+ response = await aexecute_pipeline(
2927
+ AsyncOperationRequest(input=input_, options=options_),
2928
+ handler=_handler,
2929
+ interceptors=list(interceptors_),
2930
+ )
2931
+ await response.response.aclose()
2932
+ return response.output
2933
+
2934
+ async def tag_resource(
2935
+ self,
2936
+ resource_arn: "capo_codedeploy.types.arn.Arn",
2937
+ tags: "capo_codedeploy.types.tag_list.TagList",
2938
+ *,
2939
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2940
+ ) -> "capo_codedeploy.types.tag_resource_output.TagResourceOutput":
2941
+ """<p> Associates the list of tags in the input <code>Tags</code> parameter with the resource identified by the <code>ResourceArn</code> input parameter. </p>
2942
+
2943
+ Args:
2944
+ resource_arn: <p> The ARN of a resource, such as a CodeDeploy application or deployment group. </p>
2945
+ tags: <p> A list of tags that <code>TagResource</code> associates with a resource. The resource is identified by the <code>ResourceArn</code> input parameter. </p>
2946
+
2947
+ Raises:
2948
+ capo_codedeploy.errors.application_does_not_exist_exception.ApplicationDoesNotExistException: <p>The application does not exist with the user or Amazon Web Services account.</p>
2949
+ capo_codedeploy.errors.arn_not_supported_exception.ArnNotSupportedException: <p> The specified ARN is not supported. For example, it might be an ARN for a resource that is not expected. </p>
2950
+ capo_codedeploy.errors.deployment_config_does_not_exist_exception.DeploymentConfigDoesNotExistException: <p>The deployment configuration does not exist with the user or Amazon Web Services account.</p>
2951
+ capo_codedeploy.errors.deployment_group_does_not_exist_exception.DeploymentGroupDoesNotExistException: <p>The named deployment group with the user or Amazon Web Services account does not exist.</p>
2952
+ capo_codedeploy.errors.invalid_arn_exception.InvalidArnException: <p> The specified ARN is not in a valid format. </p>
2953
+ capo_codedeploy.errors.invalid_tags_to_add_exception.InvalidTagsToAddException: <p> The specified tags are not valid. </p>
2954
+ capo_codedeploy.errors.resource_arn_required_exception.ResourceArnRequiredException: <p> The ARN of a resource is required, but was not found. </p>
2955
+ capo_codedeploy.errors.tag_required_exception.TagRequiredException: <p>A tag was not specified.</p>
2956
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
2957
+ """
2958
+
2959
+ async def _handler(
2960
+ req: "AsyncOperationRequest[capo_codedeploy.types.tag_resource_input.TagResourceInput]",
2961
+ ) -> AsyncOperationResponse[
2962
+ "capo_codedeploy.types.tag_resource_output.TagResourceOutput"
2963
+ ]:
2964
+ import capo_codedeploy._operations.code_deploy_20141006.tag_resource
2965
+
2966
+ (
2967
+ output,
2968
+ http_response,
2969
+ ) = await capo_codedeploy._operations.code_deploy_20141006.tag_resource.async_tag_resource(
2970
+ req.options, req.input
2971
+ )
2972
+ return AsyncOperationResponse(output=output, response=http_response)
2973
+
2974
+ interceptors_, options_ = self.operation_options(config_overrides)
2975
+ input_: capo_codedeploy.types.tag_resource_input.TagResourceInput = {
2976
+ "resource_arn": resource_arn,
2977
+ "tags": tags,
2978
+ }
2979
+
2980
+ response = await aexecute_pipeline(
2981
+ AsyncOperationRequest(input=input_, options=options_),
2982
+ handler=_handler,
2983
+ interceptors=list(interceptors_),
2984
+ )
2985
+ await response.response.aclose()
2986
+ return response.output
2987
+
2988
+ async def untag_resource(
2989
+ self,
2990
+ resource_arn: "capo_codedeploy.types.arn.Arn",
2991
+ tag_keys: "capo_codedeploy.types.tag_key_list.TagKeyList",
2992
+ *,
2993
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
2994
+ ) -> "capo_codedeploy.types.untag_resource_output.UntagResourceOutput":
2995
+ """<p> Disassociates a resource from a list of tags. The resource is identified by the <code>ResourceArn</code> input parameter. The tags are identified by the list of keys in the <code>TagKeys</code> input parameter. </p>
2996
+
2997
+ Args:
2998
+ resource_arn: <p> The Amazon Resource Name (ARN) that specifies from which resource to disassociate the tags with the keys in the <code>TagKeys</code> input parameter. </p>
2999
+ tag_keys: <p> A list of keys of <code>Tag</code> objects. The <code>Tag</code> objects identified by the keys are disassociated from the resource specified by the <code>ResourceArn</code> input parameter. </p>
3000
+
3001
+ Raises:
3002
+ capo_codedeploy.errors.application_does_not_exist_exception.ApplicationDoesNotExistException: <p>The application does not exist with the user or Amazon Web Services account.</p>
3003
+ capo_codedeploy.errors.arn_not_supported_exception.ArnNotSupportedException: <p> The specified ARN is not supported. For example, it might be an ARN for a resource that is not expected. </p>
3004
+ capo_codedeploy.errors.deployment_config_does_not_exist_exception.DeploymentConfigDoesNotExistException: <p>The deployment configuration does not exist with the user or Amazon Web Services account.</p>
3005
+ capo_codedeploy.errors.deployment_group_does_not_exist_exception.DeploymentGroupDoesNotExistException: <p>The named deployment group with the user or Amazon Web Services account does not exist.</p>
3006
+ capo_codedeploy.errors.invalid_arn_exception.InvalidArnException: <p> The specified ARN is not in a valid format. </p>
3007
+ capo_codedeploy.errors.invalid_tags_to_add_exception.InvalidTagsToAddException: <p> The specified tags are not valid. </p>
3008
+ capo_codedeploy.errors.resource_arn_required_exception.ResourceArnRequiredException: <p> The ARN of a resource is required, but was not found. </p>
3009
+ capo_codedeploy.errors.tag_required_exception.TagRequiredException: <p>A tag was not specified.</p>
3010
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
3011
+ """
3012
+
3013
+ async def _handler(
3014
+ req: "AsyncOperationRequest[capo_codedeploy.types.untag_resource_input.UntagResourceInput]",
3015
+ ) -> AsyncOperationResponse[
3016
+ "capo_codedeploy.types.untag_resource_output.UntagResourceOutput"
3017
+ ]:
3018
+ import capo_codedeploy._operations.code_deploy_20141006.untag_resource
3019
+
3020
+ (
3021
+ output,
3022
+ http_response,
3023
+ ) = await capo_codedeploy._operations.code_deploy_20141006.untag_resource.async_untag_resource(
3024
+ req.options, req.input
3025
+ )
3026
+ return AsyncOperationResponse(output=output, response=http_response)
3027
+
3028
+ interceptors_, options_ = self.operation_options(config_overrides)
3029
+ input_: capo_codedeploy.types.untag_resource_input.UntagResourceInput = {
3030
+ "resource_arn": resource_arn,
3031
+ "tag_keys": tag_keys,
3032
+ }
3033
+
3034
+ response = await aexecute_pipeline(
3035
+ AsyncOperationRequest(input=input_, options=options_),
3036
+ handler=_handler,
3037
+ interceptors=list(interceptors_),
3038
+ )
3039
+ await response.response.aclose()
3040
+ return response.output
3041
+
3042
+ async def update_application(
3043
+ self,
3044
+ *,
3045
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
3046
+ application_name: Optional[
3047
+ "capo_codedeploy.types.application_name.ApplicationName"
3048
+ ] = None,
3049
+ new_application_name: Optional[
3050
+ "capo_codedeploy.types.application_name.ApplicationName"
3051
+ ] = None,
3052
+ ) -> None:
3053
+ """<p>Changes the name of an application.</p>
3054
+
3055
+ Args:
3056
+ application_name: <p>The current name of the application you want to change.</p>
3057
+ new_application_name: <p>The new name to give the application.</p>
3058
+
3059
+ Raises:
3060
+ capo_codedeploy.errors.application_already_exists_exception.ApplicationAlreadyExistsException: <p>An application with the specified name with the user or Amazon Web Services account already exists.</p>
3061
+ capo_codedeploy.errors.application_does_not_exist_exception.ApplicationDoesNotExistException: <p>The application does not exist with the user or Amazon Web Services account.</p>
3062
+ capo_codedeploy.errors.application_name_required_exception.ApplicationNameRequiredException: <p>The minimum number of required application names was not specified.</p>
3063
+ capo_codedeploy.errors.invalid_application_name_exception.InvalidApplicationNameException: <p>The application name was specified in an invalid format.</p>
3064
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
3065
+ """
3066
+
3067
+ async def _handler(
3068
+ req: "AsyncOperationRequest[capo_codedeploy.types.update_application_input.UpdateApplicationInput]",
3069
+ ) -> AsyncOperationResponse[None]:
3070
+ import capo_codedeploy._operations.code_deploy_20141006.update_application
3071
+
3072
+ (
3073
+ output,
3074
+ http_response,
3075
+ ) = await capo_codedeploy._operations.code_deploy_20141006.update_application.async_update_application(
3076
+ req.options, req.input
3077
+ )
3078
+ return AsyncOperationResponse(output=output, response=http_response)
3079
+
3080
+ interceptors_, options_ = self.operation_options(config_overrides)
3081
+ input_: capo_codedeploy.types.update_application_input.UpdateApplicationInput = {}
3082
+ if application_name is not None:
3083
+ input_["application_name"] = application_name
3084
+ if new_application_name is not None:
3085
+ input_["new_application_name"] = new_application_name
3086
+
3087
+ response = await aexecute_pipeline(
3088
+ AsyncOperationRequest(input=input_, options=options_),
3089
+ handler=_handler,
3090
+ interceptors=list(interceptors_),
3091
+ )
3092
+ await response.response.aclose()
3093
+ return response.output
3094
+
3095
+ async def update_deployment_group(
3096
+ self,
3097
+ application_name: "capo_codedeploy.types.application_name.ApplicationName",
3098
+ current_deployment_group_name: "capo_codedeploy.types.deployment_group_name.DeploymentGroupName",
3099
+ *,
3100
+ config_overrides: Optional[AsyncCodeDeployClientConfig] = None,
3101
+ new_deployment_group_name: Optional[
3102
+ "capo_codedeploy.types.deployment_group_name.DeploymentGroupName"
3103
+ ] = None,
3104
+ deployment_config_name: Optional[
3105
+ "capo_codedeploy.types.deployment_config_name.DeploymentConfigName"
3106
+ ] = None,
3107
+ ec2_tag_filters: Optional[
3108
+ "capo_codedeploy.types.ec2_tag_filter_list.EC2TagFilterList"
3109
+ ] = None,
3110
+ on_premises_instance_tag_filters: Optional[
3111
+ "capo_codedeploy.types.tag_filter_list.TagFilterList"
3112
+ ] = None,
3113
+ auto_scaling_groups: Optional[
3114
+ "capo_codedeploy.types.auto_scaling_group_name_list.AutoScalingGroupNameList"
3115
+ ] = None,
3116
+ service_role_arn: Optional["capo_codedeploy.types.role.Role"] = None,
3117
+ trigger_configurations: Optional[
3118
+ "capo_codedeploy.types.trigger_config_list.TriggerConfigList"
3119
+ ] = None,
3120
+ alarm_configuration: Optional[
3121
+ "capo_codedeploy.types.alarm_configuration.AlarmConfiguration"
3122
+ ] = None,
3123
+ auto_rollback_configuration: Optional[
3124
+ "capo_codedeploy.types.auto_rollback_configuration.AutoRollbackConfiguration"
3125
+ ] = None,
3126
+ outdated_instances_strategy: Optional[
3127
+ "capo_codedeploy.types.outdated_instances_strategy.OutdatedInstancesStrategy"
3128
+ ] = None,
3129
+ deployment_style: Optional[
3130
+ "capo_codedeploy.types.deployment_style.DeploymentStyle"
3131
+ ] = None,
3132
+ blue_green_deployment_configuration: Optional[
3133
+ "capo_codedeploy.types.blue_green_deployment_configuration.BlueGreenDeploymentConfiguration"
3134
+ ] = None,
3135
+ load_balancer_info: Optional[
3136
+ "capo_codedeploy.types.load_balancer_info.LoadBalancerInfo"
3137
+ ] = None,
3138
+ ec2_tag_set: Optional["capo_codedeploy.types.ec2_tag_set.EC2TagSet"] = None,
3139
+ ecs_services: Optional[
3140
+ "capo_codedeploy.types.ecs_service_list.ECSServiceList"
3141
+ ] = None,
3142
+ on_premises_tag_set: Optional[
3143
+ "capo_codedeploy.types.on_premises_tag_set.OnPremisesTagSet"
3144
+ ] = None,
3145
+ termination_hook_enabled: Optional[
3146
+ "capo_codedeploy.types.nullable_boolean.NullableBoolean"
3147
+ ] = None,
3148
+ ) -> "capo_codedeploy.types.update_deployment_group_output.UpdateDeploymentGroupOutput":
3149
+ r"""<p>Changes information about a deployment group.</p>
3150
+
3151
+ Args:
3152
+ application_name: <p>The application name that corresponds to the deployment group to update.</p>
3153
+ current_deployment_group_name: <p>The current name of the deployment group.</p>
3154
+ new_deployment_group_name: <p>The new name of the deployment group, if you want to change it.</p>
3155
+ deployment_config_name: <p>The replacement deployment configuration name to use, if you want to change it.</p>
3156
+ ec2_tag_filters: <p>The replacement set of Amazon EC2 tags on which to filter, if you want to change them. To keep the existing tags, enter their names. To remove tags, do not enter any tag names.</p>
3157
+ on_premises_instance_tag_filters: <p>The replacement set of on-premises instance tags on which to filter, if you want to change them. To keep the existing tags, enter their names. To remove tags, do not enter any tag names.</p>
3158
+ auto_scaling_groups: <p>The replacement list of Auto Scaling groups to be included in the deployment group, if you want to change them.</p> <ul> <li> <p>To keep the Auto Scaling groups, enter their names or do not specify this parameter. </p> </li> <li> <p>To remove Auto Scaling groups, specify a non-null empty list of Auto Scaling group names to detach all CodeDeploy-managed Auto Scaling lifecycle hooks. For examples, see <a href=\"https://docs.aws.amazon.com/codedeploy/latest/userguide/troubleshooting-auto-scaling.html#troubleshooting-auto-scaling-heartbeat\">Amazon EC2 instances in an Amazon EC2 Auto Scaling group fail to launch and receive the error \"Heartbeat Timeout\"</a> in the <i>CodeDeploy User Guide</i>.</p> </li> </ul>
3159
+ service_role_arn: <p>A replacement ARN for the service role, if you want to change it.</p>
3160
+ trigger_configurations: <p>Information about triggers to change when the deployment group is updated. For examples, see <a href=\"https://docs.aws.amazon.com/codedeploy/latest/userguide/how-to-notify-edit.html\">Edit a Trigger in a CodeDeploy Deployment Group</a> in the <i>CodeDeploy User Guide</i>.</p>
3161
+ alarm_configuration: <p>Information to add or change about Amazon CloudWatch alarms when the deployment group is updated.</p>
3162
+ auto_rollback_configuration: <p>Information for an automatic rollback configuration that is added or changed when a deployment group is updated.</p>
3163
+ outdated_instances_strategy: <p>Indicates what happens when new Amazon EC2 instances are launched mid-deployment and do not receive the deployed application revision.</p> <p>If this option is set to <code>UPDATE</code> or is unspecified, CodeDeploy initiates one or more 'auto-update outdated instances' deployments to apply the deployed application revision to the new Amazon EC2 instances.</p> <p>If this option is set to <code>IGNORE</code>, CodeDeploy does not initiate a deployment to update the new Amazon EC2 instances. This may result in instances having different revisions.</p>
3164
+ deployment_style: <p>Information about the type of deployment, either in-place or blue/green, you want to run and whether to route deployment traffic behind a load balancer.</p>
3165
+ blue_green_deployment_configuration: <p>Information about blue/green deployment options for a deployment group.</p>
3166
+ load_balancer_info: <p>Information about the load balancer used in a deployment.</p>
3167
+ ec2_tag_set: <p>Information about groups of tags applied to on-premises instances. The deployment group includes only Amazon EC2 instances identified by all the tag groups.</p>
3168
+ ecs_services: <p> The target Amazon ECS services in the deployment group. This applies only to deployment groups that use the Amazon ECS compute platform. A target Amazon ECS service is specified as an Amazon ECS cluster and service name pair using the format <code><clustername>:<servicename></code>. </p>
3169
+ on_premises_tag_set: <p>Information about an on-premises instance tag set. The deployment group includes only on-premises instances identified by all the tag groups.</p>
3170
+ termination_hook_enabled: <p>This parameter only applies if you are using CodeDeploy with Amazon EC2 Auto Scaling. For more information, see <a href=\"https://docs.aws.amazon.com/codedeploy/latest/userguide/integrations-aws-auto-scaling.html\">Integrating CodeDeploy with Amazon EC2 Auto Scaling</a> in the <i>CodeDeploy User Guide</i>.</p> <p>Set <code>terminationHookEnabled</code> to <code>true</code> to have CodeDeploy install a termination hook into your Auto Scaling group when you update a deployment group. When this hook is installed, CodeDeploy will perform termination deployments.</p> <p>For information about termination deployments, see <a href=\"https://docs.aws.amazon.com/codedeploy/latest/userguide/integrations-aws-auto-scaling.html#integrations-aws-auto-scaling-behaviors-hook-enable\">Enabling termination deployments during Auto Scaling scale-in events</a> in the <i>CodeDeploy User Guide</i>.</p> <p>For more information about Auto Scaling scale-in events, see the <a href=\"https://docs.aws.amazon.com/autoscaling/ec2/userguide/ec2-auto-scaling-lifecycle.html#as-lifecycle-scale-in\">Scale in</a> topic in the <i>Amazon EC2 Auto Scaling User Guide</i>.</p>
3171
+
3172
+ Raises:
3173
+ capo_codedeploy.errors.alarms_limit_exceeded_exception.AlarmsLimitExceededException: <p>The maximum number of alarms for a deployment group (10) was exceeded.</p>
3174
+ capo_codedeploy.errors.application_does_not_exist_exception.ApplicationDoesNotExistException: <p>The application does not exist with the user or Amazon Web Services account.</p>
3175
+ capo_codedeploy.errors.application_name_required_exception.ApplicationNameRequiredException: <p>The minimum number of required application names was not specified.</p>
3176
+ capo_codedeploy.errors.deployment_config_does_not_exist_exception.DeploymentConfigDoesNotExistException: <p>The deployment configuration does not exist with the user or Amazon Web Services account.</p>
3177
+ capo_codedeploy.errors.deployment_group_already_exists_exception.DeploymentGroupAlreadyExistsException: <p>A deployment group with the specified name with the user or Amazon Web Services account already exists.</p>
3178
+ capo_codedeploy.errors.deployment_group_does_not_exist_exception.DeploymentGroupDoesNotExistException: <p>The named deployment group with the user or Amazon Web Services account does not exist.</p>
3179
+ capo_codedeploy.errors.deployment_group_name_required_exception.DeploymentGroupNameRequiredException: <p>The deployment group name was not specified.</p>
3180
+ capo_codedeploy.errors.ecs_service_mapping_limit_exceeded_exception.ECSServiceMappingLimitExceededException: <p> The Amazon ECS service is associated with more than one deployment groups. An Amazon ECS service can be associated with only one deployment group. </p>
3181
+ capo_codedeploy.errors.invalid_alarm_config_exception.InvalidAlarmConfigException: <p>The format of the alarm configuration is invalid. Possible causes include:</p> <ul> <li> <p>The alarm list is null.</p> </li> <li> <p>The alarm object is null.</p> </li> <li> <p>The alarm name is empty or null or exceeds the limit of 255 characters.</p> </li> <li> <p>Two alarms with the same name have been specified.</p> </li> <li> <p>The alarm configuration is enabled, but the alarm list is empty.</p> </li> </ul>
3182
+ capo_codedeploy.errors.invalid_application_name_exception.InvalidApplicationNameException: <p>The application name was specified in an invalid format.</p>
3183
+ capo_codedeploy.errors.invalid_auto_rollback_config_exception.InvalidAutoRollbackConfigException: <p>The automatic rollback configuration was specified in an invalid format. For example, automatic rollback is enabled, but an invalid triggering event type or no event types were listed.</p>
3184
+ capo_codedeploy.errors.invalid_auto_scaling_group_exception.InvalidAutoScalingGroupException: <p>The Auto Scaling group was specified in an invalid format or does not exist.</p>
3185
+ capo_codedeploy.errors.invalid_blue_green_deployment_configuration_exception.InvalidBlueGreenDeploymentConfigurationException: <p>The configuration for the blue/green deployment group was provided in an invalid format. For information about deployment configuration format, see <a>CreateDeploymentConfig</a>.</p>
3186
+ capo_codedeploy.errors.invalid_deployment_config_name_exception.InvalidDeploymentConfigNameException: <p>The deployment configuration name was specified in an invalid format.</p>
3187
+ capo_codedeploy.errors.invalid_deployment_group_name_exception.InvalidDeploymentGroupNameException: <p>The deployment group name was specified in an invalid format.</p>
3188
+ capo_codedeploy.errors.invalid_deployment_style_exception.InvalidDeploymentStyleException: <p>An invalid deployment style was specified. Valid deployment types include \"IN_PLACE\" and \"BLUE_GREEN.\" Valid deployment options include \"WITH_TRAFFIC_CONTROL\" and \"WITHOUT_TRAFFIC_CONTROL.\"</p>
3189
+ capo_codedeploy.errors.invalid_ec2_tag_combination_exception.InvalidEC2TagCombinationException: <p>A call was submitted that specified both Ec2TagFilters and Ec2TagSet, but only one of these data types can be used in a single call.</p>
3190
+ capo_codedeploy.errors.invalid_ec2_tag_exception.InvalidEC2TagException: <p>The tag was specified in an invalid format.</p>
3191
+ capo_codedeploy.errors.invalid_ecs_service_exception.InvalidECSServiceException: <p> The Amazon ECS service identifier is not valid. </p>
3192
+ capo_codedeploy.errors.invalid_input_exception.InvalidInputException: <p>The input was specified in an invalid format.</p>
3193
+ capo_codedeploy.errors.invalid_load_balancer_info_exception.InvalidLoadBalancerInfoException: <p>An invalid load balancer name, or no load balancer name, was specified.</p>
3194
+ capo_codedeploy.errors.invalid_on_premises_tag_combination_exception.InvalidOnPremisesTagCombinationException: <p>A call was submitted that specified both OnPremisesTagFilters and OnPremisesTagSet, but only one of these data types can be used in a single call.</p>
3195
+ capo_codedeploy.errors.invalid_role_exception.InvalidRoleException: <p>The service role ARN was specified in an invalid format. Or, if an Auto Scaling group was specified, the specified service role does not grant the appropriate permissions to Amazon EC2 Auto Scaling.</p>
3196
+ capo_codedeploy.errors.invalid_tag_exception.InvalidTagException: <p>The tag was specified in an invalid format.</p>
3197
+ capo_codedeploy.errors.invalid_target_group_pair_exception.InvalidTargetGroupPairException: <p> A target group pair associated with this deployment is not valid. </p>
3198
+ capo_codedeploy.errors.invalid_traffic_routing_configuration_exception.InvalidTrafficRoutingConfigurationException: <p> The configuration that specifies how traffic is routed during a deployment is invalid.</p>
3199
+ capo_codedeploy.errors.invalid_trigger_config_exception.InvalidTriggerConfigException: <p>The trigger was specified in an invalid format.</p>
3200
+ capo_codedeploy.errors.lifecycle_hook_limit_exceeded_exception.LifecycleHookLimitExceededException: <p>The limit for lifecycle hooks was exceeded.</p>
3201
+ capo_codedeploy.errors.tag_set_list_limit_exceeded_exception.TagSetListLimitExceededException: <p>The number of tag groups included in the tag set list exceeded the maximum allowed limit of 3.</p>
3202
+ capo_codedeploy.errors.throttling_exception.ThrottlingException: <p>An API function was called too frequently.</p>
3203
+ capo_codedeploy.errors.trigger_targets_limit_exceeded_exception.TriggerTargetsLimitExceededException: <p>The maximum allowed number of triggers was exceeded.</p>
3204
+ capo_codedeploy.errors.UnknownServiceError: The service returned an error code this client does not model.
3205
+ """
3206
+
3207
+ async def _handler(
3208
+ req: "AsyncOperationRequest[capo_codedeploy.types.update_deployment_group_input.UpdateDeploymentGroupInput]",
3209
+ ) -> AsyncOperationResponse[
3210
+ "capo_codedeploy.types.update_deployment_group_output.UpdateDeploymentGroupOutput"
3211
+ ]:
3212
+ import capo_codedeploy._operations.code_deploy_20141006.update_deployment_group
3213
+
3214
+ (
3215
+ output,
3216
+ http_response,
3217
+ ) = await capo_codedeploy._operations.code_deploy_20141006.update_deployment_group.async_update_deployment_group(
3218
+ req.options, req.input
3219
+ )
3220
+ return AsyncOperationResponse(output=output, response=http_response)
3221
+
3222
+ interceptors_, options_ = self.operation_options(config_overrides)
3223
+ input_: capo_codedeploy.types.update_deployment_group_input.UpdateDeploymentGroupInput = {
3224
+ "application_name": application_name,
3225
+ "current_deployment_group_name": current_deployment_group_name,
3226
+ }
3227
+ if new_deployment_group_name is not None:
3228
+ input_["new_deployment_group_name"] = new_deployment_group_name
3229
+ if deployment_config_name is not None:
3230
+ input_["deployment_config_name"] = deployment_config_name
3231
+ if ec2_tag_filters is not None:
3232
+ input_["ec2_tag_filters"] = ec2_tag_filters
3233
+ if on_premises_instance_tag_filters is not None:
3234
+ input_["on_premises_instance_tag_filters"] = (
3235
+ on_premises_instance_tag_filters
3236
+ )
3237
+ if auto_scaling_groups is not None:
3238
+ input_["auto_scaling_groups"] = auto_scaling_groups
3239
+ if service_role_arn is not None:
3240
+ input_["service_role_arn"] = service_role_arn
3241
+ if trigger_configurations is not None:
3242
+ input_["trigger_configurations"] = trigger_configurations
3243
+ if alarm_configuration is not None:
3244
+ input_["alarm_configuration"] = alarm_configuration
3245
+ if auto_rollback_configuration is not None:
3246
+ input_["auto_rollback_configuration"] = auto_rollback_configuration
3247
+ if outdated_instances_strategy is not None:
3248
+ input_["outdated_instances_strategy"] = outdated_instances_strategy
3249
+ if deployment_style is not None:
3250
+ input_["deployment_style"] = deployment_style
3251
+ if blue_green_deployment_configuration is not None:
3252
+ input_["blue_green_deployment_configuration"] = (
3253
+ blue_green_deployment_configuration
3254
+ )
3255
+ if load_balancer_info is not None:
3256
+ input_["load_balancer_info"] = load_balancer_info
3257
+ if ec2_tag_set is not None:
3258
+ input_["ec2_tag_set"] = ec2_tag_set
3259
+ if ecs_services is not None:
3260
+ input_["ecs_services"] = ecs_services
3261
+ if on_premises_tag_set is not None:
3262
+ input_["on_premises_tag_set"] = on_premises_tag_set
3263
+ if termination_hook_enabled is not None:
3264
+ input_["termination_hook_enabled"] = termination_hook_enabled
3265
+
3266
+ response = await aexecute_pipeline(
3267
+ AsyncOperationRequest(input=input_, options=options_),
3268
+ handler=_handler,
3269
+ interceptors=list(interceptors_),
3270
+ )
3271
+ await response.response.aclose()
3272
+ return response.output
3273
+
3274
+ async def __aenter__(self) -> Self:
3275
+ return self
3276
+
3277
+ async def __aexit__(self, exc_type: Any, exc: Any, tb: Any):
3278
+ await self._client.aclose()