Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/main'
Browse files Browse the repository at this point in the history
  • Loading branch information
dineshg13 committed Jul 25, 2023
2 parents 50d5c29 + 436a96e commit a54beed
Show file tree
Hide file tree
Showing 51 changed files with 3,427 additions and 2,308 deletions.
138 changes: 138 additions & 0 deletions .github/workflows/build-images.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,138 @@
# Copyright The OpenTelemetry Authors
# SPDX-License-Identifier: Apache-2.0
on:
workflow_call:
inputs:
push:
description: Should the images be pushed
default: false
required: false
type: boolean
version:
description: The version used when tagging the image
default: dev
required: false
type: string

jobs:
build_and_push_images:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write

env:
RELEASE_VERSION: "${{ github.event.release.tag_name }}"
DOCKERHUB_REPO: "otel/demo"
GHCR_REPO: "ghcr.io/open-telemetry/demo"

strategy:
fail-fast: false
matrix:
file_tag:
- file: ./src/adservice/Dockerfile
tag_suffix: adservice
context: ./
- file: ./src/cartservice/src/Dockerfile
tag_suffix: cartservice
context: ./
- file: ./src/checkoutservice/Dockerfile
tag_suffix: checkoutservice
context: ./
- file: ./src/currencyservice/Dockerfile
tag_suffix: currencyservice
context: ./src/currencyservice
- file: ./src/emailservice/Dockerfile
tag_suffix: emailservice
context: ./src/emailservice
# TODO: https://github.com/open-telemetry/opentelemetry-demo/issues/956
# - file: ./src/featureflagservice/Dockerfile
# tag_suffix: featureflagservice
# context: ./
- file: ./src/frontend/Dockerfile
tag_suffix: frontend
context: ./
- file: ./src/frontendproxy/Dockerfile
tag_suffix: frontendproxy
context: ./
- file: ./src/loadgenerator/Dockerfile
tag_suffix: loadgenerator
context: ./
- file: ./src/otelcollector/Dockerfile
tag_suffix: otelcollector
context: ./
- file: ./src/paymentservice/Dockerfile
tag_suffix: paymentservice
context: ./
- file: ./src/productcatalogservice/Dockerfile
tag_suffix: productcatalogservice
context: ./
- file: ./src/quoteservice/Dockerfile
tag_suffix: quoteservice
context: ./
- file: ./src/shippingservice/Dockerfile
tag_suffix: shippingservice
context: ./
- file: ./src/recommendationservice/Dockerfile
tag_suffix: recommendationservice
context: ./
- file: ./src/kafka/Dockerfile
tag_suffix: kafka
context: ./
- file: ./src/accountingservice/Dockerfile
tag_suffix: accountingservice
context: ./
- file: ./src/frauddetectionservice/Dockerfile
tag_suffix: frauddetectionservice
context: ./
- file: ./src/frontend/Dockerfile.cypress
tag_suffix: frontend-tests
context: ./
- file: ./test/Dockerfile
tag_suffix: integrationTests
context: ./

steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Log in to the Container registry
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
if: ${{ inputs.push }}

- name: Log in to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
if: ${{ inputs.push }}

- name: Set up QEMU
uses: docker/setup-qemu-action@v2
with:
image: tonistiigi/binfmt:master

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
with:
config-inline: |
[worker.oci]
max-parallelism = 2
- name: Matrix Build and push demo images
uses: docker/build-push-action@v3.3.0
with:
context: ${{ matrix.file_tag.context }}
file: ${{ matrix.file_tag.file }}
platforms: linux/amd64,linux/arm64
push: ${{ inputs.push }}
tags: |
${{ env.DOCKERHUB_REPO }}:${{ inputs.version }}-${{matrix.file_tag.tag_suffix }}
${{ env.GHCR_REPO }}:${{ inputs.version }}-${{ matrix.file_tag.tag_suffix }}
cache-from: type=gha
cache-to: type=gha
6 changes: 6 additions & 0 deletions .github/workflows/checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,16 @@
name: Checks

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
workflow_dispatch:

jobs:
build_images:
uses: ./.github/workflows/build-images.yml

markdownlint:
runs-on: ubuntu-latest
steps:
Expand Down
117 changes: 4 additions & 113 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,116 +8,7 @@ on:

jobs:
build_and_push_images:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write

env:
RELEASE_VERSION: "${{ github.event.release.tag_name }}"
DOCKERHUB_REPO: "otel/demo"
GHCR_REPO: "ghcr.io/open-telemetry/demo"

strategy:
matrix:
file_tag:
- file: ./src/adservice/Dockerfile
tag_suffix: adservice
context: ./
- file: ./src/cartservice/src/Dockerfile
tag_suffix: cartservice
context: ./
- file: ./src/checkoutservice/Dockerfile
tag_suffix: checkoutservice
context: ./
- file: ./src/currencyservice/Dockerfile
tag_suffix: currencyservice
context: ./src/currencyservice
- file: ./src/emailservice/Dockerfile
tag_suffix: emailservice
context: ./src/emailservice
- file: ./src/featureflagservice/Dockerfile
tag_suffix: featureflagservice
context: ./
- file: ./src/frontend/Dockerfile
tag_suffix: frontend
context: ./
- file: ./src/frontendproxy/Dockerfile
tag_suffix: frontendproxy
context: ./
- file: ./src/loadgenerator/Dockerfile
tag_suffix: loadgenerator
context: ./
- file: ./src/paymentservice/Dockerfile
tag_suffix: paymentservice
context: ./
- file: ./src/productcatalogservice/Dockerfile
tag_suffix: productcatalogservice
context: ./
- file: ./src/quoteservice/Dockerfile
tag_suffix: quoteservice
context: ./
- file: ./src/shippingservice/Dockerfile
tag_suffix: shippingservice
context: ./
- file: ./src/recommendationservice/Dockerfile
tag_suffix: recommendationservice
context: ./
- file: ./src/kafka/Dockerfile
tag_suffix: kafka
context: ./
- file: ./src/accountingservice/Dockerfile
tag_suffix: accountingservice
context: ./
- file: ./src/frauddetectionservice/Dockerfile
tag_suffix: frauddetectionservice
context: ./
- file: ./src/frontend/Dockerfile.cypress
tag_suffix: frontend-tests
context: ./
- file: ./test/Dockerfile
tag_suffix: integrationTests
context: ./

steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Log in to the Container registry
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
if: github.event_name != 'pull_request'

- name: Log in to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
if: github.event_name != 'pull_request'

- name: Set up QEMU
uses: docker/setup-qemu-action@v2

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
with:
config-inline: |
[worker.oci]
max-parallelism = 2
- name: Matrix Build and push demo images
uses: docker/build-push-action@v3.3.0
with:
context: ${{ matrix.file_tag.context }}
file: ${{ matrix.file_tag.file }}
platforms: linux/amd64,linux/arm64
push: ${{ github.event_name != 'pull_request' }}
tags: |
${{ env.DOCKERHUB_REPO }}:${{ env.RELEASE_VERSION || 'pr' }}-${{matrix.file_tag.tag_suffix }}
${{ env.GHCR_REPO }}:${{ env.RELEASE_VERSION || 'pr' }}-${{ matrix.file_tag.tag_suffix }}
cache-from: type=gha
cache-to: type=gha
uses: ./.github/workflows/build-images.yml
with:
push: true
version: ${{ github.event.release.tag_name }}"
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ src/shippingservice/target/
/src/featureflagservice/src/ffs_demo_pb.erl
/src/featureflagservice/src/ffs_service_*.erl
/src/featureflagservice/src/oteldemo_*.erl
/src/frauddetectionservice/src/main/proto
/src/frontend/pb/
/src/frontend/protos/
/src/paymentservice/demo.proto
Expand Down
20 changes: 18 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,12 +45,28 @@ release.
([#935](https://github.com/open-telemetry/opentelemetry-demo/pull/935))
* [cartservice] update service to .NET 7
([#942](https://github.com/open-telemetry/opentelemetry-demo/pull/942))
* [cartservice] update .NET package to 1.5.1 release
([#935](https://github.com/open-telemetry/opentelemetry-demo/pull/957))
* Introduce minimal mode to run demo
([#872](https://github.com/open-telemetry/opentelemetry-demo/pull/872))
* [frontendproxy]Envoy expose a route for the collector to route frontend spans
([#938](https://github.com/open-telemetry/opentelemetry-demo/pull/938))
* [frontend] update JS SDKs to 1.15.0/0.41.0
([#853](https://github.com/open-telemetry/opentelemetry-demo/pull/853))
* [shippingservice] Update Rust dependencies and add TelemetryResourceDetector
([#972](https://github.com/open-telemetry/opentelemetry-demo/pull/972))
* Update frontendproxy's env for minimal
([#983](https://github.com/open-telemetry/opentelemetry-demo/pull/983))
* [FeatureFlagService] Update dependencies
([#992](https://github.com/open-telemetry/opentelemetry-demo/pull/992))
* [currencyService] Update OTel dependency
([#991](https://github.com/open-telemetry/opentelemetry-demo/pull/991))
* [LoadGenerator & RecommendatationService] update dependencies
([#988](https://github.com/open-telemetry/opentelemetry-demo/pull/988))
* [FraudDetectionService] Updated Kotlin version and OTel dependencies
([#987](https://github.com/open-telemetry/opentelemetry-demo/pull/987))
* [otelcol] Use the collector builder to produce otelcol docker image
([#944](https://github.com/open-telemetry/opentelemetry-demo/pull/944))
* [quoteservice] update php dependencies
([#994](https://github.com/open-telemetry/opentelemetry-demo/issues/994))

## 1.4.0

Expand Down
20 changes: 10 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,16 +53,16 @@ We welcome any vendor to fork the project to demonstrate their services and
adding a link below. The community is committed to maintaining the project and
keeping it up to date for you.

| | | |
| ----------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- |
| [AlibabaCloud LogService](https://github.com/aliyun-sls/opentelemetry-demo) | [Elastic](https://github.com/elastic/opentelemetry-demo) | [OpenSearch](https://github.com/opensearch-project/opentelemetry-demo) |
| [AppDynamics](https://www.appdynamics.com/blog/cloud/how-to-observe-opentelemetry-demo-app-in-appdynamics-cloud/) | [Grafana Labs](https://github.com/grafana/opentelemetry-demo) | [Sentry](https://github.com/getsentry/opentelemetry-demo) |
| [Aspecto](https://github.com/aspecto-io/opentelemetry-demo) | [Helios](https://otelsandbox.gethelios.dev) | [Splunk](https://github.com/signalfx/opentelemetry-demo) |
| [Axiom](https://play.axiom.co/axiom-play-qf1k/dashboards/otel.traces.otel-demo-traces) | [Honeycomb.io](https://github.com/honeycombio/opentelemetry-demo) | [Sumo Logic](https://www.sumologic.com/blog/common-opentelemetry-demo-application/) |
| [Azure Data Explorer](https://github.com/Azure/Azure-kusto-opentelemetry-demo) | [Instana](https://github.com/instana/opentelemetry-demo) | [TelemetryHub](https://github.com/TelemetryHub/opentelemetry-demo/tree/telemetryhub-backend) |
| [Coralogix](https://coralogix.com/blog/configure-otel-demo-send-telemetry-data-coralogix) | [Kloudfuse](https://github.com/kloudfuse/opentelemetry-demo) | [Teletrace](https://github.com/teletrace/opentelemetry-demo) |
| [Datadog](https://github.com/DataDog/opentelemetry-demo) | [Lightstep](https://github.com/lightstep/opentelemetry-demo) | [Uptrace](https://github.com/uptrace/uptrace/tree/master/example/opentelemetry-demo) |
| [Dynatrace](https://www.dynatrace.com/news/blog/opentelemetry-demo-application-with-dynatrace/) | [New Relic](https://github.com/newrelic/opentelemetry-demo) | |
| | | |
|-------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------|
| [AlibabaCloud LogService](https://github.com/aliyun-sls/opentelemetry-demo) | [Elastic](https://github.com/elastic/opentelemetry-demo) | [Sentry](https://github.com/getsentry/opentelemetry-demo) |
| [AppDynamics](https://www.appdynamics.com/blog/cloud/how-to-observe-opentelemetry-demo-app-in-appdynamics-cloud/) | [Grafana Labs](https://github.com/grafana/opentelemetry-demo) | [ServiceNow Cloud Observability](https://docs.lightstep.com/otel/quick-start-operator#send-data-from-the-opentelemetry-demo) |
| [Aspecto](https://github.com/aspecto-io/opentelemetry-demo) | [Helios](https://otelsandbox.gethelios.dev) | [Splunk](https://github.com/signalfx/opentelemetry-demo) |
| [Axiom](https://play.axiom.co/axiom-play-qf1k/dashboards/otel.traces.otel-demo-traces) | [Honeycomb.io](https://github.com/honeycombio/opentelemetry-demo) | [Sumo Logic](https://www.sumologic.com/blog/common-opentelemetry-demo-application/) |
| [Azure Data Explorer](https://github.com/Azure/Azure-kusto-opentelemetry-demo) | [Instana](https://github.com/instana/opentelemetry-demo) | [TelemetryHub](https://github.com/TelemetryHub/opentelemetry-demo/tree/telemetryhub-backend) |
| [Coralogix](https://coralogix.com/blog/configure-otel-demo-send-telemetry-data-coralogix) | [Kloudfuse](https://github.com/kloudfuse/opentelemetry-demo) | [Teletrace](https://github.com/teletrace/opentelemetry-demo) |
| [Datadog](https://github.com/DataDog/opentelemetry-demo) | [New Relic](https://github.com/newrelic/opentelemetry-demo) | [Uptrace](https://github.com/uptrace/uptrace/tree/master/example/opentelemetry-demo) |
| [Dynatrace](https://www.dynatrace.com/news/blog/opentelemetry-demo-application-with-dynatrace/) | [OpenSearch](https://github.com/opensearch-project/opentelemetry-demo) | |

## Contributing

Expand Down
6 changes: 4 additions & 2 deletions docker-compose.minimal.yml
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,8 @@ services:
- JAEGER_SERVICE_PORT
- JAEGER_SERVICE_HOST
- OTEL_COLLECTOR_HOST
- OTEL_COLLECTOR_PORT
- OTEL_COLLECTOR_PORT_GRPC
- OTEL_COLLECTOR_PORT_HTTP
- ENVOY_PORT
depends_on:
frontend:
Expand Down Expand Up @@ -288,7 +289,8 @@ services:
- LOCUST_HOST
- LOCUST_HEADLESS
- LOCUST_AUTOSTART
- OTEL_EXPORTER_OTLP_TRACES_ENDPOINT=http://${OTEL_COLLECTOR_HOST}:4318/v1/traces
- OTEL_EXPORTER_OTLP_ENDPOINT
- OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE
- OTEL_RESOURCE_ATTRIBUTES
- OTEL_SERVICE_NAME=loadgenerator
- PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python
Expand Down
12 changes: 8 additions & 4 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,8 @@ services:
- LOCUST_HOST
- LOCUST_HEADLESS
- LOCUST_AUTOSTART
- OTEL_EXPORTER_OTLP_TRACES_ENDPOINT=http://${OTEL_COLLECTOR_HOST}:4318/v1/traces
- OTEL_EXPORTER_OTLP_ENDPOINT
- OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE
- OTEL_RESOURCE_ATTRIBUTES
- OTEL_SERVICE_NAME=loadgenerator
- PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python
Expand Down Expand Up @@ -644,8 +645,13 @@ services:

# OpenTelemetry Collector
otelcol:
image: otel/opentelemetry-collector-contrib:0.76.1
image: ${IMAGE_NAME}:${IMAGE_VERSION}-otelcol
container_name: otel-col
build:
context: ./
dockerfile: ./src/otelcollector/Dockerfile
cache_from:
- ${IMAGE_NAME}:${IMAGE_VERSION}-otelcol
deploy:
resources:
limits:
Expand Down Expand Up @@ -818,8 +824,6 @@ services:
interval: 1s
timeout: 3s
retries: 60
environment:
TRACETEST_DEV: ${TRACETEST_DEV}

tracetest-postgres:
image: postgres:14
Expand Down
Loading

0 comments on commit a54beed

Please sign in to comment.