Giter Site home page Giter Site logo

debajitdas / opentelemetry-demo-webstore Goto Github PK

View Code? Open in Web Editor NEW

This project forked from open-telemetry/opentelemetry-demo

0.0 0.0 0.0 26.89 MB

OpenTelemetry Community Demo Application

License: Apache License 2.0

Shell 0.21% JavaScript 1.99% Ruby 0.24% Python 2.13% Erlang 61.88% Java 1.52% Go 4.18% C# 2.83% Elixir 6.65% CSS 1.64% Makefile 0.22% HTML 0.83% Batchfile 0.02% Dockerfile 1.99% CMake 0.37% C++ 1.84% Rust 1.29% TypeScript 10.17%

opentelemetry-demo-webstore's Introduction

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.

Local Quickstart

Docker

Pre-requisites

Clone Repo

  • Clone the Webstore Demo repository:
git clone https://github.com/open-telemetry/opentelemetry-demo.git

Open Folder

  • Navigate to the cloned folder:
cd opentelemetry-demo/

Run Docker Compose

  • Start the demo (It can take ~20min the first time the command is executed as all the images will be build):
docker compose up

Verify the Webstore & the Telemetry

Once the images are built and containers are started you can access:

Bring your own backend

Likely you want to use the Webstore as a demo application for an observability backend you already have (e.g. an existing instance of Jaeger, Zipkin or one of the vendor of your choice.

To add your backend open the file src/otelcollector/otelcol-config.yml with an editor:

  • add a trace exporter for your backend. For example, if your backend supports otlp, extend the exporters section like the following:
exporters:
  jaeger:
    endpoint: "jaeger:14250"
    insecure: true
  logging:
  otlp:
    endpoint: <your-endpoint-url>
  • add the otlp exporter to the pipelines section as well:
service:
  pipelines:
    traces:
      receivers: [otlp]
      processors: [batch]
      exporters: [logging, jaeger, otlp]

Vendor backends might require you to add additional parameters for authentication, please check their documentation. Some backends require different exporters, you may find them and their documentation available at opentelemetry-collector-contrib/exporter.

After updating the otelcol-config.yml start the demo by running docker compose up. After a while you should see the traces flowing into your backend as well.

Kubernetes

We provide a OpenTelemetry Demo Helm chart to help deploy the demo to an existing Kubernetes cluster.

Helm must be installed to use the charts. Please refer to Helm's documentation to get started.

Prerequisites

  • Pre-existing Kubernetes Cluster
  • Helm 3.0+

Install the Chart

Add OpenTelemetry Helm repository:

helm repo add open-telemetry https://open-telemetry.github.io/opentelemetry-helm-charts

To install the chart with the release name my-otel-demo, run the following command:

helm install my-otel-demo open-telemetry/opentelemetry-demo

Screenshots from the Online Boutique

Home Page Checkout Screen
Screenshot of store homepage Screenshot of checkout screen

Screenshots from Jaeger

Jaeger UI Trace View
Screenshot of Jaeger UI Screenshot of Trace View

Architecture

Online Boutique is composed of microservices written in different programming languages that talk to each other over gRPC. Plus one 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):::golang
loadgenerator([Load Generator]):::python
paymentservice(Payment Service):::nodejs
productcatalogservice(ProductCatalog Service):::golang
recommendationservice(Recommendation Service):::python
shippingservice(Shipping Service):::rust

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

checkoutservice --> cartservice --> cache
checkoutservice --> productcatalogservice
checkoutservice --> currencyservice
checkoutservice --> emailservice
checkoutservice --> paymentservice
checkoutservice --> shippingservice
checkoutservice --> |evalFlag| featureflagfeservice

frontend --> adservice
frontend --> cartservice
frontend --> productcatalogservice
frontend --> checkoutservice
frontend --> currencyservice
frontend --> recommendationservice --> productcatalogservice
frontend --> shippingservice
frontend --> |evalFlag| featureflagfeservice

productcatalogservice --> |evalFlag| featureflagfeservice

featureflagbeservice(Flag Server):::erlang
featureflagfeservice(Flag UI/API):::erlang
featureflagstore[(Flag Store<br/>&#40PostgreSQL DB&#41)]

featureflagfeservice --> featureflagbeservice --> 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 nodejs fill:#f1e05a,color:black;
classDef rust fill:#dea584,color:black;
classDef erlang fill:#b83998,color:white;
classDef php fill:#4f5d95,color:white;
graph TD
subgraph Service Legend
  javasvc(Java):::java
  dotnetsvc(.NET):::dotnet
  golangsvc(Go):::golang
  cppsvc(C++):::cpp
  rubysvc(Ruby):::ruby
  pythonsvc(Python):::python
  nodesvc(Node.js):::nodejs
  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 nodejs fill:#f1e05a,color:black;
classDef rust fill:#dea584,color:black;
classDef erlang fill:#b83998,color:white;
classDef php fill:#4f5d95,color:white;

To view a graph of the desired state of this application click here

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

opentelemetry-demo-webstore's People

Contributors

cartersocha avatar mic-max avatar puckpuck avatar reyang avatar fatsheep9146 avatar wph95 avatar tsloughter avatar julianocosta89 avatar ahayworth avatar xoscar avatar frapschen avatar cedricziel avatar dependabot[bot] avatar maciej-szlosarczyk avatar jaredtan95 avatar garypwhite avatar dineshg13 avatar arminru avatar austinlparker avatar cijothomas avatar debajitdas avatar dmitryax avatar lalitb avatar mviitane avatar svrnm avatar tigrannajaryan avatar ymtdzzz avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.