SlideShare a Scribd company logo
1 of 66
Z I P K I N
A distributed tracing framework
Why Zipkin?
Google



0.5 sec slower



20% traffic drop


                  @skr | @thisisfranklin   3
Google



0.5 sec slower    1.5 sec faster



20% traffic drop   CTR up 12%


                               @skr | @thisisfranklin   3
Performance matters
Front end




            @skr | @thisisfranklin   5
Front end   Back end




                   @skr | @thisisfranklin   5
@skr | @thisisfranklin   6
@skr | @thisisfranklin   6
@skr | @thisisfranklin   7
@skr | @thisisfranklin   8
Picture from http://www.flickr.com/photos/jpellgen
@skr | @thisisfranklin   9
• Collects traces from production requests
• Low overhead
• Minimum of extra work for developers




                                             @skr | @thisisfranklin   9
Finagle
“Finagle is an asynchronous network stack for the JVM that you can use to build
asynchronous Remote Procedure Call (RPC) clients and servers in Java, Scala, or
any JVM-hosted language.”


                         github.com/twitter/finagle
@skr | @thisisfranklin   11
Finagle Http service




                       @skr | @thisisfranklin   11
Finagle Http service




                       @skr | @thisisfranklin   11
Finagle Http service



Finagle Thrift Service




                                          @skr | @thisisfranklin   11
Finagle Http service



Finagle Thrift Service




                                          @skr | @thisisfranklin   11
Finagle Http service



Finagle Thrift Service




                                          @skr | @thisisfranklin   11
Finagle Http service



Finagle Thrift Service                Service




                                                @skr | @thisisfranklin   11
Finagle Http service



Finagle Thrift Service                Service




                                                @skr | @thisisfranklin   11
Finagle Http service



Finagle Thrift Service                Service




                                                @skr | @thisisfranklin   11
Zipkin terminology
‣   Annotation: string data associated with a particular timestamp, service, and
    host


                                        Time



         time: 2012-01-21 22:37:01
         value: “something happened”
         server: 135.34.53.2
         service: “timelineservice”




                                                                           @skr | @thisisfranklin   12
‣   Span: represents one specific method call; made up of a set of annotations.
    Has a name and an id.
                                        Time

         T:0ms Client Send



                                        Span




                                                                           @skr | @thisisfranklin   13
‣   Span: represents one specific method call; made up of a set of annotations.
    Has a name and an id.
                                        Time

         T:0ms Client Send



                                        Span


             T:10ms Server Receive




                                                                           @skr | @thisisfranklin   13
‣   Span: represents one specific method call; made up of a set of annotations.
    Has a name and an id.
                                        Time

         T:0ms Client Send



                                        Span


             T:10ms Server Receive                        T:90ms Server Send




                                                                               @skr | @thisisfranklin   13
‣   Span: represents one specific method call; made up of a set of annotations.
    Has a name and an id.
                                        Time

         T:0ms Client Send                               T:100ms Client Receive



                                        Span


             T:10ms Server Receive                        T:90ms Server Send




                                                                                  @skr | @thisisfranklin   13
‣   Span: represents one specific method call; made up of a set of annotations.
    Has a name and an id.
                                               Time

         T:0ms Client Send                                            T:100ms Client Receive



                                               Span

                                     T:20ms Read 30 kbytes from file
             T:10ms Server Receive                                     T:90ms Server Send




                                                                                               @skr | @thisisfranklin   13
‣   Span: represents one specific method call; made up of a set of annotations.
    Has a name and an id.
                                               Time

         T:0ms Client Send                                            T:100ms Client Receive



                                               Span

                                     T:20ms Read 30 kbytes from file
             T:10ms Server Receive                                     T:90ms Server Send



‣   Trace: a set of spans all associated with the same request


                                                                                               @skr | @thisisfranklin   13
Finagle
 http
service




          @skr | @thisisfranklin   14
• Generate a random i64 trace id
                                   Finagle
                                    http
                                   service




                                             @skr | @thisisfranklin   14
• Generate a random i64 trace id
• Decide if we should sample the
trace or not                       Finagle
                                    http
                                   service




                                             @skr | @thisisfranklin   14
• Generate a random i64 trace id
• Decide if we should sample the
trace or not                       Finagle
                                    http
                                   service




                                   Finagle
                                    thrift
                                   service



                                             @skr | @thisisfranklin   14
• Generate a random i64 trace id
• Decide if we should sample the
trace or not                       Finagle
                                    http
                                   service

• Generate new span id


                                   Finagle
                                    thrift
                                   service



                                             @skr | @thisisfranklin   14
• Generate a random i64 trace id
• Decide if we should sample the
trace or not                       Finagle
                                    http
                                   service

• Generate new span id
• Pass trace header

                                   Finagle
                                    thrift
                                   service



                                             @skr | @thisisfranklin   14
• Generate a random i64 trace id
• Decide if we should sample the
trace or not                       Finagle
                                    http     struct RequestHeader {
                                   service     i64 trace_id,
                                               i64 span_id,
• Generate new span id                         optional i64 parent_span_id,
• Pass trace header
                                               optional bool sampled
                                             }
                                   Finagle
                                    thrift
                                   service



                                                                 @skr | @thisisfranklin   14
• Generate a random i64 trace id
• Decide if we should sample the
trace or not                            Finagle
                                         http     struct RequestHeader {
                                        service     i64 trace_id,
                                                    i64 span_id,
• Generate new span id                              optional i64 parent_span_id,
• Pass trace header
                                                    optional bool sampled
                                                  }
                                        Finagle
• Thrift service adopts trace id from    thrift
header if it exists                     service



                                                                      @skr | @thisisfranklin   14
Finagle
 http
service




Finagle
 thrift
service




          @skr | @thisisfranklin   14
Finagle
           http
          service




Finagle   Finagle
 thrift    thrift
service   service




                    @skr | @thisisfranklin   14
Finagle
           http
          service




Finagle   Finagle
 thrift    thrift
service   service



                    Finagle
                     thrift
                    service

                              @skr | @thisisfranklin   14
Finagle
            http
          service
          S




Finagle   Finagle
 thrift    thrift
S
service   service
          S



                    Finagle
                     thrift
                    S
                    service

                              @skr | @thisisfranklin   14
Finagle
            http
          service
          S

                               Zipkin
                              collector


Finagle   Finagle
 thrift    thrift
S
service   service
          S
                              Cassandra


                    Finagle
                     thrift
                    S
                    service

                                          @skr | @thisisfranklin   14
Finagle
            http
          service
          S

                               Zipkin
                              collector


Finagle   Finagle
 thrift    thrift
S
service   service
          S                               Zipkin        Zipkin
                              Cassandra
                                          Query           UI

                    Finagle
                     thrift
                    S
                    service

                                                   @skr | @thisisfranklin   14
Finagle ♥ Zipkin
Finagle Thrift server

       ServerBuilder()
        .bindTo(address)
        .codec(ThriftServerFramedCodec())
        .name("servicename")
        .build(someService)




                                            @skr | @thisisfranklin   16
Finagle Thrift server

       ServerBuilder()
        .bindTo(address)
        .codec(ThriftServerFramedCodec())
        .name("servicename")
        .build(someService)




                                            @skr | @thisisfranklin   16
Finagle Thrift server

       ServerBuilder()
        .bindTo(address)
        .codec(ThriftServerFramedCodec())
        .name("servicename")
        .build(someService)




                                            @skr | @thisisfranklin   16
Finagle Thrift server

       ServerBuilder()
        .bindTo(address)
        .codec(ThriftServerFramedCodec())
        .name("servicename")
        .build(someService)




                                            @skr | @thisisfranklin   16
Finagle Http server

       ServerBuilder()
        .bindTo(address)
        .codec(Http())
        .name("servicename")
        .build(someService)




                               @skr | @thisisfranklin   17
ServerBuilder()
 .bindTo(address)
 .codec(ThriftServerFramedCodec())
 .name("servicename")
 .tracerFactory(ZipkinTracer())
 .build(someService)




                                     @skr | @thisisfranklin   18
ClientBuilder()
 .cluster(hosts)
 .codec(ThriftServerFramedCodec())
 .name("clientname")
 .tracerFactory(ZipkinTracer())
 .build(someService)




                                     @skr | @thisisfranklin   19
Trace.record("doing stuff")




                              @skr | @thisisfranklin   20
Trace.record("doing stuff")




                              @skr | @thisisfranklin   20
Trace.record("doing stuff")



   time: 2012-01-21 22:37:01
   value: “doing stuff”
   server: 135.34.53.2
   service: “timelineservice”




                                @skr | @thisisfranklin   20
Trace.recordBinary("key", data)




                                  @skr | @thisisfranklin   21
Key           Value


Trace.recordBinary("key", data)   responsecode       500


                                  cache:somekey      Hit


                                    sql.query     select *...



                                                      @skr | @thisisfranklin   21
Platform    Protocol   Client   Server
 Finagle     Thrift     Yes      Yes
 Finagle     HTTP       Yes      Yes
 Finagle    Memcache    Yes      No
 Finagle     Redis      Yes      No
 Cassie      Thrift     Yes      No
Querulous    JDBC       Yes      No
  Ruby       Thrift     Yes      Yes
                                       @skr | @thisisfranklin   22
Zipkin UI
@skr | @thisisfranklin   24
@skr | @thisisfranklin   24
@skr | @thisisfranklin   24
What did we find?
github.com/twitter/zipkin
     @zipkinproject
                            @skr | @thisisfranklin   27

More Related Content

Recently uploaded

Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...apidays
 
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
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century educationjfdjdjcjdnsjd
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024The Digital Insurer
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherRemote DBA Services
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAndrey Devyatkin
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Jeffrey Haguewood
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu SubbuApidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbuapidays
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...Zilliz
 
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
 
A Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusA Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusZilliz
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024The Digital Insurer
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businesspanagenda
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CVKhem
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 

Recently uploaded (20)

Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
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...
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu SubbuApidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
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...
 
A Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusA Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source Milvus
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 

Featured

Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTExpeed Software
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsPixeldarts
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthThinkNow
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfmarketingartwork
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024Neil Kimberley
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)contently
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024Albert Qian
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsKurio // The Social Media Age(ncy)
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Search Engine Journal
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summarySpeakerHub
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next Tessa Mero
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentLily Ray
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best PracticesVit Horky
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project managementMindGenius
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...RachelPearson36
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Applitools
 

Featured (20)

Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
 

Zipkin - Runtime open house

  • 1. Z I P K I N A distributed tracing framework
  • 3. Google 0.5 sec slower 20% traffic drop @skr | @thisisfranklin 3
  • 4. Google 0.5 sec slower 1.5 sec faster 20% traffic drop CTR up 12% @skr | @thisisfranklin 3
  • 6. Front end @skr | @thisisfranklin 5
  • 7. Front end Back end @skr | @thisisfranklin 5
  • 11. @skr | @thisisfranklin 8 Picture from http://www.flickr.com/photos/jpellgen
  • 13. • Collects traces from production requests • Low overhead • Minimum of extra work for developers @skr | @thisisfranklin 9
  • 14. Finagle “Finagle is an asynchronous network stack for the JVM that you can use to build asynchronous Remote Procedure Call (RPC) clients and servers in Java, Scala, or any JVM-hosted language.” github.com/twitter/finagle
  • 16. Finagle Http service @skr | @thisisfranklin 11
  • 17. Finagle Http service @skr | @thisisfranklin 11
  • 18. Finagle Http service Finagle Thrift Service @skr | @thisisfranklin 11
  • 19. Finagle Http service Finagle Thrift Service @skr | @thisisfranklin 11
  • 20. Finagle Http service Finagle Thrift Service @skr | @thisisfranklin 11
  • 21. Finagle Http service Finagle Thrift Service Service @skr | @thisisfranklin 11
  • 22. Finagle Http service Finagle Thrift Service Service @skr | @thisisfranklin 11
  • 23. Finagle Http service Finagle Thrift Service Service @skr | @thisisfranklin 11
  • 24. Zipkin terminology ‣ Annotation: string data associated with a particular timestamp, service, and host Time time: 2012-01-21 22:37:01 value: “something happened” server: 135.34.53.2 service: “timelineservice” @skr | @thisisfranklin 12
  • 25. Span: represents one specific method call; made up of a set of annotations. Has a name and an id. Time T:0ms Client Send Span @skr | @thisisfranklin 13
  • 26. Span: represents one specific method call; made up of a set of annotations. Has a name and an id. Time T:0ms Client Send Span T:10ms Server Receive @skr | @thisisfranklin 13
  • 27. Span: represents one specific method call; made up of a set of annotations. Has a name and an id. Time T:0ms Client Send Span T:10ms Server Receive T:90ms Server Send @skr | @thisisfranklin 13
  • 28. Span: represents one specific method call; made up of a set of annotations. Has a name and an id. Time T:0ms Client Send T:100ms Client Receive Span T:10ms Server Receive T:90ms Server Send @skr | @thisisfranklin 13
  • 29. Span: represents one specific method call; made up of a set of annotations. Has a name and an id. Time T:0ms Client Send T:100ms Client Receive Span T:20ms Read 30 kbytes from file T:10ms Server Receive T:90ms Server Send @skr | @thisisfranklin 13
  • 30. Span: represents one specific method call; made up of a set of annotations. Has a name and an id. Time T:0ms Client Send T:100ms Client Receive Span T:20ms Read 30 kbytes from file T:10ms Server Receive T:90ms Server Send ‣ Trace: a set of spans all associated with the same request @skr | @thisisfranklin 13
  • 31. Finagle http service @skr | @thisisfranklin 14
  • 32. • Generate a random i64 trace id Finagle http service @skr | @thisisfranklin 14
  • 33. • Generate a random i64 trace id • Decide if we should sample the trace or not Finagle http service @skr | @thisisfranklin 14
  • 34. • Generate a random i64 trace id • Decide if we should sample the trace or not Finagle http service Finagle thrift service @skr | @thisisfranklin 14
  • 35. • Generate a random i64 trace id • Decide if we should sample the trace or not Finagle http service • Generate new span id Finagle thrift service @skr | @thisisfranklin 14
  • 36. • Generate a random i64 trace id • Decide if we should sample the trace or not Finagle http service • Generate new span id • Pass trace header Finagle thrift service @skr | @thisisfranklin 14
  • 37. • Generate a random i64 trace id • Decide if we should sample the trace or not Finagle http struct RequestHeader { service i64 trace_id, i64 span_id, • Generate new span id optional i64 parent_span_id, • Pass trace header optional bool sampled } Finagle thrift service @skr | @thisisfranklin 14
  • 38. • Generate a random i64 trace id • Decide if we should sample the trace or not Finagle http struct RequestHeader { service i64 trace_id, i64 span_id, • Generate new span id optional i64 parent_span_id, • Pass trace header optional bool sampled } Finagle • Thrift service adopts trace id from thrift header if it exists service @skr | @thisisfranklin 14
  • 39. Finagle http service Finagle thrift service @skr | @thisisfranklin 14
  • 40. Finagle http service Finagle Finagle thrift thrift service service @skr | @thisisfranklin 14
  • 41. Finagle http service Finagle Finagle thrift thrift service service Finagle thrift service @skr | @thisisfranklin 14
  • 42. Finagle http service S Finagle Finagle thrift thrift S service service S Finagle thrift S service @skr | @thisisfranklin 14
  • 43. Finagle http service S Zipkin collector Finagle Finagle thrift thrift S service service S Cassandra Finagle thrift S service @skr | @thisisfranklin 14
  • 44. Finagle http service S Zipkin collector Finagle Finagle thrift thrift S service service S Zipkin Zipkin Cassandra Query UI Finagle thrift S service @skr | @thisisfranklin 14
  • 46. Finagle Thrift server ServerBuilder() .bindTo(address) .codec(ThriftServerFramedCodec()) .name("servicename") .build(someService) @skr | @thisisfranklin 16
  • 47. Finagle Thrift server ServerBuilder() .bindTo(address) .codec(ThriftServerFramedCodec()) .name("servicename") .build(someService) @skr | @thisisfranklin 16
  • 48. Finagle Thrift server ServerBuilder() .bindTo(address) .codec(ThriftServerFramedCodec()) .name("servicename") .build(someService) @skr | @thisisfranklin 16
  • 49. Finagle Thrift server ServerBuilder() .bindTo(address) .codec(ThriftServerFramedCodec()) .name("servicename") .build(someService) @skr | @thisisfranklin 16
  • 50. Finagle Http server ServerBuilder() .bindTo(address) .codec(Http()) .name("servicename") .build(someService) @skr | @thisisfranklin 17
  • 51. ServerBuilder() .bindTo(address) .codec(ThriftServerFramedCodec()) .name("servicename") .tracerFactory(ZipkinTracer()) .build(someService) @skr | @thisisfranklin 18
  • 52. ClientBuilder() .cluster(hosts) .codec(ThriftServerFramedCodec()) .name("clientname") .tracerFactory(ZipkinTracer()) .build(someService) @skr | @thisisfranklin 19
  • 53. Trace.record("doing stuff") @skr | @thisisfranklin 20
  • 54. Trace.record("doing stuff") @skr | @thisisfranklin 20
  • 55. Trace.record("doing stuff") time: 2012-01-21 22:37:01 value: “doing stuff” server: 135.34.53.2 service: “timelineservice” @skr | @thisisfranklin 20
  • 56. Trace.recordBinary("key", data) @skr | @thisisfranklin 21
  • 57. Key Value Trace.recordBinary("key", data) responsecode 500 cache:somekey Hit sql.query select *... @skr | @thisisfranklin 21
  • 58. Platform Protocol Client Server Finagle Thrift Yes Yes Finagle HTTP Yes Yes Finagle Memcache Yes No Finagle Redis Yes No Cassie Thrift Yes No Querulous JDBC Yes No Ruby Thrift Yes Yes @skr | @thisisfranklin 22
  • 63.
  • 64.
  • 65. What did we find?
  • 66. github.com/twitter/zipkin @zipkinproject @skr | @thisisfranklin 27

Editor's Notes

  1. Talk more about what tracing is. Compare in process profiling to distributed system?\n
  2. Before we get into what Zipkin is: why we created it\n
  3. Shit is slow, you lose users and money\n
  4. \n
  5. Simplify wildly, there are two parts to web performance\nFront end. The order assets are loaded, minifying and other tricsk\nBack end. How quickly can we generate and push out the HTML/JSON/whatever\n
  6. For the front end we have these nice development tools. Shows us how the assets loaded, what it was waiting for and so on.\nWe want a fancy tool like this for the backend.\nPicked a page where server side was unusually bad, normally it’s mostly FE\n
  7. For the back end we only had these graphs to look at per service.\nNothing that ties them together\n
  8. Capture information about how services in a datacentre is working together to respond to a request. \n
  9. Read this paper from Google called Dapper\n
  10. Read this paper from Google called Dapper\n
  11. \n
  12. \n
  13. \n
  14. \n
  15. \n
  16. \n
  17. \n
  18. \n
  19. \n
  20. \n
  21. \n
  22. \n
  23. \n
  24. \n
  25. \n
  26. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  27. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  28. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  29. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  30. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  31. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  32. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  33. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  34. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  35. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  36. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  37. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  38. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  39. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  40. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  41. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  42. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  43. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  44. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  45. Mention that Cassandra and Scribe can both be replaced. Zookeeper coordination?\n
  46. \n
  47. Mention dependency on finagle-zipkin\n
  48. Mention dependency on finagle-zipkin\n
  49. Mention dependency on finagle-zipkin\n
  50. Mention dependency on finagle-zipkin\n
  51. Mention dependency on finagle-zipkin\n
  52. \n
  53. \n
  54. \n
  55. \n
  56. \n
  57. \n
  58. \n
  59. \n
  60. \n
  61. Trace view\nServices on the left. Time scale on top. Least impactful parts of trace collapsed automatically.\nMention bootstrap and dj\n
  62. \n
  63. It’s all open source, check it out now.\n