-
Notifications
You must be signed in to change notification settings - Fork 672
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Separate protobuf encoding into a separate package #3169
Separate protobuf encoding into a separate package #3169
Conversation
...orter-otlp-proto-http/src/opentelemetry/exporter/otlp/proto/http/metric_exporter/__init__.py
Show resolved
Hide resolved
...r-otlp-proto-common/src/opentelemetry/exporter/otlp/proto/common/metrics_encoder/__init__.py
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've also noticed that all log packaged are protected, as in start with _log
should this also happen in the common package?
...pentelemetry-exporter-otlp-proto-grpc/src/opentelemetry/exporter/otlp/proto/grpc/exporter.py
Show resolved
Hide resolved
5547c24
to
c70248c
Compare
c70248c
to
beb7cc2
Compare
...r-otlp-proto-common/src/opentelemetry/exporter/otlp/proto/common/metrics_encoder/__init__.py
Outdated
Show resolved
Hide resolved
...pentelemetry-exporter-otlp-proto-grpc/src/opentelemetry/exporter/otlp/proto/grpc/exporter.py
Show resolved
Hide resolved
...porter-otlp-proto-grpc/src/opentelemetry/exporter/otlp/proto/grpc/trace_exporter/__init__.py
Outdated
Show resolved
Hide resolved
...ter-otlp-proto-common/src/opentelemetry/exporter/otlp/proto/common/trace_encoder/__init__.py
Outdated
Show resolved
Hide resolved
...ter-otlp-proto-common/src/opentelemetry/exporter/otlp/proto/common/trace_encoder/__init__.py
Outdated
Show resolved
Hide resolved
...telemetry-exporter-otlp-proto-common/src/opentelemetry/exporter/otlp/proto/common/version.py
Outdated
Show resolved
Hide resolved
exporter/opentelemetry-exporter-otlp-proto-common/tests/test_log_encoder.py
Show resolved
Hide resolved
...orter-otlp-proto-common/src/opentelemetry/exporter/otlp/proto/common/log_encoder/__init__.py
Outdated
Show resolved
Hide resolved
...r-otlp-proto-common/src/opentelemetry/exporter/otlp/proto/common/metrics_encoder/__init__.py
Outdated
Show resolved
Hide resolved
...r-otlp-proto-common/src/opentelemetry/exporter/otlp/proto/common/metrics_encoder/__init__.py
Outdated
Show resolved
Hide resolved
...r-otlp-proto-common/src/opentelemetry/exporter/otlp/proto/common/metrics_encoder/__init__.py
Outdated
Show resolved
Hide resolved
...r-otlp-proto-common/src/opentelemetry/exporter/otlp/proto/common/metrics_encoder/__init__.py
Outdated
Show resolved
Hide resolved
...pentelemetry-exporter-otlp-proto-grpc/src/opentelemetry/exporter/otlp/proto/grpc/exporter.py
Outdated
Show resolved
Hide resolved
...orter-otlp-proto-http/src/opentelemetry/exporter/otlp/proto/http/metric_exporter/__init__.py
Outdated
Show resolved
Hide resolved
...elemetry-exporter-otlp-proto-common/src/opentelemetry/exporter/otlp/proto/common/__init__.py
Outdated
Show resolved
Hide resolved
...orter-otlp-proto-common/src/opentelemetry/exporter/otlp/proto/common/log_encoder/__init__.py
Outdated
Show resolved
Hide resolved
...r-otlp-proto-common/src/opentelemetry/exporter/otlp/proto/common/metrics_encoder/__init__.py
Outdated
Show resolved
Hide resolved
...r-otlp-proto-common/src/opentelemetry/exporter/otlp/proto/common/metrics_encoder/__init__.py
Outdated
Show resolved
Hide resolved
...r-otlp-proto-common/src/opentelemetry/exporter/otlp/proto/common/metrics_encoder/__init__.py
Outdated
Show resolved
Hide resolved
@lzchen @srikanthccv I'm not entirely sure on the namings, at the moment I've added the encoders as:
But I am now thinking:
|
beb7cc2
to
fcfbd68
Compare
e91877c
to
e4aa80f
Compare
@jack-burridge-cfh you can resolve the outdated conversation if you believe the comment is addressed. I will take a look at the PR again. |
Done |
@srikanthccv The issues with the checks seem to be git-based ones which I can't reproduce locally, so I don't know how to fix those |
@jack-burridge-cfh |
ce2d186
to
7a746ae
Compare
I ran |
Overall LGTM. I am thinking about the import paths. It seems like one would end up using aliases if they want to use encoders.
|
The decision here was a conscious one, basically most uses will not involve multiple types of encoders, and encourages you to keep them separate. I honestly cannot think of a reason you would, it's more likely an edge case. Like they are used here the encoders are likely to be used to write different types of exporters (Kafka etc) and these exporters are likely to be in different files. |
We have been explicit and verbose in the project. You can see it in many places in the project, including the exporters ( |
7a746ae
to
96fe119
Compare
Fair point. Done 😄 |
LGTM from my side, I will let other approvers take a look once and then merge if they don't have any objections. Thank you for your continuous effort to for addressing the comments and get this merged. |
e827f58
to
0322c32
Compare
...try-exporter-otlp-proto-common/src/opentelemetry/exporter/otlp/proto/common/trace_encoder.py
Outdated
Show resolved
Hide resolved
0322c32
to
76a87f1
Compare
76a87f1
to
179a697
Compare
179a697
to
82a1075
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Solid refactoring! Thank you.
It's why I use PyCharm 😄 It may be cumbersome but the refactoring is fantastic |
@srikanthccv Any reason this cant be merged? or are we waiting for more people to look at it because of the scope of the change? |
Description
This separates Protobuf encoding into a separate package
opentelemetry-exporter-otlp-proto-common
which is then used by:opentelemetry-exporter-otlp-proto-grpc
opentelemetry-exporter-otlp-proto-http
Fixes #3160
Type of change
How Has This Been Tested?
Tests have been moved from
opentelemetry-exporter-otlp-proto-grpc
andopentelemetry-exporter-otlp-proto-http
to the new packageChecklist: