Skip to content

S3RangeReader path wrongly created: exception on spaces and not using AWS_S3_FORCE_PATH_STYLE #323

@jaimeferj

Description

@jaimeferj

In this commit: 2d3f75c, AWS_S3_FORCE_PATH_STYLE was introduced to support s3 path style endpoints.

  1. The problem comes when, after having send an url encoded url to create a it.geosolutions.imageioimpl.plugins.cog.S3RangeReader, when it.geosolutions.imageioimpl.plugins.cog.S3RangeReader#getURL is called, configProps.getKey() is the "in-bucket" path already stringified, so we have lost the url encoding, making the URL conversion fail because of invalid characters.
  2. Moreover, when reading how the URL is constructed, you can clearly see that AWS_S3_FORCE_PATH_STYLE is not taken into account, and that the subdomain url is built always.

More precisely, I have been trying to make Geoserver work with MinIO locally so I can test a service I am building. The thing is that I am using an ImageMosaic store in which I add coverages and then publish them using filters and those errors came by.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions