open-telemetry / opentelemetry-collector-contrib

Contrib repository for the OpenTelemetry Collector
https://opentelemetry.io
Apache License 2.0
3.1k stars 2.39k forks source link

S3 exporter: endpoint documentation / bucket #32774

Closed dmitryax closed 4 months ago

dmitryax commented 6 months ago

Discussed in https://github.com/open-telemetry/opentelemetry-collector-contrib/discussions/32766

Originally posted by **dabcoder** April 30, 2024 [The S3 exporter documentation](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/main/exporter/awss3exporter/README.md#exporter-configuration) states that the `endpoint` parameter overrides the endpoint used by the exporter instead of constructing it from `region` and `s3_bucket` . Yet [in the code](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/e0af2457aed5ba6107da21204eb41d84273ca8dc/exporter/awss3exporter/config.go#L54) there is: ``` if c.S3Uploader.S3Bucket == "" { errs = multierr.Append(errs, errors.New("bucket is required")) } ``` However, when the `endpoint` is provided, it should also contain the S3 bucket, thus I would not expect the `s3_bucket` to have to be provided and this error to be returned. Am I misunderstanding the config setup here?
github-actions[bot] commented 6 months ago

Pinging code owners for exporter/awss3: @atoulme @pdelewski. See Adding Labels via Comments if you do not have permissions to add labels yourself.

atoulme commented 6 months ago

This is because in some cases (minIO, storJ) I believe the endpoint can be completely different from what s3 expects, and the bucket is dropped.

Yes, we can make bucket required only if endpoint is not set.

github-actions[bot] commented 4 months ago

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.

atoulme commented 4 months ago

I think this was addressed by #32815. Closing.