liveBook · Manning

Performance

As explained in The Art of Code

A monitoring metric is a measured numeric signal describing the state, activity, or performance of a running system.

Performance concerns speed and responsiveness: whether a system delivers results quickly enough for its users. It is not a property of code style. Readable, maintainable code can still execute slowly, while difficult code can appear fast when powerful hardware compensates for it. section 8.3

Treat performance as a constraint rather than an isolated goal. Sustainability asks for an acceptable level of responsiveness using the smallest practical infrastructure; that overlap is efficiency. Faster behavior alone does not establish lower environmental impact, and clean code alone does not establish fast execution. section 8.3 section 8.6

Use performance thinking to make deliberate tradeoffs:

  • Define what responsiveness is acceptable before adding hardware or optimizing code. section 8.3
  • Seek acceptable performance with minimal hardware resources, rather than equating performance with maximum speed. section 8.3 section 8.6
  • Investigate CPU work, memory use, communication, storage, and workload timing when resource use or operational cost is a concern. section 8.6

Tracing an intermittent database slowdown

When an input-data problem cannot be reproduced, reconstruct its timeline from logs, metrics, and traces. A JDBC-connection failure that recurs at the same times as database-host CPU saturation points to intermittent server overload, turning scattered evidence into a performance hypothesis. section 10.3.2

Figure 8.1 How sustainable coding fits with clean code and performance
figure

The diagram positions efficiency between sustainability and performance, alongside the separate concern of clean code. section 8.3

How The Art of Code covers it

How deep it goes
Defines performance through speed and responsiveness, then contrasts it with clean code, sustainability, and efficiency without optimization internals.
Examples
Uses intermittent JDBC connection failures and saturated database-host CPU metrics to infer server overload.
What you can do after
Evaluate/understand performance tradeoffs by separating responsiveness from code readability and environmental impact.
How it connects
Connects performance with clean code, sustainability, efficiency, hardware resources, logs, and monitoring metrics.

Also explained in

Compare how 40 books explain performance →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of The Art of Code. The section links point to the parts of the book it draws on.