Skip to content
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

Watson.Lite : Partial Range Requests status labeled as Internal Server Error 500 despite being handled fine. #135

Open
GitHubProUser67 opened this issue Jan 26, 2024 · 4 comments

Comments

@GitHubProUser67
Copy link
Contributor

GitHubProUser67 commented Jan 26, 2024

In Watson.Lite, due to it's reliance on an external TCP service, allows for partial range request handling via some customised code.

However, said code, despite working fine, for some reasons print error 500 in the console logs:

image

image

Here is the demonstration of a movie streaming system in https using Watson.Lite, as you can see, works perfect, despite status 500 in the console.

Note, due to the non-lite version relying on httpListener, it is impossible to handle range request on this backend, it could be neat to indicate this in the documentation if someone wanna use it is a backend project.

@GitHubProUser67
Copy link
Contributor Author

GitHubProUser67 commented Jan 26, 2024

After more testing, it can happen sometimes that it does print 206:

image

My theory is that this logger only keep tracks of finished requests, effectively sending an internal server error on a dead connection, but a range request can massively bound the interface and actually uses the same wire for multiples chunck of data, which it seems Watson.Lite is not having any issue with.

@jchristn
Copy link
Collaborator

Please share the code you have for your default request handler - seems that is where this content is being served from, correct?

@jchristn
Copy link
Collaborator

Also - range requests should 100% be supported. You would have to parse the header NameValueCollection to get access to the Range header and handle it manually. Content routes do not support it today, though.

@GitHubProUser67
Copy link
Contributor Author

Here is the code : https://github.com/GitHubProUser67/MultiServer2/blob/main/HTTPSecureServerLite/LocalFileStreamHelper.cs

So what happens is that, the handling of the range is done outside of the API itself, rather I use the API as a transmiter.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants