Jay13
Jay13

Reputation: 920

Autodesk Forge Data Management API Resumable Upload fail on files over 2GB

When uploading very large files over 2GB I am receiving the error;

(416) Requested Range Not Satisfiable.

I was encountering it with .Net API so I tried it with the REST API and I get the same error there. This makes me think that the Forge filesystem may be 32bit which doesn't support files larger than 2GB or maybe the REST API code for resumable defines the range values as int and can't handle a value greater than 2147483648. I've looked for a max file-size limit in the documentation but didn't find one.

Has anyone else encountered this problem or better yet, found a way around it? My file is already zipped so that's not a solution in this case.

Upvotes: 0

Views: 123

Answers (1)

Jay13
Jay13

Reputation: 920

Doh, I found the issue. I was on the right track with the code using an int rather than a long, but it was my code at fault. I would have expected an error when an int gets set to a value exceeding it's max value but that isn't the case so when the range string was calculated I ended up with;

bytes 2139095040--2124414977/3221225472

when I was expecting;

bytes 2139095040-2170552319/3221225472

I suspect the C# code I was updating came from a sample somewhere on the internet so I guess it's worth leaving this question and answer in place, hopefully it will help someone else that runs into the same issue.

Upvotes: 1

Related Questions