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

Add module for streaming with iteratees [WIP] #557

Closed

Conversation

travisbrown
Copy link
Collaborator

This is just a sketch (from experiments at the Typelevel summit last week) but I wanted to go ahead and open a PR to track it. Needs tests and examples, and it should be a little cleaner and more efficient to bypass AsyncStream and use Reader / Writer directly.

@codecov-io
Copy link

Current coverage is 79.33%

Merging #557 into master will not affect coverage as of 32a513d

Powered by Codecov. Updated on successful CI builds.

case (_, a) => f(a)
}

implicit final val enumeratorToResponse: ToResponse[Enumerator[Future, Buf]] =
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Given that we now have Encode.ApplicationJson can we write that in a generic way and convert Enumerator[Future, A: Encode.ApplcationJson] into streamed JSON array? I mean we can have both Buf and A: Encode.ApplicationJson defined here.

@vkostyukov
Copy link
Collaborator

vkostyukov commented Nov 8, 2016

Going back to this.

I think it would be totally awesome if we could include this into finch-circe (like Circe support in Finch comes with built-in iteratee-powered streaming). I think we have all the required machinery now (including Decode and Encode type-classes parametrized with content-types) to make this happen.

What do you think @travisbrown?

@travisbrown
Copy link
Collaborator Author

@vkostyukov Sounds good to me, if you don't mind the extra iteratee.io dependency for finch-circe. I might not get a chance to get things updated until after Scala by the Bay, though.

@vkostyukov
Copy link
Collaborator

I'm closing this as @imliar took good care about iteratee in #812.

Thanks @travisbrown for the inspiration and sharing your ahead-of-time perspective!

@vkostyukov vkostyukov closed this Aug 23, 2017
@travisbrown
Copy link
Collaborator Author

Yes, thanks @imliar—it's great to see this get merged!

@sergeykolbasov sergeykolbasov mentioned this pull request Oct 8, 2017
9 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants