Skip to content

Latest commit

 

History

History
220 lines (171 loc) · 8.55 KB

README.md

File metadata and controls

220 lines (171 loc) · 8.55 KB

otel-photo OpenTelemetry Demo

Slack Version Commits Downloads License

Under Construction

This repo is a work in progress. If you'd like to help, check out our contributing guidance.

Getting Started

Documentation

Architecture

Online Boutique is composed of microservices written in different programming languages that talk to each other over gRPC and HTTP; and a load generator which uses Locust to fake user traffic.

graph TD

subgraph Service Diagram
adservice(Ad Service):::java
cache[(Cache<br/>&#40redis&#41)]
cartservice(Cart Service):::dotnet
checkoutservice(Checkout Service):::golang
currencyservice(Currency Service):::cpp
emailservice(Email Service):::ruby
frontend(Frontend):::javascript
loadgenerator([Load Generator]):::python
paymentservice(Payment Service):::javascript
productcatalogservice(ProductCatalog Service):::golang
recommendationservice(Recommendation Service):::python
shippingservice(Shipping Service):::rust
featureflagservice(Feature Flag Service):::erlang
featureflagstore[(Feature Flag Store<br/>&#40PostgreSQL DB&#41)]

Internet -->|HTTP| frontend
loadgenerator -->|HTTP| frontend

checkoutservice --> cartservice --> cache
checkoutservice --> productcatalogservice
checkoutservice --> currencyservice
checkoutservice -->|HTTP| emailservice
checkoutservice --> paymentservice
checkoutservice --> shippingservice

frontend --> adservice
frontend --> cartservice
frontend --> productcatalogservice
frontend --> checkoutservice
frontend --> currencyservice
frontend --> recommendationservice --> productcatalogservice
frontend --> shippingservice

productcatalogservice --> |evalFlag| featureflagservice

shippingservice --> |evalFlag| featureflagservice

featureflagservice --> featureflagstore

end
classDef java fill:#b07219,color:white;
classDef dotnet fill:#178600,color:white;
classDef golang fill:#00add8,color:black;
classDef cpp fill:#f34b7d,color:white;
classDef ruby fill:#701516,color:white;
classDef python fill:#3572A5,color:white;
classDef javascript fill:#f1e05a,color:black;
classDef rust fill:#dea584,color:black;
classDef erlang fill:#b83998,color:white;
classDef php fill:#4f5d95,color:white;
Loading
graph TD
subgraph Service Legend
  javasvc(Java):::java
  dotnetsvc(.NET):::dotnet
  golangsvc(Go):::golang
  cppsvc(C++):::cpp
  rubysvc(Ruby):::ruby
  pythonsvc(Python):::python
  javascriptsvc(JavaScript):::javascript
  rustsvc(Rust):::rust
  erlangsvc(Erlang/Elixir):::erlang
end

classDef java fill:#b07219,color:white;
classDef dotnet fill:#178600,color:white;
classDef golang fill:#00add8,color:black;
classDef cpp fill:#f34b7d,color:white;
classDef ruby fill:#701516,color:white;
classDef python fill:#3572A5,color:white;
classDef javascript fill:#f1e05a,color:black;
classDef rust fill:#dea584,color:black;
classDef erlang fill:#b83998,color:white;
classDef php fill:#4f5d95,color:white;
Loading

Find the Protocol Buffer Definitions in the /pb/ directory.

Features

  • Kubernetes: the app is designed to run on Kubernetes (both locally , as well as on the cloud).
  • Docker: this forked sample can also be executed only with Docker.
  • gRPC: microservices use a high volume of gRPC calls to communicate to each other.
  • OpenTelemetry Traces: all services are instrumented using OpenTelemetry available instrumentation libraries.
  • OpenTelemetry Collector: all services are instrumented and sending the generated traces to the OpenTelemetry Collector via gRPC. The received traces are then exported to the logs and to Jaeger.
  • Jaeger: all generated traces are being sent to Jaeger.
  • Synthetic Load Generation: the application demo comes with a background job that creates realistic usage patterns on the website using Locust load generator.
  • Prometheus: all generated metrics are being sent to Prometheus.
  • Grafana: all metric dashboards are stored in Grafana.

Demos featuring Online Boutique

Contributing

See CONTRIBUTING.md

We meet weekly Monday's at 8:15 AM PT. The meeting is subject to change depending on contributors' availability. Check the OpenTelemetry community calendar for specific dates and Zoom meeting links.

Meeting notes are available as a public Google doc. For edit access, get in touch on Slack.

Maintainers (@open-telemetry/demo-maintainers):

Approvers (@open-telemetry/demo-approvers):

Thanks to all the people who have contributed

contributors

Pyroscope Additions

Adding pyroscope ebpf cluster-wide profiling to your k8s cluster

First, make sure to update API KEY in ebpf-values.yml file. You can get the key here.

make install-pyroscope-ebpf

Adding pyroscope to checkoutservice

# this will create docker images and push them to your registry
# you may have to change .dockerenv file to make this work with your registry
make build-and-push-dockerhub

# this will update the service in k8s:
# it assumes that you have helm charts in an adjacent directory
# and charts are modified to allow for port 6060 to be exposed
# see commits in https://github.com/pyroscope-io/opentelemetry-helm-charts
helm upgrade my-otel-demo ../opentelemetry-helm-charts/charts/opentelemetry-demo/

Installing pyroscope server to run in your k8s cluster and collect profilng data from checkoutservice

First, make sure to update API KEY in pyroscope-server-values.yml file. You can get the key here.

make install-pyroscope-server