Skip to content

smiletrl/go_jaeger_tracing

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Go tracing

This is an example for jaeger tracing in go for micro services. It assumes Jaeger has been installed already (at kubernetes, or no-k8s env), and you are already familiar with Opentracing.

You might want to tweak the variables defined at pkg/constants, depending on your installment.

This repository shows tracing for restful request, grpc server request, and custom function(such as database connection/request).

Key points:

You might want to check the full example at repository micro ecommerce.

See the demo result like

Jaeger UI Jaeger UI

Commands

Test Post command

curl --header "Content-Type: application/json" \
  --request POST \
  --data '{"sku_id":"12","quantity":1}' \
  http://127.0.0.1:1325/cart

Proto Update

cd service.product/internal

protoc --go_out=. --go_opt=paths=source_relative \
    --go-grpc_out=. --go-grpc_opt=paths=source_relative \
    proto/product.proto

About

jaeger tracing example for golang micro service

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published