Chapter 7. Data-Driven Efficiency Assessment
You learned how to observe our Go program using different observability signals in the previous chapter. We discussed how to transform those signals to numeric values, or metrics, to effectively observe and assess the latency and resource consumption of the program.
Unfortunately, knowing how to measure the current or maximum consumption or latency for running a program does not guarantee the correct assessment of the overall program efficiency for our application. What we are missing here is the experiment part, which might be the most challenging part of optimization generally: how to trigger situations that are worth measuring with the observability tools mentioned in Chapter 6!
The Definition of Measuring
I find the verb “to measure” very imprecise. I have seen this word overused to describe two things: the process of performing an experiment and gathering numeric data from it.
In this book, every time you read about the “measuring” process, I follow the definition used in metrology (the science of measurement). I precisely mean the process of using the instruments to quantify what is happening now (e.g., the latency of the event, or how much memory it required) or what happened in a given time window. Everything that leads to this event that we measure (simulated by us in a benchmark or occurring naturally) is a separate topic, discussed in this chapter.
In this chapter, I will introduce you to the art of experimentation and measurement ...
Get Efficient Go now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.