Services are Polylith's deployable artefacts. They are the result of combining one base with multiple components and libraries.

Services are the end goal of the Polylith architecture. They are the artefact(s) that we'll deploy in our local, test, staging and production environments.

Polylith's building block approach makes constructing services both simple and fun. Once we've designed our base's API, then we just need to compose the right set of components and libraries which implement the functionality we've exposed.

Let's take a look at two complete services:

A service with one base, two components and three libraries
A service with one base, five components and six libraries

Services won't compile with exposed dependency studs, so valid services always have a flat “roof” of libraries.

But what if your solution requires the horizontal scalability of several services? Then you'll need a system.