Skip to content
This repository has been archived by the owner on Nov 30, 2022. It is now read-only.

Telemetry collector is catching BQ's internal open telemetry #177

Closed
bastienboutonnet opened this issue Jan 3, 2022 · 4 comments · Fixed by sodadata/soda-core#632
Closed
Assignees
Labels
bug Something isn't working soda-sql

Comments

@bastienboutonnet
Copy link

Running select distinct implementation_module_name from intelligence_dwh.soda_sql_telemetry.base_soda_sql_events returns google.cloud.bigquery.opentelemetry_tracing which made one of our reporting transformation DQ test fail.

We should ideally avoid catching telemetry messages coming from other libraries so that we don't end up polluting our events with stuff that other people track.

@bastienboutonnet bastienboutonnet added bug Something isn't working soda-sql labels Jan 3, 2022
@vijaykiran
Copy link
Contributor

Notes: Looks like bigquery module doesn't give an option to disable it, because it is setting it up at module load: https://github.com/googleapis/python-bigquery/blob/main/google/cloud/bigquery/opentelemetry_tracing.py#L25

@vijaykiran vijaykiran self-assigned this Jan 3, 2022
@bastienboutonnet
Copy link
Author

What I'm not sure I understand is why those events get pushed into our collector. Is it something about how we implemented it that somehow redirects BQ's collector URL to ours?

It seems like the more people would implement OT the more everyone would start collecting each other's data which is less than ideal.

@vijaykiran
Copy link
Contributor

BigQuery library only creates spans - and provides a way to collect the instrumentation data (https://github.com/googleapis/python-bigquery#instrumenting-with-opentelemetry). The library doesn't have any collector by default.

Since we configure a collector ourselves, the data is pushed to it because the spans are created. There can be many different exporters configured in an application. And there is no easy way to (open-telemetry/opentelemetry-collector#2310) disable it.

I'll see if we can monkey-patch python-bigquery or perhaps create a version of exporter.

@m1n0
Copy link
Contributor

m1n0 commented Jan 6, 2022

fixed, we filter out any non-soda spans very strictly based on their name (span name starts with soda)

@vijaykiran vijaykiran transferred this issue from sodadata/soda-core Mar 22, 2022
@vijaykiran vijaykiran transferred this issue from sodadata/soda-core Mar 22, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working soda-sql
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants