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

Streaming API for existing on-disk storage #124

Merged
merged 22 commits into from
Apr 30, 2024
Merged

Streaming API for existing on-disk storage #124

merged 22 commits into from
Apr 30, 2024

Conversation

ikatson
Copy link
Owner

@ikatson ikatson commented Apr 25, 2024

I was playing around yesterday to see how we would go about implementing #110

Although a full stream-from-memory would require a very different API, and re-assembling components in a novel way, I first tried to make an API that would stream an existing file from disk and:

  • block the stream unless pieces are available
  • prioritize streamed pieces

This made it possible to play those URLs in VLC and "ffplay", and even seek, jump around.

This might be useful if you are planning to store the file eventually anyway.

As for streaming from memory, will try to do sometime later.

This one isn't complete yet though:

  • need a bit more polish and testing. Maybe simplification.
  • it doesn't stream the file unless it's checked for streaming
  • need to wake up peers that are waiting for things to do if we start/seek a stream

@ikatson ikatson force-pushed the streaming-2 branch 3 times, most recently from f3c12cd to ebd6c88 Compare April 29, 2024 19:15
@ikatson ikatson marked this pull request as ready for review April 30, 2024 20:43
@ikatson ikatson merged commit 5cac8ac into main Apr 30, 2024
4 checks passed
@ikatson ikatson deleted the streaming-2 branch April 30, 2024 20:45
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

Successfully merging this pull request may close these issues.

1 participant