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

feat: Better OTEL traces, add metrics #1751

Merged
merged 10 commits into from
Jun 27, 2024

Conversation

erezrokah
Copy link
Contributor

@erezrokah erezrokah commented Jun 19, 2024

Summary

Trying to follow https://www.honeycomb.io/blog/opentelemetry-best-practices-naming to have some convention and namespaces for traces.
Also removed syncDfs as it doesn't really add additional information.

I've added invocationID to traces, but not metrics as using a random value for a metric attribute will cause high cardinality (that will increase over time)


Use the following steps to ensure your PR is ready to be reviewed

  • Read the contribution guidelines 🧑‍🎓
  • Run go fmt to format your code 🖊
  • Lint your changes via golangci-lint run 🚨 (install golangci-lint here)
  • Update or add tests 🧪
  • Ensure the status checks below are successful ✅

@github-actions github-actions bot added the fix label Jun 19, 2024
@erezrokah erezrokah changed the title fix: Better naming for OTEL traces feat: Better OTEL traces, add metrics Jun 25, 2024
@github-actions github-actions bot added feat and removed fix labels Jun 25, 2024
serve/plugin.go Outdated Show resolved Hide resolved
@github-actions github-actions bot removed the feat label Jun 26, 2024
@erezrokah erezrokah marked this pull request as ready for review June 26, 2024 20:25
@github-actions github-actions bot added the feat label Jun 26, 2024
@erezrokah erezrokah requested a review from a team as a code owner June 26, 2024 20:25
@@ -140,45 +136,12 @@ func (s *PluginServe) newCmdPluginServe() *cobra.Command {
logger = log.Output(zerolog.ConsoleWriter{Out: os.Stdout}).Level(zerologLevel)
}

if otelEndpoint != "" {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Moved in to opentelemetry.go

Copy link

@marianogappa marianogappa left a comment

Choose a reason for hiding this comment

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

Some comments.

plugin/plugin_source.go Show resolved Hide resolved
serve/plugin.go Show resolved Hide resolved
@kodiakhq kodiakhq bot merged commit 874c33a into cloudquery:main Jun 27, 2024
10 checks passed
@erezrokah erezrokah deleted the feat/open_telemetry branch June 27, 2024 11:39
kodiakhq bot pushed a commit that referenced this pull request Jun 27, 2024
🤖 I have created a release *beep* *boop*
---


## [4.49.0](v4.48.0...v4.49.0) (2024-06-27)


### Features

* Better OTEL traces, add metrics ([#1751](#1751)) ([874c33a](874c33a))


### Bug Fixes

* **deps:** Update module github.com/hashicorp/go-retryablehttp to v0.7.7 [SECURITY] ([#1774](#1774)) ([e5e8e7e](e5e8e7e))

---
This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
kodiakhq bot pushed a commit to cloudquery/cloudquery that referenced this pull request Jun 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants