Skip to content

ValManP/grpc-go-distributed-tracing-example

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

grpc-go-distributed-tracing-example

Small example of distributed tracing in grpc-go applications. Using OpenCensus for collecting traces data and Jaeger for export.

Overview

Example has 3 parts.

Client:

  • reads "radius" from console
  • calls "Circle.area" grpc method to calculate an area of a circle with given radius

Circle:

  • Circle.area calls Math.sqr grpc method to calculate the radius squared
  • Circle.area returns value of area

Math:

  • Math.sqr returns the radius squared

Prerequisites

  1. Start Jaeger Exporter locally in Docker
docker run -d --name jaeger \
  -p 16686:16686 \
  -p 14268:14268 \
  jaegertracing/all-in-one:1.22
  • 16686 - Jaeger UI port
  • 14268 - Collector port
  1. Run main func of each part
  2. See your traces in http://localhost:16686/

Example

example

Releases

No releases published

Packages

No packages published

Languages