Skip to content

update opentelemetry to 0.21 without backwards compatibility #350

update opentelemetry to 0.21 without backwards compatibility

update opentelemetry to 0.21 without backwards compatibility #350

Workflow file for this run

on:
push:
branches:
- main
pull_request:
branches:
- main
name: CI
jobs:
build_and_test:
name: Build and Test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
# Lint
# Note: GitHub hosted runners using the latest stable version of Rust have Clippy pre-installed.
- run: cargo clippy --features=metrics-0_21,prometheus-exporter
- run: cargo clippy --features=prometheus-0_13
- run: cargo clippy --features=prometheus-client-0_21
- run: cargo clippy --features=opentelemetry-0_21
# Run the tests with each of the different metrics libraries
- run: cargo test --features=prometheus-exporter
- run: cargo test --features=prometheus-exporter,metrics-0_21
- run: cargo test --features=prometheus-exporter,prometheus-0_13
- run: cargo test --features=prometheus-exporter,prometheus-client-0_21,exemplars-tracing
- run: cargo test --features=prometheus-exporter,prometheus-client-0_21,exemplars-tracing-opentelemetry-0_22
- run: cargo test --features=prometheus-exporter,opentelemetry-0_21
# Build the crate using the other optional features
- run: cargo build --features=metrics-0_21,custom-objective-percentile,custom-objective-latency
# Compile the examples
- run: cargo build --package example-actix-web
- run: cargo build --package example-axum
- run: cargo build --package example-custom-metrics
- run: cargo build --package example-exemplars-tracing
- run: cargo build --package example-exemplars-tracing-opentelemetry
- run: cargo build --package example-full-api
- run: cargo build --package example-opentelemetry-push
# Make sure the docs can be built
- run: cargo doc --all-features