Menu

LVD Inside a Single Microservice
📰

LVD Inside a Single Microservice

DEV Community: microservices·Anup Hariharan Nair·4 days ago
#d7zkyhzj
#devtomicroservices#devto#dev#service#layers
Long article (652 words) — no AI summary yet.
Reading 0:00
15s threshold

"It's only a small service, it doesn't need layers." You hear it at the start of nearly every microservice project, and it is half right. A small service does not need nine layers. But it still contains code that changes at very different speeds, and treating it as one undifferentiated lump is how small services turn into hard-to-change large ones.

The forces don't care about deployment size

Take a loyalty-points service. It has data definitions that almost never change, a few calculation helpers that change occasionally, an integration with a payments partner that changes whenever the partner revises its API, and earning rules that marketing edits every month. That is the whole volatility spectrum, packed into a few thousand lines.

The book's position is that microservices are no exception to the forces LVD responds to. Inside each service, import edges should respect the dependency rule, and the volatility ordering of the layers should hold in practice.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.