Why We're Not Using Microservices

A Devopedia Case Study

What is Devopedia?

  • A knowledge-sharing platform inspired partly by Wikipedia
  • Developers can collaborate on content creation and editing
  • Simple explanations that avoid abstruse difficult technical jargon
  • Built as a responsive web app
  • Managed by Devopedia Foundation

Joomla! MVC Architecture

 

Model-View-Controller

Source: https://joomla.stackexchange.com/questions/599/diagram-of-joomla-architecture

Abstractions in Joomla! CMS

 

Components

Modules

Plugins

Templates

Source: https://www.javatpoint.com/architecture-of-joomla

Arch. of Devopedia App

Let's see some code!

When Monoliths Make Sense

  • For a startup with limited resources
  • Release an MVP quickly
  • No experience in building distributed systems
  • No performance bottlenecks
  • Team is well-versed in a particular framework and employs it effectively

The Evolution

Users

Articles

Versioning

Drafts

Reviews

Social Login

Locks

Acronyms

Requests

Comments

Likes

Workshops

Badges

DevCoins

ML Models

Simplicity is a great virtue but it requires hard work to achieve it and education to appreciate it. And to make matters worse: complexity sells better.

-- Edsger W. Dijkstra

Edsger W. Dijkstra

Source: https://dev.to/alex_barashkov/microservices-vs-monolith-architecture-4l1m

Monolith

  1. Single deployable unit
  2. Application evolves as a single unit
  3. Complexity increases with time (code, teamsize, etc.)
  4. Scaling is a limited to vertical scaling
  5. Reliability has its limits
  6. Single platform and technology
  7. Database transactions

Microservices

  1. Separately deployable services
  2. Each service can evolve separately
  3. Complexity is managed in small units
  4. Each service can be scaled independently
  5. Higher reliability
  6. Multiple choice of platforms and technologies
  7. Eventual consistency

Challenges with Microservices

Introduces network latency

Hard to design it right

Need to orchestrate the services

Hard to debug problems

Unreliable network calls

Autonomous cross-functional teams

Distributed Monolith

Source: https://www.feval.ca/posts/microservices/

Modular Monolith

Source: https://medium.com/design-and-tech-co/modular-monoliths-a-gateway-to-microservices-946f2cbdf382

  • Use of packages
  • Public APIs only at the service layer
  • Java 9 has modules to support this architecture
  • Could we package horizontally (a layered architecture)?

 

Component vs Microservice

Source: https://medium.com/design-and-tech-co/modular-monoliths-a-gateway-to-microservices-946f2cbdf382

Devopedia Roadmap

  • It's not trivial to identify the right boundaries
  • PHP: Lumen is a micro-framework by Laravel: APIs can be delivered as packages
  • CLI scripts will be deprecated once the functionality is available as APIs
  • Migrate to microservices only if necessary

Further Reading

Why We're Not Using Microservices: A Devopedia Case Study

By Arvind Padmanabhan

Why We're Not Using Microservices: A Devopedia Case Study

  • 800