SlideShare uma empresa Scribd logo
inspectIT Ocelot: Dynamic OpenTelemetry
Instrumentation at Runtime
Open Source Monitoring Conference 2021
The Scenario
2
Is the application
working?
How many users
are accessing it?
How long did my
task take?
How many errors
occur?
What is its
memory footprint?
What other applications
are called?
The Scenario
3
Java Class
public Result getQuote(Subject subject) {
long start = System.currentTimeMillis();
validate(params);
Result result = quoteManager.getQuote(subject);
long duration = System.currentTimeMillis() - start;
Attributes attributes = create("quote-subject", subject);
Observer.record("getQuote", duration, attributes);
return result;
}
Capturing the start time
Application logic
Calculate the execution time
Record the execution time
with context information
How long did my application take to
provide a quote for a car?
…
getQuote {‘quote-subject’:‘car’} 252ms
getQuote {‘quote-subject’:‘bike’} 78ms
…
It takes 252 milliseconds.
Our Goal
4
Java Class
public Result getQuote(Subject subject) {
long start = System.currentTimeMillis();
validate(params);
Result result = quoteManager.getQuote(subject);
long duration = System.currentTimeMillis() - start;
Attributes attributes = create("quote-subject", subject);
Observer.record("getQuote", duration, attributes);
return result;
}
Do we have to do this for each
application?
But we need something consistent
across all applications!
How do I get this data into my
analysis tool?
OpenTelemetry
5
§ Provides uniform standard for telemetry data.
§ Data can be correlated across systems.
§ Data can be exported to a variety of analysis tools.
What is OpenTelemetry?
6
“OpenTelemetry is a collection of tools, APIs, and SDKs. Use it to instrument,
generate, collect, and export telemetry data (metrics, logs, and traces) to help you
analyze your software’s performance and behavior.”
Source: https://opentelemetry.io/
DATA
How is it working?
7
OpenTelemetry API
Used to generate
telemetry data.
OpenTelemetry SDK
Implementation of the
API
OpenTelemetry
Extentions / Exporters
Additional API extensions, which
are not part of the core API.
Additional Components
E.g.: OTel-Collector, Jaeger, …
Manual Instrumentation via OTel API
8
Java Class
public Result getQuote(Subject subject) {
Span span = tracer.spanBuilder("getQuote").startSpan();
span.setAttribute("quote-subject", subject);
try (Scope scope = span.makeCurrent()) {
validate(params);
return quoteManager.getQuote(subject);
} finally {
span.end();
}
} Collected data is exported using
configured OpenTelemetry exporter
Application logic
Start span and assign data
End and record the span
Context Propagation
Changes need to be made to the source code.
§ OpenTelemetry Java agent can be used to dynamically
injects bytecode to capture telemetry of popular libraries
and frameworks.
§ But: no ability to extract
specific data from
certain classes.
Auto-Instrumentation
9
Java Class
public Result getQuote(Subject subject) {
validate(params);
return quoteManager.getQuote(subject);
}
Java Class
public Result getQuote(Subject subject) {
Span span = tracer.spanBuilder("getQuote").startSpan();
span.setAttribute("quote-subject", subject);
try (Scope scope = span.makeCurrent()) {
validate(params);
return quoteManager.getQuote(subject);
} finally {
span.end();
}
}
Java agent automatically adds
OpenTelemetry instrumentation
to classes using Bytecode
Instrumentation (BCI)
Modified (instrumented) Class
Original Class
Java Agent
Class Transformation
inspectIT Ocelot
10
§ A highly configurable Java agent for collecting telemetry and any
(business) data of Java applications.
§ Instrumentation (injected OpenTelemetry bytecode) can be
changed during application runtime.
§ Pre-configured to capture telemetry data of popular libraries and
frameworks.
§ Utility components that support the use of the agent (e.g.
configuration-server).
What is inspectIT Ocelot
11
Ocelot
Java Agent
Configuration
Server
Managing agents and
agent configurations
Fetch Configuration
http://inspectit.rocks/
§ The configuration-server provides a simple UI for creating configurations
Basic Tracing
12
Easy selection of the
methods to be traced with
the ”class browser”.
Advanced YAML-based Configuration
13
§ Configuration determines what the agent does and consists of
three basic components:
Actions
What should the agent do
Scopes
Where should the agent do
something
Rules
Uses scopes and rules to instruct
the agent what to do
E.g.: Capture the first
method argument
E.g.: method “execute”
of class “Worker”
E.g.: trace the method “execute” of
class “worker”, capture the first
method argument of it and attach it
to the current span
Advanced YAML-based Configuration - Tracing
Predefined instruction set –
trace all methods in the scopes
Which scopes should be used
Which actions should be
executed when a method starts
Which data should be recorded
Scope
Action
Rule
Result (e.g.: Jaeger):
Advanced YAML-based Configuration - Metrics
Which scopes should be used
Which actions should be
executed when a method starts
Use the recorded data as a
metric’s value and export it
Scope
Action
Rule
Result (e.g. Prometheus):
Let's see it in action!
16
§ Check out the talk “Open Source Application Performance Monitoring
in the Enterprise” by Sascha Brechmann of VHV Versicherung
Real-World Usage of inspectIT Ocelot
17
Novatec Consulting GmbH
Bertha-Benz-Platz 1
D-70771 Leinfelden-Echterdingen
T. +49 711 22040-700
info@novatec-gmbh.de
www.novatec-gmbh.de
18
Senior Consultant
Marius Oehler
E-Mail: marius.oehler@novatec-gmbh.de

Mais conteúdo relacionado

Mais procurados

GitOps - Modern best practices for high velocity app dev using cloud native t...
GitOps - Modern best practices for high velocity app dev using cloud native t...GitOps - Modern best practices for high velocity app dev using cloud native t...
GitOps - Modern best practices for high velocity app dev using cloud native t...Weaveworks
 
CI:CD in Lightspeed with kubernetes and argo cd
CI:CD in Lightspeed with kubernetes and argo cdCI:CD in Lightspeed with kubernetes and argo cd
CI:CD in Lightspeed with kubernetes and argo cdBilly Yuen
 
Introduction to Kubernetes Workshop
Introduction to Kubernetes WorkshopIntroduction to Kubernetes Workshop
Introduction to Kubernetes WorkshopBob Killen
 
Gitops: the kubernetes way
Gitops: the kubernetes wayGitops: the kubernetes way
Gitops: the kubernetes waysparkfabrik
 
Prometheus and Docker (Docker Galway, November 2015)
Prometheus and Docker (Docker Galway, November 2015)Prometheus and Docker (Docker Galway, November 2015)
Prometheus and Docker (Docker Galway, November 2015)Brian Brazil
 
OpenTelemetry Introduction
OpenTelemetry Introduction OpenTelemetry Introduction
OpenTelemetry Introduction DimitrisFinas1
 
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
 
初探 OpenTelemetry - 蒐集遙測數據的新標準
初探 OpenTelemetry - 蒐集遙測數據的新標準初探 OpenTelemetry - 蒐集遙測數據的新標準
初探 OpenTelemetry - 蒐集遙測數據的新標準Marcus Tung
 
A GitOps Kubernetes Native CICD Solution with Argo Events, Workflows, and CD
A GitOps Kubernetes Native CICD Solution with Argo Events, Workflows, and CDA GitOps Kubernetes Native CICD Solution with Argo Events, Workflows, and CD
A GitOps Kubernetes Native CICD Solution with Argo Events, Workflows, and CDJulian Mazzitelli
 
Monitoring Kubernetes with Prometheus
Monitoring Kubernetes with PrometheusMonitoring Kubernetes with Prometheus
Monitoring Kubernetes with PrometheusGrafana Labs
 
Kubernetes 101 for Beginners
Kubernetes 101 for BeginnersKubernetes 101 for Beginners
Kubernetes 101 for BeginnersOktay Esgul
 
Opentelemetry - From frontend to backend
Opentelemetry - From frontend to backendOpentelemetry - From frontend to backend
Opentelemetry - From frontend to backendSebastian Poxhofer
 
Free GitOps Workshop + Intro to Kubernetes & GitOps
Free GitOps Workshop + Intro to Kubernetes & GitOpsFree GitOps Workshop + Intro to Kubernetes & GitOps
Free GitOps Workshop + Intro to Kubernetes & GitOpsWeaveworks
 
Kubernetes and Prometheus
Kubernetes and PrometheusKubernetes and Prometheus
Kubernetes and PrometheusWeaveworks
 
Deep Dive into Building a Secure & Multi-tenant SaaS Solution with NATS
Deep Dive into Building a Secure & Multi-tenant SaaS Solution with NATSDeep Dive into Building a Secure & Multi-tenant SaaS Solution with NATS
Deep Dive into Building a Secure & Multi-tenant SaaS Solution with NATSNATS
 
KCD-OpenTelemetry.pdf
KCD-OpenTelemetry.pdfKCD-OpenTelemetry.pdf
KCD-OpenTelemetry.pdfRui Liu
 

Mais procurados (20)

GitOps - Modern best practices for high velocity app dev using cloud native t...
GitOps - Modern best practices for high velocity app dev using cloud native t...GitOps - Modern best practices for high velocity app dev using cloud native t...
GitOps - Modern best practices for high velocity app dev using cloud native t...
 
Kubernetes 101
Kubernetes 101Kubernetes 101
Kubernetes 101
 
CI:CD in Lightspeed with kubernetes and argo cd
CI:CD in Lightspeed with kubernetes and argo cdCI:CD in Lightspeed with kubernetes and argo cd
CI:CD in Lightspeed with kubernetes and argo cd
 
Introduction to Kubernetes Workshop
Introduction to Kubernetes WorkshopIntroduction to Kubernetes Workshop
Introduction to Kubernetes Workshop
 
Gitops: the kubernetes way
Gitops: the kubernetes wayGitops: the kubernetes way
Gitops: the kubernetes way
 
Prometheus and Docker (Docker Galway, November 2015)
Prometheus and Docker (Docker Galway, November 2015)Prometheus and Docker (Docker Galway, November 2015)
Prometheus and Docker (Docker Galway, November 2015)
 
OpenTelemetry Introduction
OpenTelemetry Introduction OpenTelemetry Introduction
OpenTelemetry Introduction
 
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
 
初探 OpenTelemetry - 蒐集遙測數據的新標準
初探 OpenTelemetry - 蒐集遙測數據的新標準初探 OpenTelemetry - 蒐集遙測數據的新標準
初探 OpenTelemetry - 蒐集遙測數據的新標準
 
A GitOps Kubernetes Native CICD Solution with Argo Events, Workflows, and CD
A GitOps Kubernetes Native CICD Solution with Argo Events, Workflows, and CDA GitOps Kubernetes Native CICD Solution with Argo Events, Workflows, and CD
A GitOps Kubernetes Native CICD Solution with Argo Events, Workflows, and CD
 
Monitoring Kubernetes with Prometheus
Monitoring Kubernetes with PrometheusMonitoring Kubernetes with Prometheus
Monitoring Kubernetes with Prometheus
 
Kubernetes 101 for Beginners
Kubernetes 101 for BeginnersKubernetes 101 for Beginners
Kubernetes 101 for Beginners
 
Kubernetes Introduction
Kubernetes IntroductionKubernetes Introduction
Kubernetes Introduction
 
Opentelemetry - From frontend to backend
Opentelemetry - From frontend to backendOpentelemetry - From frontend to backend
Opentelemetry - From frontend to backend
 
Gitops Hands On
Gitops Hands OnGitops Hands On
Gitops Hands On
 
Free GitOps Workshop + Intro to Kubernetes & GitOps
Free GitOps Workshop + Intro to Kubernetes & GitOpsFree GitOps Workshop + Intro to Kubernetes & GitOps
Free GitOps Workshop + Intro to Kubernetes & GitOps
 
Kubernetes and Prometheus
Kubernetes and PrometheusKubernetes and Prometheus
Kubernetes and Prometheus
 
GitOps with Gitkube
GitOps with GitkubeGitOps with Gitkube
GitOps with Gitkube
 
Deep Dive into Building a Secure & Multi-tenant SaaS Solution with NATS
Deep Dive into Building a Secure & Multi-tenant SaaS Solution with NATSDeep Dive into Building a Secure & Multi-tenant SaaS Solution with NATS
Deep Dive into Building a Secure & Multi-tenant SaaS Solution with NATS
 
KCD-OpenTelemetry.pdf
KCD-OpenTelemetry.pdfKCD-OpenTelemetry.pdf
KCD-OpenTelemetry.pdf
 

Semelhante a OSMC 2021 | inspectIT Ocelot: Dynamic OpenTelemetry Instrumentation at Runtime

Protractor framework architecture with example
Protractor framework architecture with exampleProtractor framework architecture with example
Protractor framework architecture with exampleshadabgilani
 
Appium Automation with Kotlin
Appium Automation with KotlinAppium Automation with Kotlin
Appium Automation with KotlinRapidValue
 
Mvc interview questions – deep dive jinal desai
Mvc interview questions – deep dive   jinal desaiMvc interview questions – deep dive   jinal desai
Mvc interview questions – deep dive jinal desaijinaldesailive
 
Guide to Generate Extent Report in Kotlin
Guide to Generate Extent Report in KotlinGuide to Generate Extent Report in Kotlin
Guide to Generate Extent Report in KotlinRapidValue
 
Dive into Angular, part 5: Experience
Dive into Angular, part 5: ExperienceDive into Angular, part 5: Experience
Dive into Angular, part 5: ExperienceOleksii Prohonnyi
 
Hadoop cluster performance profiler
Hadoop cluster performance profilerHadoop cluster performance profiler
Hadoop cluster performance profilerIhor Bobak
 
Jdk Tools For Performance Diagnostics
Jdk Tools For Performance DiagnosticsJdk Tools For Performance Diagnostics
Jdk Tools For Performance DiagnosticsDror Bereznitsky
 
Mastering Test Automation: How To Use Selenium Successfully
Mastering Test Automation: How To Use Selenium SuccessfullyMastering Test Automation: How To Use Selenium Successfully
Mastering Test Automation: How To Use Selenium SuccessfullySpringPeople
 
Intoduction to Play Framework
Intoduction to Play FrameworkIntoduction to Play Framework
Intoduction to Play FrameworkKnoldus Inc.
 
Qtp Training
Qtp TrainingQtp Training
Qtp Trainingmehramit
 
Test strategy for web development
Test strategy for web developmentTest strategy for web development
Test strategy for web developmentalice yang
 
Struts 2 Overview
Struts 2 OverviewStruts 2 Overview
Struts 2 Overviewskill-guru
 
What's Coming in Spring 3.0
What's Coming in Spring 3.0What's Coming in Spring 3.0
What's Coming in Spring 3.0Matt Raible
 
Strut2-Spring-Hibernate
Strut2-Spring-HibernateStrut2-Spring-Hibernate
Strut2-Spring-HibernateJay Shah
 

Semelhante a OSMC 2021 | inspectIT Ocelot: Dynamic OpenTelemetry Instrumentation at Runtime (20)

Protractor framework architecture with example
Protractor framework architecture with exampleProtractor framework architecture with example
Protractor framework architecture with example
 
Struts2 - 101
Struts2 - 101Struts2 - 101
Struts2 - 101
 
Appium Automation with Kotlin
Appium Automation with KotlinAppium Automation with Kotlin
Appium Automation with Kotlin
 
Mvc interview questions – deep dive jinal desai
Mvc interview questions – deep dive   jinal desaiMvc interview questions – deep dive   jinal desai
Mvc interview questions – deep dive jinal desai
 
Guide to Generate Extent Report in Kotlin
Guide to Generate Extent Report in KotlinGuide to Generate Extent Report in Kotlin
Guide to Generate Extent Report in Kotlin
 
Angular Js Basics
Angular Js BasicsAngular Js Basics
Angular Js Basics
 
Asp.net mvc
Asp.net mvcAsp.net mvc
Asp.net mvc
 
Dive into Angular, part 5: Experience
Dive into Angular, part 5: ExperienceDive into Angular, part 5: Experience
Dive into Angular, part 5: Experience
 
Struts2 notes
Struts2 notesStruts2 notes
Struts2 notes
 
Hadoop cluster performance profiler
Hadoop cluster performance profilerHadoop cluster performance profiler
Hadoop cluster performance profiler
 
Jdk Tools For Performance Diagnostics
Jdk Tools For Performance DiagnosticsJdk Tools For Performance Diagnostics
Jdk Tools For Performance Diagnostics
 
Struts2 in a nutshell
Struts2 in a nutshellStruts2 in a nutshell
Struts2 in a nutshell
 
Mastering Test Automation: How To Use Selenium Successfully
Mastering Test Automation: How To Use Selenium SuccessfullyMastering Test Automation: How To Use Selenium Successfully
Mastering Test Automation: How To Use Selenium Successfully
 
Intoduction to Play Framework
Intoduction to Play FrameworkIntoduction to Play Framework
Intoduction to Play Framework
 
Qtp Training
Qtp TrainingQtp Training
Qtp Training
 
Struts framework
Struts frameworkStruts framework
Struts framework
 
Test strategy for web development
Test strategy for web developmentTest strategy for web development
Test strategy for web development
 
Struts 2 Overview
Struts 2 OverviewStruts 2 Overview
Struts 2 Overview
 
What's Coming in Spring 3.0
What's Coming in Spring 3.0What's Coming in Spring 3.0
What's Coming in Spring 3.0
 
Strut2-Spring-Hibernate
Strut2-Spring-HibernateStrut2-Spring-Hibernate
Strut2-Spring-Hibernate
 

Último

APVP,apvp apvp High quality supplier safe spot transport, 98% purity
APVP,apvp apvp High quality supplier safe spot transport, 98% purityAPVP,apvp apvp High quality supplier safe spot transport, 98% purity
APVP,apvp apvp High quality supplier safe spot transport, 98% purityamy56318795
 
A Python-based approach to data loading in TM1 - Using Airflow as an ETL for TM1
A Python-based approach to data loading in TM1 - Using Airflow as an ETL for TM1A Python-based approach to data loading in TM1 - Using Airflow as an ETL for TM1
A Python-based approach to data loading in TM1 - Using Airflow as an ETL for TM1KnowledgeSeed
 
IT Software Development Resume, Vaibhav jha 2024
IT Software Development Resume, Vaibhav jha 2024IT Software Development Resume, Vaibhav jha 2024
IT Software Development Resume, Vaibhav jha 2024vaibhav130304
 
INGKA DIGITAL: Linked Metadata by Design
INGKA DIGITAL: Linked Metadata by DesignINGKA DIGITAL: Linked Metadata by Design
INGKA DIGITAL: Linked Metadata by DesignNeo4j
 
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERRORTROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERRORTier1 app
 
KLARNA - Language Models and Knowledge Graphs: A Systems Approach
KLARNA -  Language Models and Knowledge Graphs: A Systems ApproachKLARNA -  Language Models and Knowledge Graphs: A Systems Approach
KLARNA - Language Models and Knowledge Graphs: A Systems ApproachNeo4j
 
Studiovity film pre-production and screenwriting software
Studiovity film pre-production and screenwriting softwareStudiovity film pre-production and screenwriting software
Studiovity film pre-production and screenwriting softwareinfo611746
 
JustNaik Solution Deck (stage bus sector)
JustNaik Solution Deck (stage bus sector)JustNaik Solution Deck (stage bus sector)
JustNaik Solution Deck (stage bus sector)Max Lee
 
Mastering Windows 7 A Comprehensive Guide for Power Users .pdf
Mastering Windows 7 A Comprehensive Guide for Power Users .pdfMastering Windows 7 A Comprehensive Guide for Power Users .pdf
Mastering Windows 7 A Comprehensive Guide for Power Users .pdfmbmh111980
 
Designing for Privacy in Amazon Web Services
Designing for Privacy in Amazon Web ServicesDesigning for Privacy in Amazon Web Services
Designing for Privacy in Amazon Web ServicesKrzysztofKkol1
 
iGaming Platform & Lottery Solutions by Skilrock
iGaming Platform & Lottery Solutions by SkilrockiGaming Platform & Lottery Solutions by Skilrock
iGaming Platform & Lottery Solutions by SkilrockSkilrock Technologies
 
CompTIA Security+ (Study Notes) for cs.pdf
CompTIA Security+ (Study Notes) for cs.pdfCompTIA Security+ (Study Notes) for cs.pdf
CompTIA Security+ (Study Notes) for cs.pdfFurqanuddin10
 
Crafting the Perfect Measurement Sheet with PLM Integration
Crafting the Perfect Measurement Sheet with PLM IntegrationCrafting the Perfect Measurement Sheet with PLM Integration
Crafting the Perfect Measurement Sheet with PLM IntegrationWave PLM
 
AI/ML Infra Meetup | Perspective on Deep Learning Framework
AI/ML Infra Meetup | Perspective on Deep Learning FrameworkAI/ML Infra Meetup | Perspective on Deep Learning Framework
AI/ML Infra Meetup | Perspective on Deep Learning FrameworkAlluxio, Inc.
 
Advanced Flow Concepts Every Developer Should Know
Advanced Flow Concepts Every Developer Should KnowAdvanced Flow Concepts Every Developer Should Know
Advanced Flow Concepts Every Developer Should KnowPeter Caitens
 
How Does XfilesPro Ensure Security While Sharing Documents in Salesforce?
How Does XfilesPro Ensure Security While Sharing Documents in Salesforce?How Does XfilesPro Ensure Security While Sharing Documents in Salesforce?
How Does XfilesPro Ensure Security While Sharing Documents in Salesforce?XfilesPro
 
Breaking the Code : A Guide to WhatsApp Business API.pdf
Breaking the Code : A Guide to WhatsApp Business API.pdfBreaking the Code : A Guide to WhatsApp Business API.pdf
Breaking the Code : A Guide to WhatsApp Business API.pdfMeon Technology
 
A Guideline to Gorgias to to Re:amaze Data Migration
A Guideline to Gorgias to to Re:amaze Data MigrationA Guideline to Gorgias to to Re:amaze Data Migration
A Guideline to Gorgias to to Re:amaze Data MigrationHelp Desk Migration
 
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...Alluxio, Inc.
 

Último (20)

APVP,apvp apvp High quality supplier safe spot transport, 98% purity
APVP,apvp apvp High quality supplier safe spot transport, 98% purityAPVP,apvp apvp High quality supplier safe spot transport, 98% purity
APVP,apvp apvp High quality supplier safe spot transport, 98% purity
 
A Python-based approach to data loading in TM1 - Using Airflow as an ETL for TM1
A Python-based approach to data loading in TM1 - Using Airflow as an ETL for TM1A Python-based approach to data loading in TM1 - Using Airflow as an ETL for TM1
A Python-based approach to data loading in TM1 - Using Airflow as an ETL for TM1
 
IT Software Development Resume, Vaibhav jha 2024
IT Software Development Resume, Vaibhav jha 2024IT Software Development Resume, Vaibhav jha 2024
IT Software Development Resume, Vaibhav jha 2024
 
5 Reasons Driving Warehouse Management Systems Demand
5 Reasons Driving Warehouse Management Systems Demand5 Reasons Driving Warehouse Management Systems Demand
5 Reasons Driving Warehouse Management Systems Demand
 
INGKA DIGITAL: Linked Metadata by Design
INGKA DIGITAL: Linked Metadata by DesignINGKA DIGITAL: Linked Metadata by Design
INGKA DIGITAL: Linked Metadata by Design
 
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERRORTROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
 
KLARNA - Language Models and Knowledge Graphs: A Systems Approach
KLARNA -  Language Models and Knowledge Graphs: A Systems ApproachKLARNA -  Language Models and Knowledge Graphs: A Systems Approach
KLARNA - Language Models and Knowledge Graphs: A Systems Approach
 
Studiovity film pre-production and screenwriting software
Studiovity film pre-production and screenwriting softwareStudiovity film pre-production and screenwriting software
Studiovity film pre-production and screenwriting software
 
JustNaik Solution Deck (stage bus sector)
JustNaik Solution Deck (stage bus sector)JustNaik Solution Deck (stage bus sector)
JustNaik Solution Deck (stage bus sector)
 
Mastering Windows 7 A Comprehensive Guide for Power Users .pdf
Mastering Windows 7 A Comprehensive Guide for Power Users .pdfMastering Windows 7 A Comprehensive Guide for Power Users .pdf
Mastering Windows 7 A Comprehensive Guide for Power Users .pdf
 
Designing for Privacy in Amazon Web Services
Designing for Privacy in Amazon Web ServicesDesigning for Privacy in Amazon Web Services
Designing for Privacy in Amazon Web Services
 
iGaming Platform & Lottery Solutions by Skilrock
iGaming Platform & Lottery Solutions by SkilrockiGaming Platform & Lottery Solutions by Skilrock
iGaming Platform & Lottery Solutions by Skilrock
 
CompTIA Security+ (Study Notes) for cs.pdf
CompTIA Security+ (Study Notes) for cs.pdfCompTIA Security+ (Study Notes) for cs.pdf
CompTIA Security+ (Study Notes) for cs.pdf
 
Crafting the Perfect Measurement Sheet with PLM Integration
Crafting the Perfect Measurement Sheet with PLM IntegrationCrafting the Perfect Measurement Sheet with PLM Integration
Crafting the Perfect Measurement Sheet with PLM Integration
 
AI/ML Infra Meetup | Perspective on Deep Learning Framework
AI/ML Infra Meetup | Perspective on Deep Learning FrameworkAI/ML Infra Meetup | Perspective on Deep Learning Framework
AI/ML Infra Meetup | Perspective on Deep Learning Framework
 
Advanced Flow Concepts Every Developer Should Know
Advanced Flow Concepts Every Developer Should KnowAdvanced Flow Concepts Every Developer Should Know
Advanced Flow Concepts Every Developer Should Know
 
How Does XfilesPro Ensure Security While Sharing Documents in Salesforce?
How Does XfilesPro Ensure Security While Sharing Documents in Salesforce?How Does XfilesPro Ensure Security While Sharing Documents in Salesforce?
How Does XfilesPro Ensure Security While Sharing Documents in Salesforce?
 
Breaking the Code : A Guide to WhatsApp Business API.pdf
Breaking the Code : A Guide to WhatsApp Business API.pdfBreaking the Code : A Guide to WhatsApp Business API.pdf
Breaking the Code : A Guide to WhatsApp Business API.pdf
 
A Guideline to Gorgias to to Re:amaze Data Migration
A Guideline to Gorgias to to Re:amaze Data MigrationA Guideline to Gorgias to to Re:amaze Data Migration
A Guideline to Gorgias to to Re:amaze Data Migration
 
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
 

OSMC 2021 | inspectIT Ocelot: Dynamic OpenTelemetry Instrumentation at Runtime

  • 1. inspectIT Ocelot: Dynamic OpenTelemetry Instrumentation at Runtime Open Source Monitoring Conference 2021
  • 2. The Scenario 2 Is the application working? How many users are accessing it? How long did my task take? How many errors occur? What is its memory footprint? What other applications are called?
  • 3. The Scenario 3 Java Class public Result getQuote(Subject subject) { long start = System.currentTimeMillis(); validate(params); Result result = quoteManager.getQuote(subject); long duration = System.currentTimeMillis() - start; Attributes attributes = create("quote-subject", subject); Observer.record("getQuote", duration, attributes); return result; } Capturing the start time Application logic Calculate the execution time Record the execution time with context information How long did my application take to provide a quote for a car? … getQuote {‘quote-subject’:‘car’} 252ms getQuote {‘quote-subject’:‘bike’} 78ms … It takes 252 milliseconds.
  • 4. Our Goal 4 Java Class public Result getQuote(Subject subject) { long start = System.currentTimeMillis(); validate(params); Result result = quoteManager.getQuote(subject); long duration = System.currentTimeMillis() - start; Attributes attributes = create("quote-subject", subject); Observer.record("getQuote", duration, attributes); return result; } Do we have to do this for each application? But we need something consistent across all applications! How do I get this data into my analysis tool?
  • 6. § Provides uniform standard for telemetry data. § Data can be correlated across systems. § Data can be exported to a variety of analysis tools. What is OpenTelemetry? 6 “OpenTelemetry is a collection of tools, APIs, and SDKs. Use it to instrument, generate, collect, and export telemetry data (metrics, logs, and traces) to help you analyze your software’s performance and behavior.” Source: https://opentelemetry.io/ DATA
  • 7. How is it working? 7 OpenTelemetry API Used to generate telemetry data. OpenTelemetry SDK Implementation of the API OpenTelemetry Extentions / Exporters Additional API extensions, which are not part of the core API. Additional Components E.g.: OTel-Collector, Jaeger, …
  • 8. Manual Instrumentation via OTel API 8 Java Class public Result getQuote(Subject subject) { Span span = tracer.spanBuilder("getQuote").startSpan(); span.setAttribute("quote-subject", subject); try (Scope scope = span.makeCurrent()) { validate(params); return quoteManager.getQuote(subject); } finally { span.end(); } } Collected data is exported using configured OpenTelemetry exporter Application logic Start span and assign data End and record the span Context Propagation Changes need to be made to the source code.
  • 9. § OpenTelemetry Java agent can be used to dynamically injects bytecode to capture telemetry of popular libraries and frameworks. § But: no ability to extract specific data from certain classes. Auto-Instrumentation 9 Java Class public Result getQuote(Subject subject) { validate(params); return quoteManager.getQuote(subject); } Java Class public Result getQuote(Subject subject) { Span span = tracer.spanBuilder("getQuote").startSpan(); span.setAttribute("quote-subject", subject); try (Scope scope = span.makeCurrent()) { validate(params); return quoteManager.getQuote(subject); } finally { span.end(); } } Java agent automatically adds OpenTelemetry instrumentation to classes using Bytecode Instrumentation (BCI) Modified (instrumented) Class Original Class Java Agent Class Transformation
  • 11. § A highly configurable Java agent for collecting telemetry and any (business) data of Java applications. § Instrumentation (injected OpenTelemetry bytecode) can be changed during application runtime. § Pre-configured to capture telemetry data of popular libraries and frameworks. § Utility components that support the use of the agent (e.g. configuration-server). What is inspectIT Ocelot 11 Ocelot Java Agent Configuration Server Managing agents and agent configurations Fetch Configuration http://inspectit.rocks/
  • 12. § The configuration-server provides a simple UI for creating configurations Basic Tracing 12 Easy selection of the methods to be traced with the ”class browser”.
  • 13. Advanced YAML-based Configuration 13 § Configuration determines what the agent does and consists of three basic components: Actions What should the agent do Scopes Where should the agent do something Rules Uses scopes and rules to instruct the agent what to do E.g.: Capture the first method argument E.g.: method “execute” of class “Worker” E.g.: trace the method “execute” of class “worker”, capture the first method argument of it and attach it to the current span
  • 14. Advanced YAML-based Configuration - Tracing Predefined instruction set – trace all methods in the scopes Which scopes should be used Which actions should be executed when a method starts Which data should be recorded Scope Action Rule Result (e.g.: Jaeger):
  • 15. Advanced YAML-based Configuration - Metrics Which scopes should be used Which actions should be executed when a method starts Use the recorded data as a metric’s value and export it Scope Action Rule Result (e.g. Prometheus):
  • 16. Let's see it in action! 16
  • 17. § Check out the talk “Open Source Application Performance Monitoring in the Enterprise” by Sascha Brechmann of VHV Versicherung Real-World Usage of inspectIT Ocelot 17
  • 18. Novatec Consulting GmbH Bertha-Benz-Platz 1 D-70771 Leinfelden-Echterdingen T. +49 711 22040-700 info@novatec-gmbh.de www.novatec-gmbh.de 18 Senior Consultant Marius Oehler E-Mail: marius.oehler@novatec-gmbh.de