liveBook · Manning

Service discovery

As explained in Kubernetes in Action, Second Edition

Service discovery is a mechanism by which applications locate other applications or services and obtain the information needed to use them.

Service discovery lets applications locate other applications or services and obtain the information needed to use them. Kubernetes provides this infrastructure capability so developers can focus on business logic instead of implementing discovery themselves. section 1.2.1

In a distributed application, Kubernetes can discover services or peers while keeping the application Kubernetes-agnostic. Applications may query the Kubernetes API when they need more detailed information about their environment. section 1.2.2

Service discovery belongs to a broader set of platform-provided capabilities, alongside horizontal scaling, load-balancing, self-healing, leader election, and centralized application configuration. section 1.2.1 section 1.2.2

Figure 1.8 Kubernetes is to a computer cluster what an operating system is to a computer.
figure

The operating-system analogy places service discovery among the basic cluster capabilities Kubernetes supplies to applications. section 1.2.1

How Kubernetes in Action, Second Edition covers it

How deep it goes
Defines the mechanism and its application role, but stops short of implementation steps, configuration, and lookup internals.
Examples
Uses service and peer discovery within a distributed application as its concrete application context.
What it assumes
Assumes distributed-application context while defining service discovery without requiring prior implementation knowledge.
What you can do after
Apply it via Kubernetes by relying on platform-provided discovery instead of implementing infrastructure mechanisms inside applications.
How it connects
Connects service discovery with distributed applications, Kubernetes, the Kubernetes API, and centralized application configuration.

Also explained in

Compare how 7 books explain service discovery →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Kubernetes in Action, Second Edition. The section links point to the parts of the book it draws on.