Skip to content

Commit cb42926

Browse files
svrnmtheletterfcartermp
authored
Update instrumentation concept page (open-telemetry#3996)
Signed-off-by: svrnm <neumanns@cisco.com> Co-authored-by: Fabrizio Ferri-Benedetti <fferribenedetti@splunk.com> Co-authored-by: Phillip Carter <pcarter@fastmail.com>
1 parent 7ce709e commit cb42926

File tree

9 files changed

+107
-72
lines changed

9 files changed

+107
-72
lines changed

content/en/blog/2023/end-user-discussions-03.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ agent to the host metrics receiver for infrastructure monitoring.
186186

187187
**A:** It depends on the use cases:
188188

189-
- [Auto instrumentation](/docs/concepts/instrumentation/automatic/) options are
189+
- [Auto instrumentation](/docs/concepts/instrumentation/zero-code/) options are
190190
maturing in OTel; for example, the Java JAR agent takes care of instrumenting
191191
[most libraries](https://github.com/open-telemetry/opentelemetry-java-instrumentation/blob/main/docs/supported-libraries.md#libraries--frameworks)
192192
that are used by applications. Auto-instrumentation is also available for

content/en/blog/2023/logs-collection/index.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -425,7 +425,7 @@ extend Yoda's code to do the following:
425425
1. Once you have traces and logs ingested in a backend, try to correlate these
426426
two telemetry signal types in the backend along with a frontend such as
427427
Grafana.
428-
1. Use [Automatic Instrumentation](/docs/concepts/instrumentation/automatic/) to
428+
1. Use [Automatic Instrumentation](/docs/concepts/instrumentation/zero-code/) to
429429
further enrich telemetry.
430430

431431
The community is currently working on the [Events API

content/en/docs/concepts/components.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ OpenTelemetry is currently made up of several main components:
1212
- [Language-specific API \& SDK implementations](#language-specific-api--sdk-implementations)
1313
- [Instrumentation Libraries](#instrumentation-libraries)
1414
- [Exporters](#exporters)
15-
- [Automatic Instrumentation](#automatic-instrumentation)
15+
- [Zero-Code Instrumentation](#zero-code-instrumentation)
1616
- [Resource Detectors](#resource-detectors)
1717
- [Cross Service Propagators](#cross-service-propagators)
1818
- [Sampler](#sampler)
@@ -75,7 +75,7 @@ For more information, see
7575

7676
{{% docs/languages/exporters/intro %}}
7777

78-
### Automatic Instrumentation
78+
### Zero-Code Instrumentation
7979

8080
If applicable a language specific implementation of OpenTelemetry will provide a
8181
way to instrument your application without touching your source code. While the
@@ -84,7 +84,7 @@ OpenTelemetry API and SDK capabilities to your application. Additionally they
8484
may add a set of Instrumentation Libraries and exporter dependencies.
8585

8686
For more information, see
87-
[Instrumenting](/docs/concepts/instrumentation/automatic/).
87+
[Zero-Code Instrumentation](/docs/concepts/instrumentation/zero-code/).
8888

8989
### Resource Detectors
9090

Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
---
22
title: Instrumentation
33
description: >-
4-
How OpenTelemetry facilitates automatic and manual instrumentation of
5-
applications.
4+
How OpenTelemetry instrumentations libraries and applications.
65
aliases: [instrumenting]
76
weight: 15
87
---
@@ -12,32 +11,48 @@ from the system's components must emit [traces](/docs/concepts/signals/traces/),
1211
[metrics](/docs/concepts/signals/metrics/), and
1312
[logs](/docs/concepts/signals/logs/).
1413

15-
Without being required to modify the source code you can collect telemetry from
16-
an application using [automatic instrumentation](automatic/). If you previously
17-
used an APM agent to extract telemetry from your application, Automatic
18-
Instrumentation will give you a similar out of the box experience.
19-
20-
To facilitate the instrumentation of applications even more, you can
21-
[manually instrument](manual/) your applications by coding against the
22-
OpenTelemetry APIs.
23-
24-
For that you don't need to instrument all the dependencies used in your
25-
application:
26-
27-
- some of your libraries will be observable out of the box by calling the
28-
OpenTelemetry API themselves directly. Those libraries are sometimes called
29-
**natively instrumented**.
30-
- for libraries without such an integration the OpenTelemetry projects provide
31-
language specific [Instrumentation Libraries][]
32-
33-
Note, that for most languages it is possible to use both manual and automatic
34-
instrumentation at the same time: Automatic Instrumentation will allow you to
35-
gain insights into your application quickly and manual instrumentation will
36-
enable you to embed granular observability into your code.
37-
38-
The exact installation mechanism for [manual](manual/) and
39-
[automatic](automatic/) instrumentation varies based on the language you’re
40-
developing in, but there are some similarities covered in the sections below.
41-
42-
[instrumentation libraries]:
43-
/docs/specs/otel/overview/#instrumentation-libraries
14+
OpenTelemetry has two primary ways to instrument.
15+
16+
1. [Code-based solutions](/docs/concepts/instrumentation/code-based) via
17+
official APIs and SDKs for eleven languages.
18+
2. [Zero-code solutions](/docs/concepts/instrumentation/zero-code/) that, when
19+
installed, instrument libraries you use.
20+
21+
Code-based solutions allow you to get rich telemetry from your application
22+
itself. They let you use the OpenTelemetry API to generate telemetry from your
23+
application, which acts as an essential complement to the telemetry generated by
24+
zero-code solutions.
25+
26+
The Zero-code solutions are great for getting started, or when you can't modify
27+
the application you need to get telemetry out of. They provide rich telemetry
28+
from libraries you use and/or the environment your application runs in. Another
29+
way to think of it is that they provide information about what's happening _at
30+
the edges_ of your application.
31+
32+
It's generally recommended that you use both solutions when you can.
33+
34+
## Additional OpenTelemetry Benefits
35+
36+
OpenTelemetry provides more than just zero-code and code-based telemetry
37+
solutions. The following things are also a part of OpenTelemetry:
38+
39+
- Libraries can leverage the OpenTelemetry API as a dependency, which will have
40+
no impact on applications using that library, unless the OpenTelemetry SDK is
41+
imported.
42+
- For each [signal](/docs/concepts/signals) (traces, metrics, logs) you have
43+
several methods at your disposals to create, process, and export them.
44+
- With [context propagation](/docs/concepts/context-propagation) built into the
45+
implementations, you can correlate signals regardless of where they are
46+
generated.
47+
- [Resources](/docs/concepts/resources) and
48+
[Instrumentation Scopes](/docs/concepts/instrumentation-scope) allow grouping
49+
of signals, by different entities, like, the
50+
[host](/docs/specs/semconv/resource/host/),
51+
[operating system](/docs/specs/semconv/resource/os/) or
52+
[K8s cluster](/docs/specs/semconv/resource/k8s/#cluster)
53+
- Each language-specific implementation of the API and SDK follows the
54+
requirements and expectations of the
55+
[OpenTelemetry specification](/docs/specs/otel/).
56+
- [Semantic Conventions](/docs/concepts/semantic-conventions) provide a common
57+
naming schema that can be used for standardization across code bases and
58+
platforms.

content/en/docs/concepts/instrumentation/automatic.md

-31
This file was deleted.

content/en/docs/concepts/instrumentation/manual.md content/en/docs/concepts/instrumentation/code-based.md

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
---
2-
title: Manual
2+
title: Code-based
33
description: >-
4-
Learn about the essential steps to manually instrument your application.
4+
Learn about the essential steps to instrument your code base.
55
weight: 20
6+
aliases: [manual]
67
cSpell:ignore: legitimatebusiness proxying
78
---
89

Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
---
2+
title: Zero-code
3+
description: >-
4+
Learn how to add observability to an application without the need to write
5+
more code
6+
weight: 10
7+
aliases: [automatic]
8+
---
9+
10+
As [ops](/docs/getting-started/ops/) you might want to add observability to one
11+
or more applications without having to edit the source. OpenTelemetry lets you
12+
quickly gain some observability for a service without having to use the
13+
OpenTelemetry API & SDK for
14+
[code-based instrumentation](/docs/concepts/instrumentation/code-based).
15+
16+
Zero-code instrumentation adds the OpenTelemetry API and SDK capabilities to
17+
your application typically as an agent or agent-like installation. The specific
18+
mechanisms involved may differ by language, ranging from bytecode manipulation,
19+
monkey patching, or eBPF to inject calls to the OpenTelemetry API and SDK into
20+
your application.
21+
22+
Typically, zero-code instrumentation adds instrumentation for the libraries
23+
you're using. This means that requests and responses, database calls, message
24+
queue calls, and so forth are what are instrumented. Your application's code,
25+
however, is not typically instrumented. To instrument your code, you'll need to
26+
use [code-based instrumentation](/docs/concepts/instrumentation/code-based).
27+
28+
Additionally, zero-code instrumentation lets you configure the
29+
[Instrumentation Libraries](/docs/concepts/instrumentation/libraries) and
30+
[exporters](/docs/concepts/components/#exporters) loaded.
31+
32+
You can configure zero-code instrumentation through environment variables and
33+
other language-specific mechanisms, such as system properties or arguments
34+
passed to initialization methods. To get started, you only need a service name
35+
configured so that you can identify the service in the observability backend of
36+
your choice.
37+
38+
Other configuration options are available, including:
39+
40+
- Data source specific configuration
41+
- Exporter configuration
42+
- Propagator configuration
43+
- Resource configuration
44+
45+
Automatic instrumentation is available for the following languages:
46+
47+
- [.NET](/docs/languages/net/automatic/)
48+
- [Java](/docs/languages/java/automatic/)
49+
- [JavaScript](/docs/languages/js/automatic/)
50+
- [PHP](/docs/languages/php/automatic/)
51+
- [Python](/docs/languages/python/automatic/)

content/en/docs/getting-started/dev.md

+1-2
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,7 @@ instrumented automatically and instrumenting your own code with our API
1414
manually, we recommend that you learn the following concepts first:
1515

1616
- [What is OpenTelemetry?](/docs/what-is-opentelemetry/)
17-
- [How can I instrument dependencies without touching their code?](/docs/concepts/instrumentation/automatic/)
18-
- [How can I instrument my application manually?](/docs/concepts/instrumentation/manual/)
17+
- [How can I add instrumentation to my code base?](/docs/concepts/instrumentation/code-based/)
1918

2019
If you develop libraries, frameworks or middleware that is used as a dependency
2120
within other software, we recommend that you learn how you can provide telemetry

content/en/docs/getting-started/ops.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ applications without touching their code, we recommend that you learn the
1515
following:
1616

1717
- [What is OpenTelemetry?](/docs/what-is-opentelemetry/)
18-
- [How can I instrument applications without touching their code?](/docs/concepts/instrumentation/automatic/)
18+
- [How can I instrument applications without touching their code?](/docs/concepts/instrumentation/zero-code/)
1919
- [How can I set up a collector?](/docs/collector/)
2020
- [How can I get automation for Kubernetes with the OpenTelemetry Operator?](/docs/kubernetes/operator/)
2121

0 commit comments

Comments
 (0)