Skip to content
This repository has been archived by the owner on Jun 20, 2024. It is now read-only.

start and endcoordinate requests sometimes return too much data. #329

Closed
viklund opened this issue Nov 2, 2023 · 0 comments · Fixed by #347
Closed

start and endcoordinate requests sometimes return too much data. #329

viklund opened this issue Nov 2, 2023 · 0 comments · Fixed by #347

Comments

@viklund
Copy link
Member

viklund commented Nov 2, 2023

Running with the starter-kit-storage-and-interfaces demo docker compose we can find start and end coordinate combinations that return too much from the files endpoint (the same is also true in the s3 endpoint). This is using the s3 backend storage.

In the first example below, we get the correct number of bytes and in the second we get too many, even though start coordinate only increased by 10. And then increasing startCoordinate by another 10 it returns correct number of bytes again. It is not that it returns a lot when too big range is requested, it more seems to be where in the file the request is made.

$ token=$(curl -s -k https://localhost:8080/tokens | jq -r '.[0]')
$ curl -H "Authorization: Bearer $token" -k 'http://localhost:8443/files/EGAF74900000001?startCoordinate=60&endCoordinate=110' | wc -c
50
$ curl -H "Authorization: Bearer $token" -k 'http://localhost:8443/files/EGAF74900000001?startCoordinate=60&endCoordinate=120' | wc -c
32768
$ curl -H "Authorization: Bearer $token" -k 'http://localhost:8443/files/EGAF74900000001?startCoordinate=70&endCoordinate=120' | wc -c
50
@blankdots blankdots linked a pull request Dec 14, 2023 that will close this issue
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant