今日を知り、明日を変えるシステム運用メディア

スタックリファクタリングで AWS CloudFormation スタックをシームレスに再形成

スタックリファクタリングで AWS CloudFormation スタックをシームレスに再形成

本記事は、2025 年 2 月 6 日にAWS公式サイトの What’s New with AWS? に掲載された英語記事を自動翻訳したものです。

ニュース内容

AWS CloudFormation では、スタック リファクタリングと呼ばれる新しい機能が導入され、CloudFormation スタック全体でクラウド リソースを簡単に再編成できるようになりました。スタック リファクタリングを使用すると、スタック間でリソースを移動したり、モノリシック スタックを小さなコンポーネントに分割したり、スタック内のリソースの論理名を変更したりできます。これにより、スタックをアーキテクチャ パターン、運用上のニーズ、またはビジネス要件に合わせて調整できます。

ワークロードが拡大し、要件が進化するにつれて、リソースを新しいスタック構造に再設計する必要が生じることがあります。たとえば、モノリシック スタックを分割してリソースのライフサイクル管理を容易にしたり、リソースの論理 ID の名前を変更して新しい命名規則に合わせたりする必要がある場合があります。以前は、スタックのリファクタリングには、テンプレートを更新して対象のリソースを保持し、現在のスタックから削除してから新しいスタックにインポートするなど、複数の手動の手順が必要でした。スタック リファクタリングにより、このプロセスの速度と安全性が向上します。

スタックをリファクタリングするには、まず、目的のスタック構造を反映する CloudFormation テンプレートを用意します。次に、リファクタリング操作のプレビューを生成し、リファクタリングの変更が要件と一致していることを確認できます。計画された変更が期待どおりであれば、アトミックワークフローを通じてリファクタリング操作を実行できます。この新しい機能により、進化するアーキテクチャパターンにシームレスかつ継続的に適応できます。

スタックリファクタリングは、CloudFormation がサポートされているすべての AWS リージョンで利用できます。開始するには、CloudFormation テンプレートを更新して目的のスタック構造を反映させ、AWS CLI または SDK を使用してリファクタリング操作を実行します。この機能の詳細については、ユーザーガイドをご覧ください。

原文

AWS CloudFormation introduces a new capability called stack refactoring that makes it easy to reorganize cloud resources across your CloudFormation stacks. Stack refactoring enables you to move resources from one stack to another, split monolithic stacks into smaller components, and rename the logical name of resources within a stack. This enables you to adapt your stacks to meet architectural patterns, operational needs, or business requirements.

As your workloads scale and requirements evolve, re-architecting resources into a new stack structure can become necessary. For example, you may need to split a monolithic stack for easier resource lifecycle management or rename resource logical IDs to align with new naming conventions. Previously, refactoring a stack required multiple manual steps, such as updating templates to retain targeted resources, removing them from current stacks, and then importing them into new stacks. Stack refactoring improves the speed and safety of this process. To refactor a stack, you first provide the CloudFormation templates that reflect the desired stack structure. Then, you generate a preview of the refactor operation, allowing you to confirm that the refactoring changes align with your requirements. If the planned changes meet your expectations, you can execute the refactor operation through an atomic workflow. This new capability enables seamless and continuous adaptation to evolving architectural patterns.

Stack refactor is available in all AWS Regions where CloudFormation is supported. To get started, update your CloudFormation templates to reflect the desired stack structure, then use the AWS CLI or SDK to perform the refactor operation. Visit our user guide to learn more about this feature.

引用元:Reshape your AWS CloudFormation stacks seamlessly with stack refactoring

人気の記事

最新情報をお届けします!

最新のITトレンドやセキュリティ対策の情報を、メルマガでいち早く受け取りませんか?ぜひご登録ください

メルマガ登録