Git Product home page Git Product logo

Comments (3)

tbonfort avatar tbonfort commented on September 24, 2024

Maybe an option in godal.RegisterVSIAdapter to prevent stripping the scheme would be a bit more generic?

from osio.

thomascoquet avatar thomascoquet commented on September 24, 2024

Maybe the best would be to always feed the scheme/protocol and let the underlying handler do the TrimPrefix if needs be?
I'd argue that the protocol (http/ https, ftp/ftps) is semantically fully part of the "key".

This would not break existing implementation as the scheme is systematically stripped if it exists (https://github.com/airbusgeo/osio/blob/main/uri.go#L19).

from osio.

tbonfort avatar tbonfort commented on September 24, 2024

In gdal world, the prefix is only used to register a handler, and is not part of the key (e.g., you use /vsicurl/https://server/path), so it is customary for gdal to drop this prefix when forwarding to the underlying handler. In our case we are using the prefix in both ways, thus the mixup we have here.
In theory, in order to not break backwards compatibility we should add a StripPrefix() option to godal.RegisterVSIAdapter that defaults to true. I believe that the use-case is sufficiently widespread that we can tolerate it defaulting to false, and make sure that all osio adapters gracefully handle the prefix://bucket/object and bucket/object keys ( which I believe it the case ). Are you willing to submit a PR to godal for this ?

from osio.

Related Issues (5)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.