GitHub user ptrdom added a comment to the discussion: 
`StreamConverters.asInputStream` not workable when using broadcast with 
`ByteString` source?

> Can you elaborate on this? To me StreamConverters.asInputStream is exactly 
> what I need, or to put it differently if I was to write a function where I 
> want to convert a Souce[ByteString, _] to InputStream, its function 
> design/signature would look very similar.

IIUC your goal is to stay in streaming, to take `ByteString` elements, 
accumulate them until `Tika().detect` returns and then push the output 
downstream. `StreamConverters.asInputStream` is a sink, so its goal is to 
materialize the stream into a result, so that is not about staying in 
streaming. Having all this in mind it does not look like using a sink, 
specifically `StreamConverters.asInputStream`, is a right tool for the problem, 
I would use a graph stage or a flow, to stay in streaming.

I am just suggesting an alternative solution, if you want to improve/fix 
`StreamConverters.asInputStream` then this discussion can be about that, it 
just was not clear to me whether you want to improve/fix 
`StreamConverters.asInputStream` or just solve your task.

GitHub link: 
https://github.com/apache/pekko/discussions/1807#discussioncomment-12591802

----
This is an automatically sent email for notifications@pekko.apache.org.
To unsubscribe, please send an email to: 
notifications-unsubscr...@pekko.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscr...@pekko.apache.org
For additional commands, e-mail: notifications-h...@pekko.apache.org

Reply via email to