Skip to content
This repository has been archived by the owner on Aug 30, 2018. It is now read-only.

Reader cannot use streams for the seek method #142

Open
chekanov opened this issue Jul 31, 2018 · 1 comment
Open

Reader cannot use streams for the seek method #142

chekanov opened this issue Jul 31, 2018 · 1 comment

Comments

@chekanov
Copy link
Contributor

Hi, David

It looks like the class proio/Reader.java cannot use the method seekToStart for streams (it works only for local files).
This creates a problem for random access of events using URL (the method skip() is not sufficient for this). Can you add a support for streams in the seekToStart() method?

best, Sergei

@decibelcooper
Copy link
Owner

Hi Sergei (@chekanov). What you describe is inherent to the fundamental design of ProIO. Streams are inherently not seekable, and ProIO has a major focus on being compatible with streams. In order for a stream to become seekable, it must be buffered, either partially or entirely (buffering an entire stream is just downloading, of course).

I tend to agree that supporting stream buffering would be beneficial. I will work on a way to do this that can be applied generally.

Thanks for the Issue, and I'll get back to you on this soon!

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

No branches or pull requests

2 participants