Skip to content
Sharp

Microservice Architecture interview questions

Bounded Contexts, Database per Service, Docker Containerization, Eventual Consistency (Sagas), Kubernetes Orchestration, Message Brokers (Kafka)

99 questions with answers and explanations · 99 flashcards

Questions (page 2 of 2)

  1. In microservices, how does the 'Circuit Breaker' pattern enhance resilience?Multiple choiceMedium
  2. In a microservices-based e-commerce system using the Saga pattern, what is a common approach to handle a payment failure when processing an order?Multiple choiceMedium
  3. Which Kubernetes component is responsible for automatically scaling the number of pods based on observed CPU utilization?Multiple choiceMedium
  4. Which component in a Saga pattern is responsible for undoing actions if a transaction fails?Multiple choiceMedium
  5. When designing a Dockerfile for a microservice, which component should NOT be included to maintain immutability?Multiple choiceMedium
  6. How does Kubernetes handle a node that is not responding?Multiple choiceEasy
  7. Which basis most strongly justifies splitting a microservice out of a monolith?Multiple choiceEasy
  8. Why do teams use topics in Kafka in production code?Multiple choiceEasy
  9. How would you explain a key benefit of using Apache Kafka in a microservices architecture in an interview?Multiple choiceMedium
  10. How does Kafka handle message delivery when a consumer is temporarily offline?Multiple choiceMedium
  11. What command is used to create a Docker image from a Dockerfile?Multiple choiceEasy
  12. Which tool would you use for tracing requests across microservices to debug a distributed system?Multiple choiceMedium
  13. In the context of distributed tracing, what is a Correlation ID used for?Multiple choiceHard
  14. Why should microservices avoid direct SQL joins across service databases?Multiple choiceMedium
  15. In a Kafka architecture, how can you ensure that messages are processed only once by a consumer?Multiple choiceHard
  16. How would you explain a 'distributed monolith' in the context of microservices in an interview?Multiple choiceEasy
  17. Which of the following scenarios best illustrates asynchronous communication in a microservices architecture?Multiple choiceMedium
  18. Why might HTTP API calls be preferred over SQL JOINs across microservices?Multiple choiceMedium
  19. Why is the 'eventual consistency' model often used in microservices architectures?Multiple choiceMedium
  20. Which characteristic best describes a microservice that differentiates it from a traditional monolithic application?Multiple choiceMedium
  21. In a microservices architecture, how is eventual consistency achieved using the Saga pattern?Multiple choiceHard
  22. What does using a Saga pattern in microservices mainly aim to achieve?Multiple choiceEasy
  23. Why is it important for container processes to be isolated from the host operating system?Multiple choiceMedium
  24. In a Docker container, how can you ensure that the Java application is decoupled from the host's Java version?Multiple choiceHard
  25. Why do teams use Docker for deploying microservices in production code?Multiple choiceEasy
  26. How would you explain a potential risk of not using immutable Docker images in a microservices architecture in an interview?Multiple choiceHard
  27. What role does Docker play in a microservices architecture?Multiple choiceEasy
  28. Which of the following best describes the concept of 'eventual consistency' in a distributed system?Multiple choiceHard
  29. How does the choreography-based Saga pattern coordinate transactions?Multiple choiceMedium
  30. Why does Kubernetes in managing a microservices architecture matter in this design?Multiple choiceEasy
  31. Why does a Circuit Breaker in a microservices architecture matter in this design?Multiple choiceMedium
  32. Why is splitting into OrderControllerService, OrderValidationService, and OrderRepositoryService usually a bad microservice design?Multiple choiceMedium
  33. In an event-driven system, what is the role of a Circuit Breaker pattern?Multiple choiceHard
  34. Why is the concept of 'bounded context' important in defining microservices?Multiple choiceEasy
  35. What command is used to create a new Kubernetes Deployment?Multiple choiceEasy
  36. In microservices, why is it crucial to avoid synchronous communication for service interactions?Multiple choiceMedium
  37. Why is it challenging to maintain ACID properties in a microservices architecture?Multiple choiceEasy
  38. Why do teams use Correlation IDs in distributed tracing in production code?Multiple choiceMedium
  39. How does Kafka ensure message ordering within a topic partition?Multiple choiceMedium
  40. Which of the following describes a 'topic' in Kafka?Multiple choiceMedium
  41. Why is eventual consistency through Sagas important in microservices architecture?Multiple choiceMedium
  42. In a microservices architecture, what is a common use case for Kubernetes?Multiple choiceMedium
  43. How would you explain a potential risk of using the Saga pattern in a highly dynamic microservices environment in an interview?Multiple choiceHard
  44. Why does decoupling producers and consumers in a microservices architecture using Apache Kafka help in practice?Multiple choiceEasy
  45. What does the term 'compensating transaction' refer to in a Saga?Multiple choiceEasy
  46. How would you explain a key advantage of using microservices architecture over a monolithic architecture in an interview?Multiple choiceMedium
  47. What role does Apache Kafka play in an event-driven microservices architecture?Multiple choiceHard
  48. How would you explain a potential pitfall of using event-driven architecture with Apache Kafka in a microservices ecosystem in an interview?Multiple choiceHard
  49. What problem does Docker solve for developers who face the 'It works on my machine' paradox?Multiple choiceEasy