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

[BUG][exporter/awss3] Newer versions path has extra "/" prefix #37503

Open
portswigger-tim opened this issue Jan 27, 2025 · 5 comments
Open

[BUG][exporter/awss3] Newer versions path has extra "/" prefix #37503

portswigger-tim opened this issue Jan 27, 2025 · 5 comments
Labels
bug Something isn't working exporter/awss3

Comments

@portswigger-tim
Copy link

Component(s)

exporter/awss3

What happened?

Description

In v0.115.0 the aws s3 exporter uploads files to a path like:
s3://sniffler-l4hsf/year=2025/month=01/day=10/hour=00/minute=05/traces_760872934.json

In v0.117.0 paths have an extra "/" prefix:
s3://sniffler-l4hsf//year=2025/month=01/day=15/hour=14/minute=55/traces_948440739.json

This leads to files not being available in the expected place. I suspecte that this was introduced in: #36698

Steps to Reproduce

Configure exporter to ship to S3 on the two different versions.

Expected Result

Paths do not have an extra "/"

Actual Result

Paths have an extra "/"

Collector version

v0.117.0

Environment information

Environment

OS: (e.g., "Ubuntu 20.04")
Compiler(if manually compiled): (e.g., "go 14.2")

OpenTelemetry Collector configuration

Log output

Additional context

No response

@portswigger-tim portswigger-tim added bug Something isn't working needs triage New item requiring triage labels Jan 27, 2025
Copy link
Contributor

Pinging code owners:

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

@portswigger-tim
Copy link
Author

I suspect that this line is the cause: https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/36698/files#diff-527f944a938a0dd5e7cab3825a123d2571a44fc3d4158046095070b51cf6390eR61

It does not account for not having a PartitionPrefix.

@portswigger-tim
Copy link
Author

Possibly related to a difference between SDK v1 and v2 handling of paths / urls: aws/aws-sdk-go-v2#1701 (comment)

@VihasMakwana
Copy link
Contributor

@portswigger-tim I suspect that the file ends up in an "empty" folder?

@VihasMakwana
Copy link
Contributor

@portswigger-tim can you share your collector configuration?

@VihasMakwana VihasMakwana removed the needs triage New item requiring triage label Jan 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working exporter/awss3
Projects
None yet
Development

No branches or pull requests

2 participants