-
Notifications
You must be signed in to change notification settings - Fork 18
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
Support data URIs in load_url
#498
Comments
I can cook up a PR for this is there is more interest for this feature |
Interesting! There will be the risk to create heavy process graphs probably, but the same happens with inline geoJSON anyway. Good to have another option and happy to try to support it. |
Indeed, we already had issues with users embedding huge GeoJSON constructs in their process graph, so this would not create a new problem. As a matter of fact, the textual representation of GeoJSON makes it very space-inefficient and data URLs could improve the situation because of binary encoding and compression. But still, it could be the responsibility of the clients to put reasonable thresholds on this and warn about or forbid excessive payloads |
This needs more investigation:
|
Another use case where data URIs could be part of the solution: users that want to work with sensitive/private (vector) data in non-geojson format that can not be hosted on a public URL. |
As geojson is limited to using lonlat, this feature would now allow users to pass geometries in a different crs to an openEO backend. |
Any thoughts or updates on the questions raised in #498 (comment)? |
Yes, that's true, base64 encoding has this "expanding" property, but I don't think this is a concern to worry about at the level of the openeo-processes. This feature is intended for "small data" use cases (e.g. a single or a couple of polygons in non-EPSG4326 projection). And when users might accidentally use oversize payloads: there is enough opportunity to raise warnings/errors client side. Also note that GeoJSON itself is actually pretty poor in terms of size efficiency (e.g. a single float value in JSON easily consumes 15 or more characters), so a base64 encoded binary format might actually even be smaller than GeoJSON.
Indeed, it should be aligned with
I don't see them as different enough to create a separate process . In the web dev world they seem to be used interchangeably (typically to embed images) without much trouble.
what kind of tooling are you worried about here?
yes, I would also think it's best to require both |
load_url
currently only supports HTTP(S) URLs:openeo-processes/proposals/load_url.json
Lines 12 to 19 in 965bbae
For a use case we were brainstorming about avoiding the overhead of creating/managing external URLs (for a lot of small files) and came to the idea to load from data URLs where the data can be embedded in base64 inside the process graph, without need for external files/URLs. E.g.
The text was updated successfully, but these errors were encountered: