Skip to content
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

Improve handling of status code/message (#51) #70

Merged
merged 1 commit into from
Jul 1, 2019
Merged

Improve handling of status code/message (#51) #70

merged 1 commit into from
Jul 1, 2019

Conversation

owais
Copy link
Contributor

@owais owais commented Jun 28, 2019

Improved how translators handling mapping status codes and messages to and from OC

translator/trace/README.md documents the new behaviour: https://github.com/open-telemetry/opentelemetry-service/pull/70/files#diff-cf653ae20e304fa43f02c3a37a01a3cd

@owais owais changed the title Improve handling of status code/message (#51) WIP: Improve handling of status code/message (#51) Jun 28, 2019
@owais owais changed the title WIP: Improve handling of status code/message (#51) Improve handling of status code/message (#51) Jun 28, 2019
@codecov-io
Copy link

codecov-io commented Jun 28, 2019

Codecov Report

❗ No coverage uploaded for pull request base (master@e32ae89). Click here to learn what that means.
The diff coverage is 91.97%.

Impacted file tree graph

@@            Coverage Diff            @@
##             master      #70   +/-   ##
=========================================
  Coverage          ?   71.91%           
=========================================
  Files             ?       94           
  Lines             ?     6145           
  Branches          ?        0           
=========================================
  Hits              ?     4419           
  Misses            ?     1499           
  Partials          ?      227
Impacted Files Coverage Δ
...sor/tracesamplerprocessor/tracesamplerprocessor.go 100% <ø> (ø)
translator/trace/spandata/protospan_to_spandata.go 59.88% <ø> (ø)
receiver/prometheusreceiver/factory.go 77.5% <ø> (ø)
receiver/zipkinreceiver/factory.go 100% <ø> (ø)
translator/trace/grpc_http_mapper.go 0% <0%> (ø)
translator/trace/zipkin/zipkinv1_to_protospan.go 90.14% <100%> (ø)
...anslator/trace/jaeger/protospan_to_jaegerthrift.go 82.41% <100%> (ø)
translator/trace/zipkin/status_code.go 100% <100%> (ø)
...lator/trace/zipkin/zipkinv1_thrift_to_protospan.go 78.06% <100%> (ø)
...ranslator/trace/jaeger/protospan_to_jaegerproto.go 76.22% <100%> (ø)
... and 2 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e32ae89...2fba65b. Read the comment docs.

tigrannajaryan
tigrannajaryan previously approved these changes Jun 28, 2019
Copy link
Member

@tigrannajaryan tigrannajaryan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, I already reviewed this in details on our internal repo.

@@ -1,4 +1,4 @@
// Copyright 2019, OpenTelemetry Authors
// Copyright 2018, OpenTelemetry Authors
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unnecessary change:

Suggested change
// Copyright 2018, OpenTelemetry Authors
// Copyright 2019, OpenTelemetry Authors

@@ -1,4 +1,4 @@
// Copyright 2019, OpenTelemetry Authors
// Copyright 2018, OpenTelemetry Authors
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ditto

@@ -1,4 +1,4 @@
// Copyright 2019, OpenTelemetry Authors
// Copyright 2018, OpenTelemetry Authors
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix here and elsewhere too.

flands
flands previously approved these changes Jun 28, 2019
Copy link
Contributor

@flands flands left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

* `code` should be added as a `census.status_code` tag.
* `message` should be added as a `census.status_description` tag.

In addition to this, if the OC status field represents a non-OK status, then a tag with the key `error` and value `true` should be added to the Zipkin span if one is not already present.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please do not do this. zipkin has always regarded the "error" true an anti pattern. instrumentation have been known to set false nonsense value

the value of the "error" tag should be the best available message ex status code if a text variant is not available. empty message is ok and better than true.

pjanotti
pjanotti previously approved these changes Jul 1, 2019
Copy link
Contributor

@pjanotti pjanotti left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just change zipkin behavior per maintainer's request, otherwise LGTM.

@owais
Copy link
Contributor Author

owais commented Jul 1, 2019

Updated.

pjanotti
pjanotti previously approved these changes Jul 1, 2019
tigrannajaryan
tigrannajaryan previously approved these changes Jul 1, 2019
Improved how translators handling mapping status codes and messages to and from OC

translator/trace/README.md documents the new behaviour
@owais owais dismissed stale reviews from tigrannajaryan and pjanotti via 2fba65b July 1, 2019 22:23
@pjanotti pjanotti merged commit 21339fb into open-telemetry:master Jul 1, 2019
* `code` should be added as a `census.status_code` tag.
* `message` should be added as a `census.status_description` tag.

In addition to this, if the OC status field represents a non-OK status, then a tag with the key `error` should be added and set to the same value as that of the status message falling back to status code when status message is not available.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SGTM

@owais owais deleted the status-translation branch February 19, 2020 00:43
bogdandrutu added a commit that referenced this pull request Oct 28, 2021
* Initial commit

* Add CODEOWNERS file (#2)

* Add CODEOWNERS file

* Update CODEOWNERS

* Moved from github.com/observatorium/opentelemetry-collector-builder (#3)

Signed-off-by: Juraci Paixão Kröhling <[email protected]>

* fixed panics (#6)

Signed-off-by: Joe Elliott <[email protected]>

* Replace master with main in CI and mergify files (#8)

Signed-off-by: Juraci Paixão Kröhling <[email protected]>

* Bump to OpenTelemetry Collector 0.20.0 (#10)

Closes #9

Signed-off-by: Juraci Paixão Kröhling <[email protected]>

* Explicitly enable Go modules in quickstart instructions (#13)

* Update to collector v0.21.0 (#17)

Fixes #16

Signed-off-by: Juraci Paixão Kröhling <[email protected]>

* Update to collector v0.22.0 (#19)

* Download go modules before building (#20)

Fixes #14

* Add version command (#25)

Signed-off-by: Ashmita Bohara <[email protected]>

* Pass errors from cobra Execute back to main for correct exit code (#28)

* pass errors from cobra execute back to main

* print the error

* Update to collector v0.23.0 (#27)

* Generate a warning if the builder and collector base version mismatch (#30)

* Generate a warning if the builder and collector base version mismatch

* Show current default version in the warning message

* Update to OpenTelemetry Collector 0.24.0

* Don't use %w formatting with log.Fatal (#35)

* Update to OpenTelemetry Collector 0.25.0 (#36)

Signed-off-by: Serge Catudal <[email protected]>

* Update to 0.26.0 and update BuildInfo (#39)

* Sync build and CI Go versions at latest 1.16 (#34)

* Sync build and CI Go versions at latest 1.16

* Run go mod tidy

* Set go binary to use in the compilation phase in tests

Signed-off-by: Juraci Paixão Kröhling <[email protected]>

Co-authored-by: Juraci Paixão Kröhling <[email protected]>

* Add option to generate go code only (no compile) (#40)

* Issue#24 Add option to generate go code only (no compile)

* Update cmd/root.go logging

Suggested by @jpkkrohling

Co-authored-by: Juraci Paixão Kröhling <[email protected]>

* remove verbose help .. created by corba

* suggestion by jpkrohling to keep generateandcompile

* lint error: remove unused var

* reword cmd option and add back help message for default

Co-authored-by: Juraci Paixão Kröhling <[email protected]>

* Don't reuse exec.Cmd (#42)

* Update to OpenTelemetry Collector 0.27.0 (#43)

* Add CI Badge (#47)

* Update to Collector v0.28.0 (#49)

* Update to Collector v0.28.0

Closes #48

Addresses the breaking API change in
#3163,
besides the usual version number changes.

Signed-off-by: Fangyi Zhou <[email protected]>

* Use `go mod tidy` instead of `go mod download`

It appears that this magically resolves the go.mod file issue.
https://stackoverflow.com/questions/67203641/missing-go-sum-entry-for-module-providing-package-package-name

Signed-off-by: Fangyi Zhou <[email protected]>

* Account for go mod download in go1.17 not updating go.sum (#50)

* Update to collector v0.29.0 (#54)

* Update replaces.builder.yaml

* Update nocore.builder.yaml

* Update config.go

* Update README.md

* Update main.go

* Update to collector v0.30.0 (#57)

* cmd: fix module flag default value to github.com/open-telemetry (#58)

Signed-off-by: Koichi Shiraishi <[email protected]>

* Update to collector v0.31.0 (#60)

* Update to v0.33.0 (#62)

Signed-off-by: Anthony J Mirabella <[email protected]>

* Add excludes support to generated go.mod (#63)

Signed-off-by: Anthony J Mirabella <[email protected]>

Co-authored-by: Juraci Paixão Kröhling <[email protected]>

* Small cleanup for the builder files (#64)

Signed-off-by: Bogdan Drutu <[email protected]>

* Support building with Go 1.17 (#66)

* Support building with Go 1.17
Fixes #65

Signed-off-by: Juraci Paixão Kröhling <[email protected]>

* Update workflows to use Go 1.17

Signed-off-by: Juraci Paixão Kröhling <[email protected]>

* Add gosec exceptions for exec.Command

Signed-off-by: Juraci Paixão Kröhling <[email protected]>

* Update to OpenTelemetry core 0.34.0 (#68)

Fixes #67

Signed-off-by: Juraci Paixão Kröhling <[email protected]>

* Upgrade to OpenTelemetry Collector 0.35.0 (#70)

Signed-off-by: Fangyi Zhou <[email protected]>

* Upgrade to OpenTelemetry Collector 0.36.0 (#76)

* Generate custom service code for Windows (#75)

* update main to include windows service code

* use main version from tag 0.35.0

* update main function

* align with upstream v0.36.0 tag

* dummy change to trigger build

* Revert "dummy change to trigger build"

This reverts commit 629d499461da2d2c240bf1e495b5fe0558e3547f.

* Remove Core from Module type (#77)

Fixes #15

Signed-off-by: yugo-horie <[email protected]>

* release 0.37.0 (#78)

* release 0.37.0

* update use of NewCommand

* Move builder to subdirectory

Signed-off-by: Juraci Paixão Kröhling <[email protected]>

Co-authored-by: Bogdan Drutu <[email protected]>
Co-authored-by: Bogdan Drutu <[email protected]>
Co-authored-by: Joe Elliott <[email protected]>
Co-authored-by: Eric Yang <[email protected]>
Co-authored-by: Brian Gibbins <[email protected]>
Co-authored-by: Ashmita <[email protected]>
Co-authored-by: Fangyi Zhou <[email protected]>
Co-authored-by: Shaun Creary <[email protected]>
Co-authored-by: Patryk Małek <[email protected]>
Co-authored-by: Serge Catudal <[email protected]>
Co-authored-by: Aaron Stone <[email protected]>
Co-authored-by: Patryk Małek <[email protected]>
Co-authored-by: Aaron Stone <[email protected]>
Co-authored-by: Kelvin Lo <[email protected]>
Co-authored-by: Himanshu <[email protected]>
Co-authored-by: Y.Horie <[email protected]>
Co-authored-by: Koichi Shiraishi <[email protected]>
Co-authored-by: Anthony Mirabella <[email protected]>
Co-authored-by: Cal Loomis <[email protected]>
Co-authored-by: alrex <[email protected]>
bogdandrutu pushed a commit that referenced this pull request Oct 28, 2021
MovieStoreGuy pushed a commit to atlassian-forks/opentelemetry-collector that referenced this pull request Nov 11, 2021
- also add implementation of AlwaysSampleSampler and NeverSampleSampler
hughesjj pushed a commit to hughesjj/opentelemetry-collector that referenced this pull request Apr 27, 2023
* Update deps to v0.19.0

* Remove deprecated signalfxcorrelation exporter
Troels51 pushed a commit to Troels51/opentelemetry-collector that referenced this pull request Jul 5, 2024
swiatekm pushed a commit to swiatekm/opentelemetry-collector that referenced this pull request Oct 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants