| Hello Reader, The two most prominent architecture patterns are microservices and Event-Driven Architecture (EDA). Let’s examine their differences and implementations, with the architecture diagram below: Request Response FlowTraditional microservice is synchronous i.e. the request and response happens on the same invocation. For example, if you are inserting data into the backend database using a microservice as shown in the left diagram, the invocation from the user will stay active till the Lambda inserts the info into the database, replies success back to the API Gateway, and API Gateway sends the response back to the user. Whereas with Event Driven, User gets a confirmation that the message is inserted into an event storage/processing service (SQS in this case) using the API Gateway. But he doesn’t get the response from the Lambda, which is inserting the message into the database, on the same invocation. Instead, the backend Lambda needs to send the response out after the message has been inserted into the database if the user needs to be notified. In this case the Lambda is invoking a websocket API, to notify the user. Alternatively, the user can query the status of the message independently using a separate microservice. Scaling (Important!)In a microservice, all the components (API Gateway, Lambda, Dynamo) need to scale up and down at the same rate. When traffic increases, all these three components will scale up together. However, if concurrent traffic exceeds a threshold beyond a service, let’s say Dynamo or Lambda max concurrency limit, transaction will fail. With EDA, the producer and consumer are decoupled. API Gateway, and Lambda/Database can scale independently. When traffic increases, API Gateway can scale up and insert messages into the SQS. However the backend Lambda and Dynamo are protected from this burst. Lambda can consume messages at a rate not to overwhelm the database. This also leads to EDA being more cost effective. Retry MechanismIf a microservice transaction fails, the user needs to send the request again. There is no default retry mechanism. With EDA, once the message is in SQS, even if Lambda fails, SQS will automatically retry to reprocess the messages. ConclusionSo which one is better? Well, as always, the answer is “it depends”! EDA can handle higher scale, and is generally more cost effective than synchronous microservice. However, in some cases you need a traditional synchronous microservice. In most applications, microservice and EDA can work together. There are parts of applications that can be broken down to be EDA. As we architects like to say, it’s NOT all or nothing, instead it’s the right tool for the right job. AWS Solutions Architect Interview MistakesAs a veteran interviewer, I see these mistakes costing candidates the offer. I explained these common (yet secret!) errors with actual questions and answers in this video:  If you have found this newsletter helpful, and want to support me 🙏: Checkout my bestselling courses on AWS, System Design, Kubernetes, DevOps, and more: Max discounted links AWS SA Bootcamp with Live Classes, Mock Interviews, Hands-On, Resume Improvement and more: https://www.sabootcamp.com/  Keep learning and keep rocking 🚀, Raj | 
Free Cloud Interview Guide to crush your next interview. Plus, real-world answers for cloud interviews, and system design from a top AWS Solutions Architect.
Hello Reader, In today’s post, let’s look at another correct but average answer and a great answer that gets you hired to common cloud interview questions. This question is even more relevant now, after this week's AWS outage! Question - How did you do Disaster Recovery (DR) for your AWS application? Common but average answer - I will replicate it to another region What the interviewer is looking for is how DR strategies are chosen, and what are the different strategies. As an SA, you will be...
Hello Reader, Recently, I had the privilege of speaking to the Computer Science and Business Club at Rutgers University - ranked #1 in New Jersey for Engineering and Computer Science by U.S. News & World Report. It was incredible to see how driven and curious these students were. Many already had offers from Amazon, JPMorgan, and other top companies. Talking with them took me right back to my college days - studying for exams, chasing grades, and trying to figure out how to land that first...
Hello Reader, Another week, another AI announcement. But this one is worth studying because this one will become the defacto standard of running agents on AWS. I am talking about newly released Amazon AgentCore. Let's dive in. 🧩 The Big Picture: Why Agents Exist Let’s break it down using a practical example: What happens when a user asks an LLM app: What’s the time in New York? What’s the weather there? List my S3 buckets The LLM don't have these information, hence it needs to invoke tools...