Skip to content

Commit

Permalink
Otel config (#782)
Browse files Browse the repository at this point in the history
* General restructring of Otel configuration

```yaml
telemetry:
  apollo:
    endpoint:
    apollo_graph_ref:
    apollo_key:
  tracing:
    propagation:
      # Propagation is automatically enabled for any exporters that are enabled
      # but you can enable extras. This is mostly to support otlp.
      zipkin: true
      datadog: false
      trace_context: false
      jaeger: false
      baggage: false

    otlp:
      endpoint: Default
      protocol: Grpc
      http:
        ..
      grpc:
        ..
    zipkin:
      agent:
        endpoint: Default
    jaeger:
      agent:
        endpoint: Default
    datadog:
      endpoint: Default

    # Trace config is shared across all exporters
    trace_config:
      # Env variables can be used anywhere in any plugin config
      service_name: "${ENV_VARIABLE}"
  metrics:
    ..

```

Each of the exporters has its own source file.

Other notes:
* Otel provides integration with http for propagation. Removed our custom code and use the library.
* Remove our propagation layer, otel provides propagators for each exporter.
* Fix header extraction. Spans can now be collated from client to subgraphs.
* Update supgergraph demo so that span propagation takes place
* Unfied metrics and tracing config
* Config enums changes to snake_case 

There is an issue round sampling that needs to be followed up on.
Sampling happens at the pipeline level, so if the user enables sampling then discarded samples will not make it to spaceport. We need to discuss what we are going to do about this.

Co-authored-by: bryn <bryn@apollographql.com>
Co-authored-by: Geoffroy Couprie <geoffroy@apollographql.com>
Co-authored-by: Coenen Benjamin <benjamin.coenen@hotmail.com>
  • Loading branch information
4 people authored Apr 8, 2022
1 parent e38c848 commit 74b20a3
Show file tree
Hide file tree
Showing 56 changed files with 3,076 additions and 2,584 deletions.
5 changes: 1 addition & 4 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -242,10 +242,7 @@ commands:
steps:
- rust/build:
with_cache: false
crate: --locked --features otlp-grpc -p apollo-router -p apollo-router-core
- rust/build:
with_cache: false
crate: --locked --no-default-features --features otlp-http -p apollo-router -p apollo-router-core
crate: --locked -p apollo-router -p apollo-router-core
build_all_permutations:
steps:
- build_common_permutations
Expand Down
107 changes: 104 additions & 3 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 74b20a3

Please sign in to comment.