Conventions used
There are a number of text conventions used throughout this book.
Code in text
: Indicates code words in text, database table names, folder names, filenames, file extensions, pathnames, dummy URLs, user input, and Twitter handles. Here is an example: "The code then calls the global set_meter_provider
method to set the meter provider for the entire application."
A block of code is set as follows:
from opentelemetry._metrics import set_meter_provider from opentelemetry.sdk._metrics import MeterProvider from opentelemetry.sdk.resources import Resource def configure_meter_provider(): provider = MeterProvider(resource=Resource.create()) set_meter_provider(provider) if __name__ == "__main__": configure_meter_provider()
When we wish to draw your attention to a particular part of a code block, the relevant lines or items are set in bold:
from opentelemetry._metrics import get_meter_provider, set_meter_provider ... if __name__ == "__main__": configure_meter_provider() meter = get_meter_provider().get_meter( name="metric-example", version="0.1.2", schema_url=" https://opentelemetry.io/schemas/1.9.0", )
Any command-line input or output is written as follows:
$ git clone https://github.com/PacktPublishing/Cloud-Native-Observability $ cd Cloud-Native-Observability/chapter7
Bold: Indicates a new term, an important word, or words that you see onscreen. For instance, words in menus or dialog boxes appear in bold. Here is an example: "Search for traces by clicking the Run Query button."
Tips or Important Notes
Appear like this.