When interviewers ask about microservices versus monoliths they are probing three things: your grasp of architectural fundamentals, your ability to match an approach to a business need, and whether you can tell a story that demonstrates real‑world impact. Below are the most frequently asked questions, a crisp spoken answer you can deliver in 45–90 seconds, and the next‑level follow‑up most interviewers tend to throw at you.

1. What is a monolith, and why would a team choose it?

A monolith is a single deployable unit that contains all the business logic, data access, and UI layers of an application. Teams often start with a monolith because it:

  • Reduces initial setup overhead – one codebase, one build pipeline, one runtime.
  • Simplifies debugging – a single process means a single stack trace.
  • Keeps coordination low – developers share the same repository and can see each other's changes instantly.

Spoken answer

"A monolith is an app that runs as one process, housing everything from the UI to the database layer. New teams gravitate to it because it’s fast to get off the ground – you only need one repo, one CI pipeline, and one deployment target. That speed lets you validate product‑market fit before you invest in the overhead of service boundaries."

Typical follow‑up

“Can you give an example of a situation where a monolith became a problem later on?”

2. What is a microservice, and what problems does it solve?

A microservice is a small, independently deployable service that owns a specific business capability and communicates with others via lightweight protocols (usually HTTP/REST or gRPC). It addresses:

  • Scalability – you can scale hot spots without over‑provisioning the whole app.
  • Team autonomy – each service can be owned by a dedicated squad, enabling parallel development.
  • Technology heterogeneity – teams can pick the best language or framework for their domain.

Spoken answer

"Microservices break a system into independent units, each responsible for a single domain concept like payments or inventory. Because each unit runs in its own container, you can scale the payment service alone when traffic spikes, and the inventory team can deploy a new feature without touching the payment code. This isolation also lets teams use the language that makes the most sense for their problem."

Typical follow‑up

“How do you handle data consistency across services?”

3. How do you decide which architecture to use for a new product?

The decision hinges on three axes:

  1. Business velocity – If the product is in discovery, a monolith lets you iterate quickly.
  2. Domain complexity – Highly decoupled domains (e.g., a marketplace with separate buyer and seller flows) often benefit from service boundaries.
  3. Operational maturity – Microservices require robust CI/CD, observability, and governance; you need those practices in place before you split.

Spoken answer

"I start by asking how fast the product needs to change. If we’re still testing hypotheses, I’d choose a monolith to keep the feedback loop short. Once the core domain stabilises and we see clear, independent load patterns—say, a recommendation engine that needs GPU scaling—I’d carve that part out into a microservice. The trade‑off is that we now need automated deployments, distributed tracing, and a contract‑testing strategy."

Typical follow‑up

“What signals would make you switch from a monolith to microservices later on?”

4. What are the biggest operational challenges of microservices?

  • Observability – You need centralized logging, metrics, and tracing to understand cross‑service flows.
  • Network reliability – Calls between services can fail; you must implement retries, circuit breakers, and timeouts.
  • Deployment coordination – Even though services are independent, schema changes often require versioned APIs and backward compatibility.
  • Testing overhead – End‑to‑end tests become more complex; contract testing and consumer‑driven contracts are essential.

Spoken answer

"Microservices give you flexibility, but they also hand you a lot of operational baggage. You now have to monitor dozens of containers, manage network latency, and make sure a failure in one service doesn’t cascade. That means investing in distributed tracing, implementing retry policies, and keeping API contracts stable across versions. Without that foundation, the system becomes fragile fast."

Typical follow‑up

“How have you mitigated one of those challenges in a past project?”

5. How do you handle data management in a microservice architecture?

Two common patterns:

  • Database per service – Each service owns its schema, preventing tight coupling.
  • Shared database with bounded contexts – In early stages, teams may share a DB but enforce logical boundaries through separate schemas or tables.

When services need the same data, you can use:

  • Event sourcing – Services publish domain events; others subscribe and build their own read models.
  • API composition – An aggregator service calls multiple downstream services and merges the results.

Spoken answer

"I usually give each service its own database to avoid schema coupling. When two services need the same piece of data, I either publish an event that the other service can consume, or I expose a read‑only API that the consumer can call. This keeps ownership clear and lets each team evolve their model independently."

Typical follow‑up

“What trade‑offs did you notice when you moved from a shared DB to DB‑per‑service?”

6. Can you describe a time you migrated a monolith to microservices?

Context – At my previous company we ran an e‑commerce platform as a monolith. As the checkout flow grew, latency spikes during flash sales became a bottleneck.

Approach –

  1. Identified the checkout module as a high‑traffic, low‑coupling candidate.
  2. Extracted it into a separate service with its own PostgreSQL instance.
  3. Added an event bus (Kafka) for order‑created events, allowing the inventory service to react asynchronously.
  4. Implemented contract tests to guarantee the new API behaved like the old internal method.
  5. Deployed the service behind a canary release, monitoring latency and error rates.

Result – The checkout latency dropped by roughly 40 % during peak traffic, and the team could push a new payment provider without touching the inventory code.

Spoken answer

"In a recent role I split the checkout flow out of a large monolith because it was the source of latency during sales events. I gave it its own database, exposed a REST endpoint, and used Kafka to broadcast order events. After a staged rollout, we saw checkout latency fall by about forty percent, and the payment team could iterate independently."

Typical follow‑up

“What was the hardest part of that migration, and how did you overcome it?”

7. How do you keep a microservice ecosystem from turning into a “spaghetti of services”?

  • Domain‑driven design – Define clear bounded contexts and keep services aligned with business capabilities.
  • Service catalog – Maintain an up‑to‑date registry that documents owners, responsibilities, and versioning.
  • Governance rules – Enforce API versioning, deprecation policies, and naming conventions.
  • Periodic refactoring – Schedule architecture reviews to prune unused services and merge overly granular ones.

Spoken answer

"I prevent service sprawl by anchoring each service to a bounded context defined in the domain model. A living service catalog records owners and contracts, and we enforce versioning rules so no team can break another’s API without a deprecation window. Regular architecture reviews let us retire dead services and combine ones that are too small."

Typical follow‑up

“Do you have a concrete example of a service you retired and why?”

8. When would you choose a hybrid approach?

Hybrid architectures keep a core monolith for tightly coupled features while exposing a few microservices for high‑scale or highly autonomous domains. This is common when:

  • The product is mature, but a new module (e.g., a recommendation engine) demands separate scaling.
  • Legacy code cannot be safely broken up, yet you need to modernize parts of the system.

Spoken answer

"A hybrid model works when you have a stable core that would be risky to split, but you need to scale a specific domain like real‑time analytics. You keep the core as a monolith, add a separate service for the analytics pipeline, and route calls through a gateway. This gives you the best of both worlds without a full rewrite."

Typical follow‑up

“How do you manage authentication across the monolith and the new service?”

9. How does the choice affect developer productivity?

  • Monolith – Faster local builds, fewer moving parts, easier onboarding.
  • Microservices – Enables parallel workstreams, but each service requires its own environment, which can increase context switching.
  • Hybrid – Balances the two; teams can focus on their service while still sharing common libraries.

Spoken answer

"With a monolith, a new dev can spin up the whole app locally and see end‑to‑end behavior quickly. Microservices let multiple squads ship independently, but each service needs its own container, which can slow down local testing. A hybrid approach tries to give you the speed of a monolith for core features while still letting specialized teams own high‑scale services."

Typical follow‑up

“What tooling have you used to smooth the local development experience for microservices?”

10. How do you measure success after a migration?

Key indicators include:

MetricMonolith baselinePost‑migration target
Checkout latency (p95)1.2 s< 0.8 s
Deployment frequency1 per week3+ per week
Failure rate (service‑level incidents)5 per month≤ 2 per month
Team autonomy (services owned per squad)12–3

Collect these numbers from your monitoring stack and compare them to the business goals you set before the migration.

Spoken answer

"I measure success with a mix of performance and delivery metrics: latency drops, higher deployment frequency, and fewer incidents. For example, after moving checkout to a service we cut p95 latency from 1.2 seconds to under 0.8 seconds and increased deployments from weekly to three times a week."

Typical follow‑up

“What did you learn from the metrics that surprised you?”


How to practice this

  1. Record yourself – Use a voice recorder or a tool like Call Assistant to answer each question aloud, keeping the response under 90 seconds.
  2. Add a follow‑up – After each answer, pause and answer the typical follow‑up you expect. This trains you to keep the conversation on track.
  3. Ground the story – Pick a real project from your resume, write a one‑minute narrative, and rehearse it until the details flow naturally.

FAQ

  • Q: Should I always recommend microservices over a monolith? A: No. Choose the architecture that solves the business problem with the least overhead. Many startups stay monolithic for the first few years to move fast.
  • Q: How many services is too many? A: There’s no hard limit, but if a team spends more time managing service boundaries than writing code, you’ve likely crossed the sweet spot.
  • Q: What’s the safest way to split a monolith? A: Start with a low‑coupling, high‑traffic domain, give it its own database, expose a thin API, and use contract tests to guarantee behavior.
  • Q: Can I mix deployment models (e.g., Docker for services, serverless for others)? A: Yes. Hybrid models often combine containers for stateful services and serverless functions for event‑driven pieces, as long as you keep observability consistent.

Frequently asked questions

Should I always recommend microservices over a monolith?

No. Choose the architecture that solves the business problem with the least overhead. Many startups stay monolithic for the first few years to move fast.

How many services is too many?

There’s no hard limit, but if a team spends more time managing service boundaries than writing code, you’ve likely crossed the sweet spot.

What’s the safest way to split a monolith?

Start with a low‑coupling, high‑traffic domain, give it its own database, expose a thin API, and use contract tests to guarantee behavior.

Can I mix deployment models (e.g., Docker for services, serverless for others)?

Yes. Hybrid models often combine containers for stateful services and serverless functions for event‑driven pieces, as long as you keep observability consistent.

#concept questions#microservices#monoliths#architecture#interview prep#microservices vs monoliths