SlideShare uma empresa Scribd logo
1 de 58
Baixar para ler offline
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
CNCF Meetup – 12 May 2022 – v4
Dimitris Finas, Sr Advisory Solution Consultant
An introduction to OpenTelemetry
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Agenda
● What is OpenTelemetry?
○ A Brief History
● Distributed Tracing Overview
● OpenTelemetry
○ Instrumentation
○ Collectors
● Q&A
● Put it in action
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
What is OpenTelemetry?
3
OpenTelemetry is a set of APIs, SDKs, tooling and integrations that
are designed for the creation and management of telemetry data, such
as traces, metrics, and logs.
OpenTelemetry's Mission is to enable effective observability by making
high-quality, portable telemetry ubiquitous and vendor-agnostic.
A trace represents a single user’s
journey across multiple
applications and systems (usually
microservices).
Numeric data measured at
various time intervals (time series
data); SLI’s (request rate, error
rate, duration, CPU%, etc.)
Timestamped records of discrete
events that happened within an
application or system, such as a
failure, an error, or a state
transformation
You want more? See Otel vision in https://github.com/open-telemetry/community/blob/main/mission-vision-values.md#otel-mission-vision-and-values
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
OpenTelemetry - A brief history
2015
Lightstep is founded by
Ben Sigelman, Daniel
Spoonhower, and Ben
Cronin
2016
Lightstep helps to found
OpenTracing, the first
common, portable API
for distributed tracing
2017
Jaeger, an open-source
tracing tool developed by
Yuri Shkuro, is open-
sourced by Uber
2018
Google releases a new
portable instrumentation
project called
OpenCensus
2019
The OpenTracing and
OpenCensus projects
announce a merger,
forming OpenTelemetry
to be a part of CNCF
2020
OpenTelemetry is
released in beta
4
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
6
Lightstep Founded
Standards
Languages
Tracers
Service Meshes / Proxies
Containers, Platforms
and Clouds
Deployment Automation (CI/CD) Alerting and Tools
Data Streaming and Storage
Integrations
See up to date list in https://opentelemetry.io/registry/
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
What are
distributed traces?
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Introduction to distributed traces
A distributed trace provides a view
of the life of a request as it travels
across multiple hosts and services
communicating over various
protocols
8
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Introduction to distributed traces
Trace
A “trace” is a view into the request
lifecycle as a whole as it moves
through a distributed system.
9
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Introduction to distributed traces
10
Trace
Span
Span
A trace is a collection of spans.
Each component of the distributed
system contributes a “span” - a
named, timed operation representing
a piece of the workflow.
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Introduction to distributed traces
Trace
Span
Span
Time
client transaction from start to end
load balancer transaction from start to end
auth billing resource allocation and provisioning
container start-up
storage allocation
start-up scripts
11
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Introduction to distributed traces
Time
A trace can be visualized as
a tree of spans with a
“root” span at the top.
client transaction from start to end
load balancer transaction from start to end
auth billing resource allocation and provisioning
container start-up
storage allocation
start-up scripts
12
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Introduction to distributed traces
Time
Spans have parent-child
relationships.
Parent spans can have
multiple children.
client transaction from start to end
load balancer transaction from start to end
auth billing resource allocation and provisioning
container start-up
storage allocation
start-up scripts
13
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Introduction to distributed traces
Time
Child spans don’t necessarily
finish before their parents
This can be seen with asynchronous
children
Real world example: An rpc call timeout
out - the parent span finished earlier
than the hanging child
client transaction from start to end
load balancer transaction from start to end
auth billing resource allocation and provisioning
container start-up
storage allocation
start-up scripts
14
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Visualizing a trace
15
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Visualizing a trace
Each span also has span context
Span context is composed of attributes
(tags) and events (logs). These are added
during instrumentation.
Attributes allow you to search and
segment your data within LightStep
Events (logs) add information that is
useful during root cause and debugging
16
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
OpenTelemetry Instrumentation
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
OpenTelemetry support of dev languages
You want to know more?
See https://opentelemetry.io/docs/instrumentation/
LANGUAGE TRACE STATUS*
INSTRUMENTATION
MANUAL/AUTO**
C++ stable manual
C# / .NET stable manual & auto
Erlang / Elixir stable manual
Go stable manual
Java stable manual & auto
Javascript / Node stable manual & auto
Javascript / Browser stable manual & auto
LANGUAGE TRACE STATUS*
INSTRUMENTATION
MANUAL/AUTO**
PHP pre-alpha manual
Python stable manual & auto
Ruby stable manual & auto
Rust beta manual
Swift beta manual
(*) Trace implementation status as of end of April 2022
(**) Automatic instrumentation means quick wins as no need to update
existing code to collect some data
Supported languages versions:
• .NET & .NET Framework all supported versions except .NET Fwk
v3.5 as https://github.com/open-telemetry/opentelemetry-dotnet
• Java > v1.8
• NodeJS >v10 as https://github.com/open-telemetry/opentelemetry-js
• Python, only latest versions as of https://github.com/open-
telemetry/opentelemetry-python
18
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
● Configure Tracer
● Create Spans
○ Decorate Spans
● Context Propagation
OTel Instrumentation Steps
20
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Configure Tracer
const opentelemetry = require('@opentelemetry/api');
const { NodeTracerProvider } = require('@opentelemetry/node');
const { SimpleSpanProcessor } = require('@opentelemetry/tracing');
const { CollectorTraceExporter } = require('@opentelemetry/exporter-collector');
const collectorOptions = {
serviceName: '<Service Name>', // Provide a service name
url: 'https://<Satellite Host>:<Satellite Port>/api/v2/otel/trace', // URL and port to Lightstep Satellite
headers: {
'Lightstep-Access-Token': 'YOUR_TOKEN' //Lightstep Access Token
},
};
// Create an exporter for sending span data
const exporter = new CollectorTraceExporter(collectorOptions);
// Create a provider for activating and tracking spans
const tracerProvider = new NodeTracerProvider({
plugins: {
http: {
enabled: true,
// You may use a package name or absolute path to the file.
path: '@opentelemetry/plugin-http',
// Enable HTTP Plugin to automatically inject/extract context into HTTP headers
}
}
});
// Configure a span processor for the tracer
tracerProvider.addSpanProcessor(new SimpleSpanProcessor(exporter));
// Register the tracer
tracerProvider.register();
Declare Dependencies
Declare Destination
Options
Declare Plugins
21
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
23
Send Telemetry To OpenTelemetry Collector
...
const collectorOptions = {
serviceName: '<Service Name>', // Provide a service name
url: 'https://<Collector Host>:<Collector Port>', // URL and port to OTel Collector
};
const exporter = new CollectorTraceExporter(collectorOptions);
...
Only difference between sending traffic to
an OTel Collector and a Lightstep
Satellite is the address and Access
Token
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Create Spans
const tracer = opentelemetry.trace.getTracer();
const span = tracer.startSpan('foo');
span.setAttribute('platform', 'osx');
span.setAttribute('version', '1.2.3');
span.addEvent('event in foo');
const childSpan = tracer.startSpan('bar', {
parent: span,
});
childSpan.end();
span.end();
Start Span
Decorate Span
Create Child Span
End Span
24
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
● tracer.startSpan(name, {parent: <span>, …})
○ This method returns a child of the specified span.
● api.context.with(api.setSpan(api.context.active(), name))
○ Starts a new span, sets it to be active. Optionally, can get a reference to the span.
● api.trace.getSpan(api.context.active())
○ Used to access & add information to the current span
● span.addEvent(msg)
○ Adds structured annotations (e.g. "logs") about what is currently happening.
● span.setAttributes(core.Key(key).String(value)...)
○ Adds a structured, typed attribute to the current span. This may include a user id, a build id, a user-agent, etc.
● span.end()
○ Often used with defer, fires when the unit of work is complete and the span can be sent
Tracer Span Methods
25
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Context Propagation
● Distributed context is an abstract data type that represents collection of
entries.
● Each key is associated with exactly one value.
● It is serialized for propagation across process boundaries
● Passing around the context enables related spans to be associated with a
single trace.
● W3C TraceContext is the de-facto standard.
● Context propagation can be automatically handled by using HTTP plugin
● Manual propagation code can be found here: https://open-
telemetry.github.io/opentelemetry-js/classes/propagationapi.html
26
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
27
Putting It All Together
const opentelemetry = require('@opentelemetry/api');
const { NodeTracerProvider } = require('@opentelemetry/node');
const { SimpleSpanProcessor } = require('@opentelemetry/tracing');
const { CollectorTraceExporter } = require('@opentelemetry/exporter-collector');
const collectorOptions = {
serviceName: '<Service Name>', // Provide a service name
url: 'https://<Satellite Host>:<Satellite Port>/api/v2/otel/trace', // URL and port to
Lightstep Satellite
headers: {
'Lightstep-Access-Token': 'YOUR_TOKEN' //Lightstep Access Token
},
};
// Create an exporter for sending span data
const exporter = new CollectorTraceExporter(collectorOptions);
// Create a provider for activating and tracking spans
const tracerProvider = new NodeTracerProvider({
plugins: {
http: {
enabled: true,
// You may use a package name or absolute path to the file.
path: '@opentelemetry/plugin-http',
// Enable HTTP Plugin to automatically inject/extract context into HTTP headers
}
}
});
Continued…..
// Configure a span processor for the tracer
tracerProvider.addSpanProcessor(new
SimpleSpanProcessor(exporter));
// Register the tracer
tracerProvider.register();
const tracer = opentelemetry.trace.getTracer();
const span = tracer.startSpan('foo');
span.setAttribute('platform', 'osx');
span.setAttribute('version', '1.2.3');
span.addEvent('event in foo');
const childSpan = tracer.startSpan('bar', {
parent: span,
});
childSpan.end();
span.end();
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
SDKs, Exporters, and Collector Services
● OpenTelemetry's SDK implements trace & span creation.
● An exporter can be instantiated to send the data collected by OpenTelemetry
to the backend of your choice.
○ E.g. Jaeger, Lightstep, etc.
● OpenTelemetry collector proxies data between instrumented code and
backend service(s). The exporters can be reconfigured without changing
instrumented code.
28
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Appendix
● NodeJS OpenTelemetry API Docs: https://open-
telemetry.github.io/opentelemetry-js/
● Context Propagation API Docs: https://open-
telemetry.github.io/opentelemetry-js/classes/propagationapi.html
● Plugins:
○ Core: https://github.com/open-telemetry/opentelemetry-js/tree/master/packages
○ Contrib: https://github.com/open-telemetry/opentelemetry-js-contrib/tree/master/plugins/node
29
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Appendix (Cont’d): Basic Data Formats
JSON formatted info, output when span.end() was called.
"SpanContext": {
"TraceID": "9850b11fa09d4b5fa4dd48dd37f3683b",
"SpanID": "1113d149cfffa942",
"TraceFlags": 1
},
"ParentSpanID": "e1e1624830d2378e",
"SpanKind": "internal",
"Name": "dbHandler/database",
"StartTime": "2019-11-03T10:52:56.903919262Z",
"EndTime": "2019-11-03T10:52:56.903923338Z",
"Attributes": [],
"MessageEvents": null,
"Links": null,
"Status": 0,
"HasRemoteParent": false,
"DroppedAttributeCount": 0,
"DroppedMessageEventCount": 0,
"DroppedLinkCount": 0,
"ChildSpanCount": 0
30
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Appendix (Cont’d): Attributes & MessageEvents
"Attributes": [
{
"Key": "http.host",
"Value": {
"Type": "STRING",
"Value": "opentelemetry-instructor.glitch.me"
}
},
{
"Key": "http.status_code",
"Value": {
"Type": "INT64",
"Value": 200
}
}
],
"MessageEvents": [
{
"Message": "annotation within span",
"Attributes": null,
"Time": "2019-11-03T10:52:56.903914029Z"
}
],
31
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
OpenTelemetry Collectors
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
The OTel Collector is an independent binary
process, written in Go, that acts as a ‘universal
agent’ for the OpenTelemetry ecosystem.
At a high level, the goals of the collector are…
- Collect, process, and export telemetry data
in a highly performant and stable manner.
- Support multiple types of telemetry.
- Highly extensible and customizable, but with
an easy OOB experience.
The collector provides separation of concerns
between Developers and Operations/SRE teams.
What is the OpenTelemetry Collector?
33
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
The collector has 4 major components -
- Receivers
- Processors
- Exporters
- Extensions
Collectors receive, process, and forward
telemetry to export destinations.
These can be part of one, or more, pipelines.
Architecture of the Collector
34
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Telemetry data flows through the collector,
from receiver to exporter. Multiple pipelines
in a single collector are configurable, but
each must operate on a single telemetry
type - either traces, or metrics.
All data received by a pipeline will be
processed by all processors and exported
to all exporters.
Pipelines
35
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
service:
pipelines: # section that can contain multiple subsections, one per pipeline
traces: # type of the pipeline
receivers: [opencensus, jaeger, zipkin]
processors: [tags, tail_sampling, batch, queued_retry]
exporters: [opencensus, jaeger, stackdriver, zipkin]
YAML
36
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Receivers listen on a single port for
telemetry data. A single receiver can send
to multiple pipelines.
Currently, the collector supports the
following receivers -
- OTLP
- OpenCensus
- Fluentd Forward
- Jaeger
- Zipkin
- Prometheus
- Host Metrics
Receivers
37
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Receivers, Cont’d.
The collector also supports third-party/contributed receivers, which include:
● Amazon X-Ray
● Wavefront
● SignalFX
● Carbon
● CollectD
● Redis
● Kubernetes/Kubelet
Many of these are metrics receivers, but some (xray, SAPM) are trace receivers.
38
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Receivers:
otlp:
grpc:
endpoint: "0.0.0.0:55678"
service:
pipelines:
traces: # a pipeline of “traces” type
receivers: [otlp]
processors: [tags, tail_sampling, batch, queued_retry]
exporters: [otlp]
YAML
39
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Typically, an exporter will forward all data it
receives to a network endpoint, but can
also write to a file or console.
Similar to receivers, a single exporter may
be included in multiple pipelines.
Exporters
40
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
exporters:
jaeger:
protocols:
grpc:
endpoint: "0.0.0.0:14250"
otlp:
endpoint: <YOUR_LOAD_BALANCER_DNS_NAME_OR_IP_ADDRESS>
headers: {"lightstep-access-token":"<YOUR_ACCESS_TOKEN>"}
service:
pipelines:
traces: # a pipeline of “traces” type
receivers: [OTLP]
processors: [tags, tail_sampling, batch, queued_retry]
exporters: [jaeger, otlp]
YAML
41
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Processors are very powerful!
They run sequentially, and receive all data
from the processor before them. A
processor can transform telemetry data,
delete it, etc.
A single processor configuration can apply
to multiple pipelines, but each pipeline gets
a unique instance of the processor.
Processors
42
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
processors:
queued_retry:
size: 50
per-exporter: true
enabled: true
service:
pipelines:
traces: # a pipeline of “traces” type
receivers: [zipkin]
processors: [queued_retry]
exporters: [jaeger]
traces/2: # another pipeline of “traces” type
receivers: [opencensus]
processors: [queued_retry]
exporters: [opencensus]
YAML
43
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Receivers, Exporters, and Extensions
aren’t super interesting on the face of
things - they receive or emit data, or simply
give you some introspection on the
collector instance.
Processors, however, can do a lot. Let’s
talk about them.
Processors Deep Dive
44
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Processors Ordering
45
Remember this?
Processors one run after the other, so the
order that you define them matters.
This means that limiting and sampling
should be first, and batching/transforms
should be later.
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
The memory limiter is used to prevent a
collector from going OOM.
It does this by allowing the user to
configure and tune GC on the collector.
This is not a replacement for sizing/tuning
collector memory/cpu.
Memory Limiter
processors:
memory_limiter:
ballast_size_mib: 2000
check_interval: 5s
limit_mib: 4000
spike_limit_mib: 500
46
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Out of the box, the collector supports a
probabilistic sampler and a tail-based
sampler.
Probabilistic supports OpenTracing priority
sampling hints as well as trace ID based
hashing.
Tail sampling allows for user-defined
policies such as string/number attributes or
desired rate.
Sampling Processors
47
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
processors:
probabilistic_sampler:
hash_seed: 22
sampling_percentage: 15.3
tail_sampling:
decision_wait: 10s
num_traces: 100
expected_new_traces_per_sec: 10
policies:
[
{
name: test-policy-1,
type: always_sample
},
{
name: test-policy-2,
type: numeric_attribute,
numeric_attribute: {key: key1, min_value: 50, max_value: 100}
},
{
name: test-policy-3,
type: string_attribute,
string_attribute: {key: key2, values: [value1, value2]}
},
{
name: test-policy-4,
type: rate_limiting,
rate_limiting: {spans_per_second: 35}
}
]
48
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Attribute processors can modify the
attributes of a span; insert, update, upsert,
delete, and extract based on attribute
names or regular expressions.
Span processors can modify a span name
or attributes based on a span name.
This can be used for more precise data
scrubbing, creating attributes from span
names, hashing attribute fields, and more.
Note: Resource attributes are modified with
the Resource processor.
Attribute and Span Processors
49
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Functionality can be added to the collector
through Extensions.
Currently, this is used for health checks
and diagnostic information.
Extensions
50
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
# Example of the extensions available with the core Collector. The list below
# includes all configurable options and their respective default value.
extensions:
health_check:
port: 13133
pprof:
endpoint: "localhost:1777"
block_profile_fraction: 0
mutex_profile_fraction: 0
zpages:
endpoint: "localhost:55679"
# The service lists extensions not directly related to data pipelines, but used
# by the service.
service:
# extensions lists the extensions added to the service. They are started
# in the order presented below and stopped in the reverse order.
extensions: [health_check, pprof, zpages]
51
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
receivers:
otlp:
protocols:
grpc:
endpoint: "0.0.0.0:55680"
http:
endpoint: "0.0.0.0:55681"
processors:
batch:
queued_retry:
extensions:
health_check: {}
exporters:
otlp:
endpoint: "ingest.lightstep.com:443"
headers:
"lightstep-access-token": "{{ .Values.lightstepKey }}"
service:
extensions: [health_check, zpages]
pipelines:
traces:
receivers: [otlp]
processors: [batch, queued_retry]
exporters: [otlp]
This can be any receiver, not just OTLP.
Remember, receivers can be part of multiple
pipelines!
Batch and Retry processors are recommended
to reduce connections and decrease size of
outgoing reports.
Other export options include
compression (gzip), etc. If satellites are
in Single Project mode, no headers
needed, just endpoint!
Putting It All Together
52
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
A goal of the collector is ‘5 Minutes to
Value’, and part of this is easy support for a
variety of deployment strategies.
The collector can be run as an ‘agent’ or as
a standalone (or pool of standalone)
processes.
Eventually, the collector will support
distribution packages for popular targets
(rpm, docker, windows…) and automatic
ingest of environment metrics/tags (AWS
env resources, k8s, etc.)
Collector Deployment Strategies
53
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Further Reading: Collectors
Most collector components are well-documented, and you can find individual READMEs
in each sub-directory of the https://github.com/open-telemetry/opentelemetry-collector
repository.
Third-party extensions, processors, receivers, and exporters are available in the
https://github.com/open-telemetry/opentelemetry-collector-contrib repository.
A Kubernetes Operator is available at https://github.com/open-telemetry/opentelemetry-
operator, but tends to lag development significantly and so I don’t currently recommend
it.
56
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Further Reading: OpenTelemetry
● OpenTelemetry documentation https://opentelemetry.io/docs/ and
https://opentelemetry.lightstep.com/
● OpenTelemetry registry to get list of supported technologies and projects:
https://opentelemetry.io/registry/
● How to choose your Observability solution: https://medium.com/dzerolabs/unpacking-
observability-how-to-choose-an-observability-vendor-aa0e6d80b71d
57
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Q&A
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
o Instrument your first application for distributed traces visibility
o Deploy your first Collector
o Connect and see results in different backends
Put it in action
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
● Activity
○ Collect distributed traces from your application
○ Use Otel Collector to receive traces
○ See results in console output
● Lab 1.1
○ Time: 15m
○ Clone the git application repository
○ Add auto-instrumentation to NodeJS application
○ Test and see results in console output
● Lab 1.2
○ Time: 10m
○ Deploy Collector as container
○ Send traces to Collector
○ Test and see results in Collector output and debug
Module Lab and Activities (1/2)
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
● Activity
○ Send traces to different Backends
○ Add custom attributes and log events
○ Test with volume and see results in backends
● Lab 2.1
○ Time: 10m
○ Create your Lightstep account
○ Update Collector to send traces to Jaeger and Lightstep
○ Test and see results in the backends
● Lab 2.2
○ Time: 15m
○ Add custom attributes and log events
○ Start some volume tests
○ See correlated analysis in Lightstep backend
Module Lab and Activities (2/2)
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
© 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
Prerequites: you must have docker desktop installed
Ø git clone https://github.com/dimitrisfinas/nodejs-microservices-
example.git
Ø cd nodejs-microservices-example
Ø docker-compose up --build
Once deployment finished, check application works:
Ø Open Browser on ”http://127.0.0.1:4000/api/data”
Then, follow instructions from file “INSTALLING_OTEL.md”
All URLs to test application are available from “README.md” in “## Starting
the microservices application” section
Step by Step instructions

Mais conteúdo relacionado

Mais procurados

Observability, Distributed Tracing, and Open Source: The Missing Primer
Observability, Distributed Tracing, and Open Source: The Missing PrimerObservability, Distributed Tracing, and Open Source: The Missing Primer
Observability, Distributed Tracing, and Open Source: The Missing PrimerVMware Tanzu
 
THE STATE OF OPENTELEMETRY, DOTAN HOROVITS, Logz.io
THE STATE OF OPENTELEMETRY, DOTAN HOROVITS, Logz.ioTHE STATE OF OPENTELEMETRY, DOTAN HOROVITS, Logz.io
THE STATE OF OPENTELEMETRY, DOTAN HOROVITS, Logz.ioDevOpsDays Tel Aviv
 
Introduction to Open Telemetry as Observability Library
Introduction to Open  Telemetry as Observability LibraryIntroduction to Open  Telemetry as Observability Library
Introduction to Open Telemetry as Observability LibraryTonny Adhi Sabastian
 
Opentelemetry - From frontend to backend
Opentelemetry - From frontend to backendOpentelemetry - From frontend to backend
Opentelemetry - From frontend to backendSebastian Poxhofer
 
OSMC 2023 | What’s new with Grafana Labs’s Open Source Observability stack by...
OSMC 2023 | What’s new with Grafana Labs’s Open Source Observability stack by...OSMC 2023 | What’s new with Grafana Labs’s Open Source Observability stack by...
OSMC 2023 | What’s new with Grafana Labs’s Open Source Observability stack by...NETWAYS
 
KCD-OpenTelemetry.pdf
KCD-OpenTelemetry.pdfKCD-OpenTelemetry.pdf
KCD-OpenTelemetry.pdfRui Liu
 
Exploring the power of OpenTelemetry on Kubernetes
Exploring the power of OpenTelemetry on KubernetesExploring the power of OpenTelemetry on Kubernetes
Exploring the power of OpenTelemetry on KubernetesRed Hat Developers
 
Observability For You and Me with OpenTelemetry
Observability For You and Me with OpenTelemetryObservability For You and Me with OpenTelemetry
Observability For You and Me with OpenTelemetryEric D. Schabell
 
Intro to open source observability with grafana, prometheus, loki, and tempo(...
Intro to open source observability with grafana, prometheus, loki, and tempo(...Intro to open source observability with grafana, prometheus, loki, and tempo(...
Intro to open source observability with grafana, prometheus, loki, and tempo(...LibbySchulze
 
Observability in Java: Getting Started with OpenTelemetry
Observability in Java: Getting Started with OpenTelemetryObservability in Java: Getting Started with OpenTelemetry
Observability in Java: Getting Started with OpenTelemetryDevOps.com
 
Distributed Tracing for Kafka with OpenTelemetry with Daniel Kim | Kafka Summ...
Distributed Tracing for Kafka with OpenTelemetry with Daniel Kim | Kafka Summ...Distributed Tracing for Kafka with OpenTelemetry with Daniel Kim | Kafka Summ...
Distributed Tracing for Kafka with OpenTelemetry with Daniel Kim | Kafka Summ...HostedbyConfluent
 
Understand your system like never before with OpenTelemetry, Grafana, and Pro...
Understand your system like never before with OpenTelemetry, Grafana, and Pro...Understand your system like never before with OpenTelemetry, Grafana, and Pro...
Understand your system like never before with OpenTelemetry, Grafana, and Pro...LibbySchulze
 
Juraci Paixão Kröhling - All you need to know about OpenTelemetry
Juraci Paixão Kröhling - All you need to know about OpenTelemetryJuraci Paixão Kröhling - All you need to know about OpenTelemetry
Juraci Paixão Kröhling - All you need to know about OpenTelemetryJuliano Costa
 
Monitoring Kubernetes with Prometheus
Monitoring Kubernetes with PrometheusMonitoring Kubernetes with Prometheus
Monitoring Kubernetes with PrometheusGrafana Labs
 
Everything You wanted to Know About Distributed Tracing
Everything You wanted to Know About Distributed TracingEverything You wanted to Know About Distributed Tracing
Everything You wanted to Know About Distributed TracingAmuhinda Hungai
 
Observability - Stockholm Splunk UG Jan 19 2023.pptx
Observability - Stockholm Splunk UG Jan 19 2023.pptxObservability - Stockholm Splunk UG Jan 19 2023.pptx
Observability - Stockholm Splunk UG Jan 19 2023.pptxMagnus Johansson
 
OSMC 2022 | The Power of Metrics, Logs & Traces with Open Source by Emil-Andr...
OSMC 2022 | The Power of Metrics, Logs & Traces with Open Source by Emil-Andr...OSMC 2022 | The Power of Metrics, Logs & Traces with Open Source by Emil-Andr...
OSMC 2022 | The Power of Metrics, Logs & Traces with Open Source by Emil-Andr...NETWAYS
 
Tracing 2000+ polyglot microservices at Uber with Jaeger and OpenTracing
Tracing 2000+ polyglot microservices at Uber with Jaeger and OpenTracingTracing 2000+ polyglot microservices at Uber with Jaeger and OpenTracing
Tracing 2000+ polyglot microservices at Uber with Jaeger and OpenTracingYuri Shkuro
 
stackconf 2023 | Practical introduction to OpenTelemetry tracing by Nicolas F...
stackconf 2023 | Practical introduction to OpenTelemetry tracing by Nicolas F...stackconf 2023 | Practical introduction to OpenTelemetry tracing by Nicolas F...
stackconf 2023 | Practical introduction to OpenTelemetry tracing by Nicolas F...NETWAYS
 

Mais procurados (20)

Observability, Distributed Tracing, and Open Source: The Missing Primer
Observability, Distributed Tracing, and Open Source: The Missing PrimerObservability, Distributed Tracing, and Open Source: The Missing Primer
Observability, Distributed Tracing, and Open Source: The Missing Primer
 
THE STATE OF OPENTELEMETRY, DOTAN HOROVITS, Logz.io
THE STATE OF OPENTELEMETRY, DOTAN HOROVITS, Logz.ioTHE STATE OF OPENTELEMETRY, DOTAN HOROVITS, Logz.io
THE STATE OF OPENTELEMETRY, DOTAN HOROVITS, Logz.io
 
Introduction to Open Telemetry as Observability Library
Introduction to Open  Telemetry as Observability LibraryIntroduction to Open  Telemetry as Observability Library
Introduction to Open Telemetry as Observability Library
 
Opentelemetry - From frontend to backend
Opentelemetry - From frontend to backendOpentelemetry - From frontend to backend
Opentelemetry - From frontend to backend
 
OSMC 2023 | What’s new with Grafana Labs’s Open Source Observability stack by...
OSMC 2023 | What’s new with Grafana Labs’s Open Source Observability stack by...OSMC 2023 | What’s new with Grafana Labs’s Open Source Observability stack by...
OSMC 2023 | What’s new with Grafana Labs’s Open Source Observability stack by...
 
KCD-OpenTelemetry.pdf
KCD-OpenTelemetry.pdfKCD-OpenTelemetry.pdf
KCD-OpenTelemetry.pdf
 
Exploring the power of OpenTelemetry on Kubernetes
Exploring the power of OpenTelemetry on KubernetesExploring the power of OpenTelemetry on Kubernetes
Exploring the power of OpenTelemetry on Kubernetes
 
Observability For You and Me with OpenTelemetry
Observability For You and Me with OpenTelemetryObservability For You and Me with OpenTelemetry
Observability For You and Me with OpenTelemetry
 
Intro to open source observability with grafana, prometheus, loki, and tempo(...
Intro to open source observability with grafana, prometheus, loki, and tempo(...Intro to open source observability with grafana, prometheus, loki, and tempo(...
Intro to open source observability with grafana, prometheus, loki, and tempo(...
 
Observability in Java: Getting Started with OpenTelemetry
Observability in Java: Getting Started with OpenTelemetryObservability in Java: Getting Started with OpenTelemetry
Observability in Java: Getting Started with OpenTelemetry
 
Distributed Tracing for Kafka with OpenTelemetry with Daniel Kim | Kafka Summ...
Distributed Tracing for Kafka with OpenTelemetry with Daniel Kim | Kafka Summ...Distributed Tracing for Kafka with OpenTelemetry with Daniel Kim | Kafka Summ...
Distributed Tracing for Kafka with OpenTelemetry with Daniel Kim | Kafka Summ...
 
Understand your system like never before with OpenTelemetry, Grafana, and Pro...
Understand your system like never before with OpenTelemetry, Grafana, and Pro...Understand your system like never before with OpenTelemetry, Grafana, and Pro...
Understand your system like never before with OpenTelemetry, Grafana, and Pro...
 
Juraci Paixão Kröhling - All you need to know about OpenTelemetry
Juraci Paixão Kröhling - All you need to know about OpenTelemetryJuraci Paixão Kröhling - All you need to know about OpenTelemetry
Juraci Paixão Kröhling - All you need to know about OpenTelemetry
 
Prometheus and Grafana
Prometheus and GrafanaPrometheus and Grafana
Prometheus and Grafana
 
Monitoring Kubernetes with Prometheus
Monitoring Kubernetes with PrometheusMonitoring Kubernetes with Prometheus
Monitoring Kubernetes with Prometheus
 
Everything You wanted to Know About Distributed Tracing
Everything You wanted to Know About Distributed TracingEverything You wanted to Know About Distributed Tracing
Everything You wanted to Know About Distributed Tracing
 
Observability - Stockholm Splunk UG Jan 19 2023.pptx
Observability - Stockholm Splunk UG Jan 19 2023.pptxObservability - Stockholm Splunk UG Jan 19 2023.pptx
Observability - Stockholm Splunk UG Jan 19 2023.pptx
 
OSMC 2022 | The Power of Metrics, Logs & Traces with Open Source by Emil-Andr...
OSMC 2022 | The Power of Metrics, Logs & Traces with Open Source by Emil-Andr...OSMC 2022 | The Power of Metrics, Logs & Traces with Open Source by Emil-Andr...
OSMC 2022 | The Power of Metrics, Logs & Traces with Open Source by Emil-Andr...
 
Tracing 2000+ polyglot microservices at Uber with Jaeger and OpenTracing
Tracing 2000+ polyglot microservices at Uber with Jaeger and OpenTracingTracing 2000+ polyglot microservices at Uber with Jaeger and OpenTracing
Tracing 2000+ polyglot microservices at Uber with Jaeger and OpenTracing
 
stackconf 2023 | Practical introduction to OpenTelemetry tracing by Nicolas F...
stackconf 2023 | Practical introduction to OpenTelemetry tracing by Nicolas F...stackconf 2023 | Practical introduction to OpenTelemetry tracing by Nicolas F...
stackconf 2023 | Practical introduction to OpenTelemetry tracing by Nicolas F...
 

Semelhante a OpenTelemetry Introduction

2307 - DevBCN - Otel 101_compressed.pdf
2307 - DevBCN - Otel 101_compressed.pdf2307 - DevBCN - Otel 101_compressed.pdf
2307 - DevBCN - Otel 101_compressed.pdfDimitrisFinas1
 
Tracing-for-fun-and-profit.pptx
Tracing-for-fun-and-profit.pptxTracing-for-fun-and-profit.pptx
Tracing-for-fun-and-profit.pptxHai Nguyen Duy
 
OGCE Overview for SciDAC 2009
OGCE Overview for SciDAC 2009OGCE Overview for SciDAC 2009
OGCE Overview for SciDAC 2009marpierc
 
WSO2 Complex Event Processor - Product Overview
WSO2 Complex Event Processor - Product OverviewWSO2 Complex Event Processor - Product Overview
WSO2 Complex Event Processor - Product OverviewWSO2
 
Implementing Observability for Kubernetes.pdf
Implementing Observability for Kubernetes.pdfImplementing Observability for Kubernetes.pdf
Implementing Observability for Kubernetes.pdfJose Manuel Ortega Candel
 
Leveraging the strength of OSGi to deliver a convergent IoT Ecosystem - O Log...
Leveraging the strength of OSGi to deliver a convergent IoT Ecosystem - O Log...Leveraging the strength of OSGi to deliver a convergent IoT Ecosystem - O Log...
Leveraging the strength of OSGi to deliver a convergent IoT Ecosystem - O Log...mfrancis
 
FIWARE Wednesday Webinars - Short Term History within Smart Systems
FIWARE Wednesday Webinars - Short Term History within Smart SystemsFIWARE Wednesday Webinars - Short Term History within Smart Systems
FIWARE Wednesday Webinars - Short Term History within Smart SystemsFIWARE
 
Opentracing jaeger
Opentracing jaegerOpentracing jaeger
Opentracing jaegerOracle Korea
 
Distributed Tracing with Jaeger
Distributed Tracing with JaegerDistributed Tracing with Jaeger
Distributed Tracing with JaegerInho Kang
 
Security & Resiliency of Cloud Native Apps with Weave GitOps & Tetrate Servic...
Security & Resiliency of Cloud Native Apps with Weave GitOps & Tetrate Servic...Security & Resiliency of Cloud Native Apps with Weave GitOps & Tetrate Servic...
Security & Resiliency of Cloud Native Apps with Weave GitOps & Tetrate Servic...Weaveworks
 
Comparison between OGC Sensor Observation Service and SensorThings API
Comparison between OGC Sensor Observation Service and SensorThings APIComparison between OGC Sensor Observation Service and SensorThings API
Comparison between OGC Sensor Observation Service and SensorThings APISensorUp
 
Istio Service Mesh
Istio Service MeshIstio Service Mesh
Istio Service MeshLew Tucker
 
Gervais Peter Resume Oct :2015
Gervais Peter Resume Oct :2015Gervais Peter Resume Oct :2015
Gervais Peter Resume Oct :2015Peter Gervais
 
Monitoring federation open stack infrastructure
Monitoring federation open stack infrastructureMonitoring federation open stack infrastructure
Monitoring federation open stack infrastructureFernando Lopez Aguilar
 
Using open source for IoT
Using open source for IoTUsing open source for IoT
Using open source for IoTIan Skerrett
 
Application Monitoring using Open Source: VictoriaMetrics - ClickHouse
Application Monitoring using Open Source: VictoriaMetrics - ClickHouseApplication Monitoring using Open Source: VictoriaMetrics - ClickHouse
Application Monitoring using Open Source: VictoriaMetrics - ClickHouseVictoriaMetrics
 
Application Monitoring using Open Source - VictoriaMetrics & Altinity ClickHo...
Application Monitoring using Open Source - VictoriaMetrics & Altinity ClickHo...Application Monitoring using Open Source - VictoriaMetrics & Altinity ClickHo...
Application Monitoring using Open Source - VictoriaMetrics & Altinity ClickHo...Altinity Ltd
 
Interledger DvP Settlement on Amazon Managed Blockchain
Interledger DvP Settlement on Amazon Managed BlockchainInterledger DvP Settlement on Amazon Managed Blockchain
Interledger DvP Settlement on Amazon Managed BlockchainAmazon Web Services
 

Semelhante a OpenTelemetry Introduction (20)

2307 - DevBCN - Otel 101_compressed.pdf
2307 - DevBCN - Otel 101_compressed.pdf2307 - DevBCN - Otel 101_compressed.pdf
2307 - DevBCN - Otel 101_compressed.pdf
 
Tracing-for-fun-and-profit.pptx
Tracing-for-fun-and-profit.pptxTracing-for-fun-and-profit.pptx
Tracing-for-fun-and-profit.pptx
 
OGCE Overview for SciDAC 2009
OGCE Overview for SciDAC 2009OGCE Overview for SciDAC 2009
OGCE Overview for SciDAC 2009
 
WSO2 Complex Event Processor - Product Overview
WSO2 Complex Event Processor - Product OverviewWSO2 Complex Event Processor - Product Overview
WSO2 Complex Event Processor - Product Overview
 
BlockchainLAB Hackathon
BlockchainLAB HackathonBlockchainLAB Hackathon
BlockchainLAB Hackathon
 
Implementing Observability for Kubernetes.pdf
Implementing Observability for Kubernetes.pdfImplementing Observability for Kubernetes.pdf
Implementing Observability for Kubernetes.pdf
 
Leveraging the strength of OSGi to deliver a convergent IoT Ecosystem - O Log...
Leveraging the strength of OSGi to deliver a convergent IoT Ecosystem - O Log...Leveraging the strength of OSGi to deliver a convergent IoT Ecosystem - O Log...
Leveraging the strength of OSGi to deliver a convergent IoT Ecosystem - O Log...
 
FIWARE Wednesday Webinars - Short Term History within Smart Systems
FIWARE Wednesday Webinars - Short Term History within Smart SystemsFIWARE Wednesday Webinars - Short Term History within Smart Systems
FIWARE Wednesday Webinars - Short Term History within Smart Systems
 
Opentracing jaeger
Opentracing jaegerOpentracing jaeger
Opentracing jaeger
 
Distributed Tracing with Jaeger
Distributed Tracing with JaegerDistributed Tracing with Jaeger
Distributed Tracing with Jaeger
 
Security & Resiliency of Cloud Native Apps with Weave GitOps & Tetrate Servic...
Security & Resiliency of Cloud Native Apps with Weave GitOps & Tetrate Servic...Security & Resiliency of Cloud Native Apps with Weave GitOps & Tetrate Servic...
Security & Resiliency of Cloud Native Apps with Weave GitOps & Tetrate Servic...
 
Comparison between OGC Sensor Observation Service and SensorThings API
Comparison between OGC Sensor Observation Service and SensorThings APIComparison between OGC Sensor Observation Service and SensorThings API
Comparison between OGC Sensor Observation Service and SensorThings API
 
citus™ iot ecosystem
citus™ iot ecosystemcitus™ iot ecosystem
citus™ iot ecosystem
 
Istio Service Mesh
Istio Service MeshIstio Service Mesh
Istio Service Mesh
 
Gervais Peter Resume Oct :2015
Gervais Peter Resume Oct :2015Gervais Peter Resume Oct :2015
Gervais Peter Resume Oct :2015
 
Monitoring federation open stack infrastructure
Monitoring federation open stack infrastructureMonitoring federation open stack infrastructure
Monitoring federation open stack infrastructure
 
Using open source for IoT
Using open source for IoTUsing open source for IoT
Using open source for IoT
 
Application Monitoring using Open Source: VictoriaMetrics - ClickHouse
Application Monitoring using Open Source: VictoriaMetrics - ClickHouseApplication Monitoring using Open Source: VictoriaMetrics - ClickHouse
Application Monitoring using Open Source: VictoriaMetrics - ClickHouse
 
Application Monitoring using Open Source - VictoriaMetrics & Altinity ClickHo...
Application Monitoring using Open Source - VictoriaMetrics & Altinity ClickHo...Application Monitoring using Open Source - VictoriaMetrics & Altinity ClickHo...
Application Monitoring using Open Source - VictoriaMetrics & Altinity ClickHo...
 
Interledger DvP Settlement on Amazon Managed Blockchain
Interledger DvP Settlement on Amazon Managed BlockchainInterledger DvP Settlement on Amazon Managed Blockchain
Interledger DvP Settlement on Amazon Managed Blockchain
 

Último

How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024The Digital Insurer
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 

Último (20)

How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 

OpenTelemetry Introduction

  • 1. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. CNCF Meetup – 12 May 2022 – v4 Dimitris Finas, Sr Advisory Solution Consultant An introduction to OpenTelemetry
  • 2. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Agenda ● What is OpenTelemetry? ○ A Brief History ● Distributed Tracing Overview ● OpenTelemetry ○ Instrumentation ○ Collectors ● Q&A ● Put it in action
  • 3. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. What is OpenTelemetry? 3 OpenTelemetry is a set of APIs, SDKs, tooling and integrations that are designed for the creation and management of telemetry data, such as traces, metrics, and logs. OpenTelemetry's Mission is to enable effective observability by making high-quality, portable telemetry ubiquitous and vendor-agnostic. A trace represents a single user’s journey across multiple applications and systems (usually microservices). Numeric data measured at various time intervals (time series data); SLI’s (request rate, error rate, duration, CPU%, etc.) Timestamped records of discrete events that happened within an application or system, such as a failure, an error, or a state transformation You want more? See Otel vision in https://github.com/open-telemetry/community/blob/main/mission-vision-values.md#otel-mission-vision-and-values
  • 4. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. OpenTelemetry - A brief history 2015 Lightstep is founded by Ben Sigelman, Daniel Spoonhower, and Ben Cronin 2016 Lightstep helps to found OpenTracing, the first common, portable API for distributed tracing 2017 Jaeger, an open-source tracing tool developed by Yuri Shkuro, is open- sourced by Uber 2018 Google releases a new portable instrumentation project called OpenCensus 2019 The OpenTracing and OpenCensus projects announce a merger, forming OpenTelemetry to be a part of CNCF 2020 OpenTelemetry is released in beta 4
  • 5. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved.
  • 6. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. 6 Lightstep Founded Standards Languages Tracers Service Meshes / Proxies Containers, Platforms and Clouds Deployment Automation (CI/CD) Alerting and Tools Data Streaming and Storage Integrations See up to date list in https://opentelemetry.io/registry/
  • 7. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. What are distributed traces?
  • 8. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Introduction to distributed traces A distributed trace provides a view of the life of a request as it travels across multiple hosts and services communicating over various protocols 8
  • 9. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Introduction to distributed traces Trace A “trace” is a view into the request lifecycle as a whole as it moves through a distributed system. 9
  • 10. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Introduction to distributed traces 10 Trace Span Span A trace is a collection of spans. Each component of the distributed system contributes a “span” - a named, timed operation representing a piece of the workflow.
  • 11. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Introduction to distributed traces Trace Span Span Time client transaction from start to end load balancer transaction from start to end auth billing resource allocation and provisioning container start-up storage allocation start-up scripts 11
  • 12. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Introduction to distributed traces Time A trace can be visualized as a tree of spans with a “root” span at the top. client transaction from start to end load balancer transaction from start to end auth billing resource allocation and provisioning container start-up storage allocation start-up scripts 12
  • 13. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Introduction to distributed traces Time Spans have parent-child relationships. Parent spans can have multiple children. client transaction from start to end load balancer transaction from start to end auth billing resource allocation and provisioning container start-up storage allocation start-up scripts 13
  • 14. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Introduction to distributed traces Time Child spans don’t necessarily finish before their parents This can be seen with asynchronous children Real world example: An rpc call timeout out - the parent span finished earlier than the hanging child client transaction from start to end load balancer transaction from start to end auth billing resource allocation and provisioning container start-up storage allocation start-up scripts 14
  • 15. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Visualizing a trace 15
  • 16. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Visualizing a trace Each span also has span context Span context is composed of attributes (tags) and events (logs). These are added during instrumentation. Attributes allow you to search and segment your data within LightStep Events (logs) add information that is useful during root cause and debugging 16
  • 17. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. OpenTelemetry Instrumentation
  • 18. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. OpenTelemetry support of dev languages You want to know more? See https://opentelemetry.io/docs/instrumentation/ LANGUAGE TRACE STATUS* INSTRUMENTATION MANUAL/AUTO** C++ stable manual C# / .NET stable manual & auto Erlang / Elixir stable manual Go stable manual Java stable manual & auto Javascript / Node stable manual & auto Javascript / Browser stable manual & auto LANGUAGE TRACE STATUS* INSTRUMENTATION MANUAL/AUTO** PHP pre-alpha manual Python stable manual & auto Ruby stable manual & auto Rust beta manual Swift beta manual (*) Trace implementation status as of end of April 2022 (**) Automatic instrumentation means quick wins as no need to update existing code to collect some data Supported languages versions: • .NET & .NET Framework all supported versions except .NET Fwk v3.5 as https://github.com/open-telemetry/opentelemetry-dotnet • Java > v1.8 • NodeJS >v10 as https://github.com/open-telemetry/opentelemetry-js • Python, only latest versions as of https://github.com/open- telemetry/opentelemetry-python 18
  • 19. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. ● Configure Tracer ● Create Spans ○ Decorate Spans ● Context Propagation OTel Instrumentation Steps 20
  • 20. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Configure Tracer const opentelemetry = require('@opentelemetry/api'); const { NodeTracerProvider } = require('@opentelemetry/node'); const { SimpleSpanProcessor } = require('@opentelemetry/tracing'); const { CollectorTraceExporter } = require('@opentelemetry/exporter-collector'); const collectorOptions = { serviceName: '<Service Name>', // Provide a service name url: 'https://<Satellite Host>:<Satellite Port>/api/v2/otel/trace', // URL and port to Lightstep Satellite headers: { 'Lightstep-Access-Token': 'YOUR_TOKEN' //Lightstep Access Token }, }; // Create an exporter for sending span data const exporter = new CollectorTraceExporter(collectorOptions); // Create a provider for activating and tracking spans const tracerProvider = new NodeTracerProvider({ plugins: { http: { enabled: true, // You may use a package name or absolute path to the file. path: '@opentelemetry/plugin-http', // Enable HTTP Plugin to automatically inject/extract context into HTTP headers } } }); // Configure a span processor for the tracer tracerProvider.addSpanProcessor(new SimpleSpanProcessor(exporter)); // Register the tracer tracerProvider.register(); Declare Dependencies Declare Destination Options Declare Plugins 21
  • 21. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. 23 Send Telemetry To OpenTelemetry Collector ... const collectorOptions = { serviceName: '<Service Name>', // Provide a service name url: 'https://<Collector Host>:<Collector Port>', // URL and port to OTel Collector }; const exporter = new CollectorTraceExporter(collectorOptions); ... Only difference between sending traffic to an OTel Collector and a Lightstep Satellite is the address and Access Token
  • 22. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Create Spans const tracer = opentelemetry.trace.getTracer(); const span = tracer.startSpan('foo'); span.setAttribute('platform', 'osx'); span.setAttribute('version', '1.2.3'); span.addEvent('event in foo'); const childSpan = tracer.startSpan('bar', { parent: span, }); childSpan.end(); span.end(); Start Span Decorate Span Create Child Span End Span 24
  • 23. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. ● tracer.startSpan(name, {parent: <span>, …}) ○ This method returns a child of the specified span. ● api.context.with(api.setSpan(api.context.active(), name)) ○ Starts a new span, sets it to be active. Optionally, can get a reference to the span. ● api.trace.getSpan(api.context.active()) ○ Used to access & add information to the current span ● span.addEvent(msg) ○ Adds structured annotations (e.g. "logs") about what is currently happening. ● span.setAttributes(core.Key(key).String(value)...) ○ Adds a structured, typed attribute to the current span. This may include a user id, a build id, a user-agent, etc. ● span.end() ○ Often used with defer, fires when the unit of work is complete and the span can be sent Tracer Span Methods 25
  • 24. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Context Propagation ● Distributed context is an abstract data type that represents collection of entries. ● Each key is associated with exactly one value. ● It is serialized for propagation across process boundaries ● Passing around the context enables related spans to be associated with a single trace. ● W3C TraceContext is the de-facto standard. ● Context propagation can be automatically handled by using HTTP plugin ● Manual propagation code can be found here: https://open- telemetry.github.io/opentelemetry-js/classes/propagationapi.html 26
  • 25. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. 27 Putting It All Together const opentelemetry = require('@opentelemetry/api'); const { NodeTracerProvider } = require('@opentelemetry/node'); const { SimpleSpanProcessor } = require('@opentelemetry/tracing'); const { CollectorTraceExporter } = require('@opentelemetry/exporter-collector'); const collectorOptions = { serviceName: '<Service Name>', // Provide a service name url: 'https://<Satellite Host>:<Satellite Port>/api/v2/otel/trace', // URL and port to Lightstep Satellite headers: { 'Lightstep-Access-Token': 'YOUR_TOKEN' //Lightstep Access Token }, }; // Create an exporter for sending span data const exporter = new CollectorTraceExporter(collectorOptions); // Create a provider for activating and tracking spans const tracerProvider = new NodeTracerProvider({ plugins: { http: { enabled: true, // You may use a package name or absolute path to the file. path: '@opentelemetry/plugin-http', // Enable HTTP Plugin to automatically inject/extract context into HTTP headers } } }); Continued….. // Configure a span processor for the tracer tracerProvider.addSpanProcessor(new SimpleSpanProcessor(exporter)); // Register the tracer tracerProvider.register(); const tracer = opentelemetry.trace.getTracer(); const span = tracer.startSpan('foo'); span.setAttribute('platform', 'osx'); span.setAttribute('version', '1.2.3'); span.addEvent('event in foo'); const childSpan = tracer.startSpan('bar', { parent: span, }); childSpan.end(); span.end();
  • 26. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. SDKs, Exporters, and Collector Services ● OpenTelemetry's SDK implements trace & span creation. ● An exporter can be instantiated to send the data collected by OpenTelemetry to the backend of your choice. ○ E.g. Jaeger, Lightstep, etc. ● OpenTelemetry collector proxies data between instrumented code and backend service(s). The exporters can be reconfigured without changing instrumented code. 28
  • 27. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Appendix ● NodeJS OpenTelemetry API Docs: https://open- telemetry.github.io/opentelemetry-js/ ● Context Propagation API Docs: https://open- telemetry.github.io/opentelemetry-js/classes/propagationapi.html ● Plugins: ○ Core: https://github.com/open-telemetry/opentelemetry-js/tree/master/packages ○ Contrib: https://github.com/open-telemetry/opentelemetry-js-contrib/tree/master/plugins/node 29
  • 28. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Appendix (Cont’d): Basic Data Formats JSON formatted info, output when span.end() was called. "SpanContext": { "TraceID": "9850b11fa09d4b5fa4dd48dd37f3683b", "SpanID": "1113d149cfffa942", "TraceFlags": 1 }, "ParentSpanID": "e1e1624830d2378e", "SpanKind": "internal", "Name": "dbHandler/database", "StartTime": "2019-11-03T10:52:56.903919262Z", "EndTime": "2019-11-03T10:52:56.903923338Z", "Attributes": [], "MessageEvents": null, "Links": null, "Status": 0, "HasRemoteParent": false, "DroppedAttributeCount": 0, "DroppedMessageEventCount": 0, "DroppedLinkCount": 0, "ChildSpanCount": 0 30
  • 29. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Appendix (Cont’d): Attributes & MessageEvents "Attributes": [ { "Key": "http.host", "Value": { "Type": "STRING", "Value": "opentelemetry-instructor.glitch.me" } }, { "Key": "http.status_code", "Value": { "Type": "INT64", "Value": 200 } } ], "MessageEvents": [ { "Message": "annotation within span", "Attributes": null, "Time": "2019-11-03T10:52:56.903914029Z" } ], 31
  • 30. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. OpenTelemetry Collectors
  • 31. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. The OTel Collector is an independent binary process, written in Go, that acts as a ‘universal agent’ for the OpenTelemetry ecosystem. At a high level, the goals of the collector are… - Collect, process, and export telemetry data in a highly performant and stable manner. - Support multiple types of telemetry. - Highly extensible and customizable, but with an easy OOB experience. The collector provides separation of concerns between Developers and Operations/SRE teams. What is the OpenTelemetry Collector? 33
  • 32. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. The collector has 4 major components - - Receivers - Processors - Exporters - Extensions Collectors receive, process, and forward telemetry to export destinations. These can be part of one, or more, pipelines. Architecture of the Collector 34
  • 33. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Telemetry data flows through the collector, from receiver to exporter. Multiple pipelines in a single collector are configurable, but each must operate on a single telemetry type - either traces, or metrics. All data received by a pipeline will be processed by all processors and exported to all exporters. Pipelines 35
  • 34. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. service: pipelines: # section that can contain multiple subsections, one per pipeline traces: # type of the pipeline receivers: [opencensus, jaeger, zipkin] processors: [tags, tail_sampling, batch, queued_retry] exporters: [opencensus, jaeger, stackdriver, zipkin] YAML 36
  • 35. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Receivers listen on a single port for telemetry data. A single receiver can send to multiple pipelines. Currently, the collector supports the following receivers - - OTLP - OpenCensus - Fluentd Forward - Jaeger - Zipkin - Prometheus - Host Metrics Receivers 37
  • 36. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Receivers, Cont’d. The collector also supports third-party/contributed receivers, which include: ● Amazon X-Ray ● Wavefront ● SignalFX ● Carbon ● CollectD ● Redis ● Kubernetes/Kubelet Many of these are metrics receivers, but some (xray, SAPM) are trace receivers. 38
  • 37. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Receivers: otlp: grpc: endpoint: "0.0.0.0:55678" service: pipelines: traces: # a pipeline of “traces” type receivers: [otlp] processors: [tags, tail_sampling, batch, queued_retry] exporters: [otlp] YAML 39
  • 38. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Typically, an exporter will forward all data it receives to a network endpoint, but can also write to a file or console. Similar to receivers, a single exporter may be included in multiple pipelines. Exporters 40
  • 39. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. exporters: jaeger: protocols: grpc: endpoint: "0.0.0.0:14250" otlp: endpoint: <YOUR_LOAD_BALANCER_DNS_NAME_OR_IP_ADDRESS> headers: {"lightstep-access-token":"<YOUR_ACCESS_TOKEN>"} service: pipelines: traces: # a pipeline of “traces” type receivers: [OTLP] processors: [tags, tail_sampling, batch, queued_retry] exporters: [jaeger, otlp] YAML 41
  • 40. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Processors are very powerful! They run sequentially, and receive all data from the processor before them. A processor can transform telemetry data, delete it, etc. A single processor configuration can apply to multiple pipelines, but each pipeline gets a unique instance of the processor. Processors 42
  • 41. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. processors: queued_retry: size: 50 per-exporter: true enabled: true service: pipelines: traces: # a pipeline of “traces” type receivers: [zipkin] processors: [queued_retry] exporters: [jaeger] traces/2: # another pipeline of “traces” type receivers: [opencensus] processors: [queued_retry] exporters: [opencensus] YAML 43
  • 42. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Receivers, Exporters, and Extensions aren’t super interesting on the face of things - they receive or emit data, or simply give you some introspection on the collector instance. Processors, however, can do a lot. Let’s talk about them. Processors Deep Dive 44
  • 43. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Processors Ordering 45 Remember this? Processors one run after the other, so the order that you define them matters. This means that limiting and sampling should be first, and batching/transforms should be later.
  • 44. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. The memory limiter is used to prevent a collector from going OOM. It does this by allowing the user to configure and tune GC on the collector. This is not a replacement for sizing/tuning collector memory/cpu. Memory Limiter processors: memory_limiter: ballast_size_mib: 2000 check_interval: 5s limit_mib: 4000 spike_limit_mib: 500 46
  • 45. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Out of the box, the collector supports a probabilistic sampler and a tail-based sampler. Probabilistic supports OpenTracing priority sampling hints as well as trace ID based hashing. Tail sampling allows for user-defined policies such as string/number attributes or desired rate. Sampling Processors 47
  • 46. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. processors: probabilistic_sampler: hash_seed: 22 sampling_percentage: 15.3 tail_sampling: decision_wait: 10s num_traces: 100 expected_new_traces_per_sec: 10 policies: [ { name: test-policy-1, type: always_sample }, { name: test-policy-2, type: numeric_attribute, numeric_attribute: {key: key1, min_value: 50, max_value: 100} }, { name: test-policy-3, type: string_attribute, string_attribute: {key: key2, values: [value1, value2]} }, { name: test-policy-4, type: rate_limiting, rate_limiting: {spans_per_second: 35} } ] 48
  • 47. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Attribute processors can modify the attributes of a span; insert, update, upsert, delete, and extract based on attribute names or regular expressions. Span processors can modify a span name or attributes based on a span name. This can be used for more precise data scrubbing, creating attributes from span names, hashing attribute fields, and more. Note: Resource attributes are modified with the Resource processor. Attribute and Span Processors 49
  • 48. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Functionality can be added to the collector through Extensions. Currently, this is used for health checks and diagnostic information. Extensions 50
  • 49. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. # Example of the extensions available with the core Collector. The list below # includes all configurable options and their respective default value. extensions: health_check: port: 13133 pprof: endpoint: "localhost:1777" block_profile_fraction: 0 mutex_profile_fraction: 0 zpages: endpoint: "localhost:55679" # The service lists extensions not directly related to data pipelines, but used # by the service. service: # extensions lists the extensions added to the service. They are started # in the order presented below and stopped in the reverse order. extensions: [health_check, pprof, zpages] 51
  • 50. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. receivers: otlp: protocols: grpc: endpoint: "0.0.0.0:55680" http: endpoint: "0.0.0.0:55681" processors: batch: queued_retry: extensions: health_check: {} exporters: otlp: endpoint: "ingest.lightstep.com:443" headers: "lightstep-access-token": "{{ .Values.lightstepKey }}" service: extensions: [health_check, zpages] pipelines: traces: receivers: [otlp] processors: [batch, queued_retry] exporters: [otlp] This can be any receiver, not just OTLP. Remember, receivers can be part of multiple pipelines! Batch and Retry processors are recommended to reduce connections and decrease size of outgoing reports. Other export options include compression (gzip), etc. If satellites are in Single Project mode, no headers needed, just endpoint! Putting It All Together 52
  • 51. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. A goal of the collector is ‘5 Minutes to Value’, and part of this is easy support for a variety of deployment strategies. The collector can be run as an ‘agent’ or as a standalone (or pool of standalone) processes. Eventually, the collector will support distribution packages for popular targets (rpm, docker, windows…) and automatic ingest of environment metrics/tags (AWS env resources, k8s, etc.) Collector Deployment Strategies 53
  • 52. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Further Reading: Collectors Most collector components are well-documented, and you can find individual READMEs in each sub-directory of the https://github.com/open-telemetry/opentelemetry-collector repository. Third-party extensions, processors, receivers, and exporters are available in the https://github.com/open-telemetry/opentelemetry-collector-contrib repository. A Kubernetes Operator is available at https://github.com/open-telemetry/opentelemetry- operator, but tends to lag development significantly and so I don’t currently recommend it. 56
  • 53. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Further Reading: OpenTelemetry ● OpenTelemetry documentation https://opentelemetry.io/docs/ and https://opentelemetry.lightstep.com/ ● OpenTelemetry registry to get list of supported technologies and projects: https://opentelemetry.io/registry/ ● How to choose your Observability solution: https://medium.com/dzerolabs/unpacking- observability-how-to-choose-an-observability-vendor-aa0e6d80b71d 57
  • 54. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Q&A
  • 55. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. o Instrument your first application for distributed traces visibility o Deploy your first Collector o Connect and see results in different backends Put it in action
  • 56. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. ● Activity ○ Collect distributed traces from your application ○ Use Otel Collector to receive traces ○ See results in console output ● Lab 1.1 ○ Time: 15m ○ Clone the git application repository ○ Add auto-instrumentation to NodeJS application ○ Test and see results in console output ● Lab 1.2 ○ Time: 10m ○ Deploy Collector as container ○ Send traces to Collector ○ Test and see results in Collector output and debug Module Lab and Activities (1/2)
  • 57. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. ● Activity ○ Send traces to different Backends ○ Add custom attributes and log events ○ Test with volume and see results in backends ● Lab 2.1 ○ Time: 10m ○ Create your Lightstep account ○ Update Collector to send traces to Jaeger and Lightstep ○ Test and see results in the backends ● Lab 2.2 ○ Time: 15m ○ Add custom attributes and log events ○ Start some volume tests ○ See correlated analysis in Lightstep backend Module Lab and Activities (2/2)
  • 58. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. © 2022 Lightstep from ServiceNow, Inc. All Rights Reserved. Prerequites: you must have docker desktop installed Ø git clone https://github.com/dimitrisfinas/nodejs-microservices- example.git Ø cd nodejs-microservices-example Ø docker-compose up --build Once deployment finished, check application works: Ø Open Browser on ”http://127.0.0.1:4000/api/data” Then, follow instructions from file “INSTALLING_OTEL.md” All URLs to test application are available from “README.md” in “## Starting the microservices application” section Step by Step instructions