Comments (3)
Maybe an option in godal.RegisterVSIAdapter to prevent stripping the scheme would be a bit more generic?
from osio.
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.
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
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from osio.