
Answer-first summary for fast verification
Answer: Deploy the application by using AWS Elastic Beanstalk. Configure a load-balanced environment and a rolling deployment policy.
## Explanation **Correct Answer: B** **Why Option B is correct:** 1. **AWS Elastic Beanstalk** is specifically designed for deploying and managing web applications (including Java/Tomcat applications) with minimal infrastructure management. 2. **Load-balanced environment** ensures high availability by distributing traffic across multiple instances. 3. **Rolling deployment policy** allows for zero-downtime deployments, maintaining application availability during updates. 4. Elastic Beanstalk automatically handles capacity provisioning, load balancing, auto-scaling, and application health monitoring. 5. For the MySQL database, the architect would typically use Amazon RDS for MySQL (managed database service) which provides high availability, automated backups, and easy scaling. **Why other options are incorrect:** **Option A (AWS Lambda):** - Lambda is serverless compute for event-driven applications, not suitable for complex Java applications requiring Apache Tomcat. - Lambda has limitations on execution time (15 minutes max), memory, and doesn't support traditional Java web application deployment patterns. - Not designed for long-running applications with persistent connections. **Option C (Amazon ElastiCache):** - ElastiCache is an in-memory caching service (Redis/Memcached), not a relational database replacement for MySQL. - This option only addresses the database aspect incorrectly and doesn't address the Java/Tomcat application deployment requirements. **Option D (EC2 with manual setup):** - While this could work, it requires significant manual configuration and management. - Installing MySQL on EC2 instances doesn't provide the same level of high availability, automated backups, and managed services as Amazon RDS. - The approach is more complex and error-prone compared to using managed services like Elastic Beanstalk and RDS. - Auto Scaling groups help with availability but don't provide the same level of application management as Elastic Beanstalk. **Key AWS Services for this scenario:** 1. **AWS Elastic Beanstalk** - For deploying and managing the Java/Tomcat application 2. **Amazon RDS for MySQL** - For the managed MySQL database with high availability 3. **Application Load Balancer** - For distributing traffic across instances 4. **Auto Scaling** - For automatically adjusting capacity based on demand This combination provides a highly available, scalable, and managed solution that meets all requirements with minimal operational overhead.
Author: LeetQuiz Editorial Team
Ultimate access to all questions.
No comments yet.
A solutions architect is implementing a complex Java application with a MySQL database. The Java application must be deployed on Apache Tomcat and must be highly available.
What should the solutions architect do to meet these requirements?
A
Deploy the application in AWS Lambda. Configure an Amazon API Gateway API to connect with the Lambda functions.
B
Deploy the application by using AWS Elastic Beanstalk. Configure a load-balanced environment and a rolling deployment policy.
C
Migrate the database to Amazon ElastiCache. Configure the ElastiCache security group to allow access from the application.
D
Launch an Amazon EC2 instance. Install a MySQL server on the EC2 instance. Configure the application on the server. Create an AMI. Use the AMI to create a launch template with an Auto Scaling group.