question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

http4s-reactive-streams module

See original GitHub issue

We discussed at the NE Scala Symposium ways for various libraries to abstract over fs2.Task and monix.eval.Task, both of which have a lot to like and a lot of people who like them. For us, it’s possible to abstract away Task, but significantly raises barriers to writing middleware or even composing library-provided building blocks. Far more difficult would be abstracting over Stream, which would require a separate branch, which we are moving away from.

However, a module with entity codecs for monix would offer a nice solution. Just like we support Ok(scala.concurrent.Future("hello")), we could support Ok(monix.eval.Task.eval("hello")). Similarly, an Ok(observable) or Ok(iterant) could be converted to an EntityBody. It would require a monix support import and some runtime conversion, but I imagine this results in a more pleasant Monix experience alongside fs2 than any extra abstractions we’ve imagined to support Monix without fs2.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:5
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
rossabakercommented, May 16, 2017

It will handle Monix Task. It won’t handle Observable, but a reactive streams module would pick up both that and akka-stream.

0reactions
armanbilgecommented, May 1, 2022

This issue reads to me a lot like a monix-http4s integration, and there’s no Monix you can use alongside CE3 (yet). akka-stream is interesting but seems unlikely use-case IMHO since they have akka-http. Closing but of course if there is interest this can pop up as a new repo at anytime.

Read more comments on GitHub >

github_iconTop Results From Across the Web

http4s/http4s - Gitter
@Pyppe use the reactive-streams module of fs2 to get them into an fs2 Stream , which can be streamed natively by http4s. Pyry-Samuli...
Read more >
Changelog - http4s
This release is the latest milestone in the 1.x series, and is not binary compatible with previous 1.0 milestones. It also includes the...
Read more >
Exploring ZIO - Part II - ZStream and modules - SmartJava
Real REST endpoint: We'll connect the HTTP4S endpoint to the MongoDB server to ... to create streams and to interact with reactivestreams.
Read more >
http4s-jdk-http-client_3 : 1.0.0-M1 - Maven Central Repository Search
Home page, https://http4s.github.io/http4s-jdk-http-client ... @Grapes( @Grab(group='org.http4s', module='http4s-jdk-http-client_3', version='1.0.0-M1') ).
Read more >
How (not) to use Reactive Streams in Java 9+ | by Jacek Kunicki
Reactive Streams is a standard for asynchronous data processing in a ... client (which was in the jdk.incubating.http module in Java 9/10, ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found