A company is migrating a distributed application to AWS. The application serves variable workloads. The legacy platform consists of a primary server that coordinates jobs across multiple compute nodes. The company wants to modernize the application with a solution that maximizes resiliency and scalability.
How should a solutions architect design the architecture to meet these requirements?
A. Configure an Amazon Simple Queue Service (Amazon SQS) queue as a destination for the jobs. Implement the compute nodes with Amazon EC2 instances that are managed in an Auto Scaling group. Configure EC2 Auto Scaling to use scheduled scaling.
B. Configure an Amazon Simple Queue Service (Amazon SQS) queue as a destination for the jobs. Implement the compute nodes with Amazon EC2 instances that are managed in an Auto Scaling group. Configure EC2 Auto Scaling based on the size of the queue.
C. Implement the primary server and the compute nodes with Amazon EC2 instances that are managed in an Auto Scaling group. Configure AWS CloudTrail as a destination for the jobs. Configure EC2 Auto Scaling based on the load on the primary server.
D. Implement the primary server and the compute nodes with Amazon EC2 instances that are managed in an Auto Scaling group. Configure Amazon EventBridge (Amazon CloudWatch Events) as a destination for the jobs. Configure EC2 Auto Scaling based on the load on the compute nodes.
B
技巧:排除明顯錯(cuò)誤選項(xiàng),在沒有明顯錯(cuò)誤的選項(xiàng)中選擇最合理的選項(xiàng)。
某公司在將分布式應(yīng)用程序遷移到 AWS 平臺(tái)。原始平臺(tái)由一個(gè)主服務(wù)器和多個(gè)計(jì)算節(jié)點(diǎn)組成,主服務(wù)器負(fù)責(zé)協(xié)調(diào)工作。公司希望最大化應(yīng)用程序的彈性和可擴(kuò)展性,以適應(yīng)不斷變化的工作負(fù)載。公司需要設(shè)計(jì)一個(gè)解決方案,可以有效地管理和擴(kuò)展資源,同時(shí)確保系統(tǒng)的高可用性。
A. 不正確。配置 Amazon SQS 作為作業(yè)目的地,使用 Auto Scaling 組管理 EC2 實(shí)例作為計(jì)算節(jié)點(diǎn),并基于計(jì)劃進(jìn)行Auto Scaling。使用Amazon SQS可以解耦作業(yè)的生產(chǎn)和消費(fèi),有助于提高系統(tǒng)的彈性和可擴(kuò)展性,但是基于計(jì)劃的 Auto Scaling 可能無法很好地適應(yīng)不斷變化的工作負(fù)載,因?yàn)樗蕾囉陬A(yù)設(shè)的縮放計(jì)劃而不是實(shí)際的工作負(fù)載需求。
B. 正確。配置 Amazon SQS 作為作業(yè)目的地,使用Auto Scaling 組管理 EC2 實(shí)例作為計(jì)算節(jié)點(diǎn),并根據(jù)隊(duì)列大小配置 Auto Scaling 組。該方案結(jié)合了Amazon SQS的解耦能力和基于隊(duì)列大小的實(shí)際需求進(jìn)行自動(dòng)擴(kuò)展。當(dāng)隊(duì)列中的作業(yè)數(shù)量增加時(shí),Auto Scaling 組會(huì)自動(dòng)增加EC2實(shí)例的數(shù)量以處理更多的作業(yè),反之亦然。這有助于確保系統(tǒng)能夠根據(jù)需要?jiǎng)討B(tài)調(diào)整資源,從而滿足彈性和可擴(kuò)展性的要求。
C. 不正確。使用 Auto Scaling 組管理包含主服務(wù)器和計(jì)算節(jié)點(diǎn)的 EC2 實(shí)例,將 AWS CloudTrail 作為作業(yè)目的地,并基于主服務(wù)器的負(fù)載配置Auto Scaling 組。AWS CloudTrail 主要用于記錄AWS賬戶的活動(dòng),而不是作為作業(yè)隊(duì)列。另外基于主服務(wù)器的負(fù)載進(jìn)行Auto Scaling可能無法反映整體系統(tǒng)的負(fù)載情況,特別是當(dāng)計(jì)算節(jié)點(diǎn)是處理實(shí)際作業(yè)的主要資源時(shí)。
D. 不正確。使用Auto Scaling組管理包含主服務(wù)器和計(jì)算節(jié)點(diǎn)的EC2實(shí)例,將Amazon EventBridge作為作業(yè)目的地,并基于計(jì)算節(jié)點(diǎn)的負(fù)載配置Auto Scaling 組。Amazon EventBridge主要用于事件路由,而不是作為作業(yè)隊(duì)列。基于計(jì)算節(jié)點(diǎn)的負(fù)載進(jìn)行Auto Scaling看似合理,但使用主服務(wù)器和固定隊(duì)列(如Amazon SQS)的組合通常更為靈活和高效。