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

[processor/resourcedetection] Additional docker attributes #29018

Closed
schewara opened this issue Nov 8, 2023 · 12 comments
Closed

[processor/resourcedetection] Additional docker attributes #29018

schewara opened this issue Nov 8, 2023 · 12 comments
Labels
closed as inactive enhancement New feature or request processor/resourcedetection Resource detection processor Stale

Comments

@schewara
Copy link

schewara commented Nov 8, 2023

Component(s)

processor/resourcedetection

Describe the issue you're reporting

It would be super helpful if the Docker Metadata would support more attributes, like the ones proposed in https://opentelemetry.io/docs/specs/semconv/resource/container/

An example use case would be a CI/CD Pipeline where multiple integration tests are running in parallel for different feature branches, which can only be distinguished by a unique container.name or container.image.tag

@schewara schewara added the needs triage New item requiring triage label Nov 8, 2023
@github-actions github-actions bot added the processor/resourcedetection Resource detection processor label Nov 8, 2023
Copy link
Contributor

github-actions bot commented Nov 8, 2023

Pinging code owners:

See Adding Labels via Comments if you do not have permissions to add labels yourself.

@crobert-1 crobert-1 added the enhancement New feature or request label Nov 8, 2023
@crobert-1
Copy link
Member

I think this is a good idea. Here's the current list of resource attributes we're getting from Docker.

This will require some level of plumbing of these resource attributes. The resource detection processor is getting docker data from internal/metadataproviders/docker (ref), which is getting data from Docker's golang client package. For any new container resource attribute we'll have to add it to the internal metadata provider, and then get it from there. (This also means we're blocked by the Docker client if data we want isn't exposed.)

@schewara would you be interested in adding these resource attributes?

@crobert-1 crobert-1 removed the needs triage New item requiring triage label Nov 8, 2023
@schewara
Copy link
Author

@crobert-1 Generally I would be interested, but therefore I need to learn Go first, which might take a while until I get around it.

@crobert-1
Copy link
Member

@crobert-1 Generally I would be interested, but therefore I need to learn Go first, which might take a while until I get around it.

Fair point 🙂

@socheatsok78

This comment was marked as off-topic.

@hq-conf
Copy link

hq-conf commented Dec 9, 2023

Has there been any work on pulling additional docker attributes, either as part of resourcedetection or dockerstats? Specifically, I am looking for the container.image.tag - as it stands, am I correct in saying that I would need to write a transform to extract this as a custom attribute?

@crobert-1
Copy link
Member

@hq-conf You might want to try the k8s attributes processor, it looks like it can get thecontainer.image.tag.

Copy link
Contributor

This issue has been inactive for 60 days. It will be closed in 60 days if there is no activity. To ping code owners by adding a component label, see Adding Labels via Comments, or if you are unsure of which component this issue relates to, please ping @open-telemetry/collector-contrib-triagers. If this issue is still relevant, please ping the code owners or leave a comment explaining why it is still relevant. Otherwise, please close it.

Pinging code owners:

See Adding Labels via Comments if you do not have permissions to add labels yourself.

@github-actions github-actions bot added the Stale label Feb 14, 2024
@schewara
Copy link
Author

How would the actual configuration for the k8s attribute processor look like to grab the labels from a docker container?

@github-actions github-actions bot removed the Stale label Feb 19, 2024
@crobert-1
Copy link
Member

How would the actual configuration for the k8s attribute processor look like to grab the labels from a docker container?

The README has information for how to accomplish this. There's also a config example that shows how to extract metadata from the k8s environmnent.

Copy link
Contributor

This issue has been inactive for 60 days. It will be closed in 60 days if there is no activity. To ping code owners by adding a component label, see Adding Labels via Comments, or if you are unsure of which component this issue relates to, please ping @open-telemetry/collector-contrib-triagers. If this issue is still relevant, please ping the code owners or leave a comment explaining why it is still relevant. Otherwise, please close it.

Pinging code owners:

See Adding Labels via Comments if you do not have permissions to add labels yourself.

@github-actions github-actions bot added the Stale label Apr 29, 2024
Copy link
Contributor

This issue has been closed as inactive because it has been stale for 120 days with no activity.

@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Jun 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
closed as inactive enhancement New feature or request processor/resourcedetection Resource detection processor Stale
Projects
None yet
Development

No branches or pull requests

4 participants