Hacker News new | past | comments | ask | show | jobs | submit login
Reactive Streams for the JVM hits 1.0.0 (reactive-streams.org)
71 points by rozza on May 7, 2015 | hide | past | favorite | 17 comments



I think the Java community has done something really amazing here. As a C# fanboy it's hard for me to admit, but while reactive extensions have been in the C# ecosystems for much longer - it seems like a wide variety of vendors lined up backing Reactive Streams in Java in their drivers (where there aren't a lot of vendors backing up their kind words with an Rx implementation in C#). Nice work.


Looks like theres strong interest for a similar improvements coming in C#7 (Async streams and disposal https://github.com/dotnet/roslyn/issues/2136)


I remember seeing a talk on this around a year ago, and while it did have some important backing and solve some interesting problems, there wasn't much in terms of examples of people using it in production.

Is this still the case? I guess with it hitting 1.0 it's more likely now, but I'd still be interested to hear if anyone's had much experience with this up until now.


Reactive Streams are just interfaces meant to make interconnection and usage of different libraries easier and faster. The document is meant to avoid the well famous "similar library, different names for same concepts". There's nothing more than that.

In the same page you can find a list of compliant implementations like AKKA or RxJava, so you can easily check out one of them and see how they are implementing these concepts under the hood. The general purpose is good, it makes the switch from framework X to Y easier with the declared goal of provide a standard for asynchronous stream processing with non-blocking back pressure, but, as said before, there's nothing more than that.

About the production, well, some of the listed libraries are widely used, so I guess there are a lot of people actually using this concept in production.

Then, if you want to go further, you can search for Duality, that seems an evolution of Reactive Programming and Reactive Streams.


For evidence of people in production now, you will find more users of RxJava which has been providing similar functionality for a while (including backpressure support).

I think this convention is one for the future and this release marks the start of adoption. I think the hope is that more implementations will come in the future and one goal is to allow the simple connection of reactive streams and allow the building complex distributed systems.

Also interestingly it looks like this concept might make it into jdk9 as Flow - https://github.com/reactive-streams/reactive-streams-jvm/iss...


I don't think it's meant to be used directly. It's a minimal api (just 4 interfaces) that can be used by various reactive frameworks to interoperate with eachother.


While this looks very interesting, and I'll probably push for using it in production shortly, I can't help but wonder what some of their marketing talk even means.

non-blocking back pressure

How does that even relate? All I can think of is sticking a potato into a car exhaust.


That's not a marketing talk but an important technical term instead. See this for a quick reference: https://github.com/ReactiveX/RxJava/wiki/Backpressure . It is important to understand before even thinking about using reactive streams in production.


It is absolutely marketing talk, there's other established terms for what that means but they elected to make up other terms. Perhaps they should take the lesson from this talk where they explicitly break down this exact term and explain what they REALLY mean in common terms.

https://www.youtube.com/watch?v=pOl4E8x3fmw


> there's other established terms for what that means

Please could you expand on this?


Did you try googling, from a quick glance it looks like results 4-6 are relevant.


This is a great vision, but without trying to be a jerk, I have to wonder: isn't this just a restatement of what Erlang/OTP has been doing for at least 20 years? I haven't learned the language yet, so it's a serious question.

And if you want "Erlang validation" it's hard to beat WhatsApp's $19B acquisition. (I doubt that Facebook will be releasing any open source Erlang code any time soon!)

So what's the deal? If you believe in the http://www.reactivemanifesto.org/ wouldn't you be better off just biting the bullet and learning http://www.erlang.org/?


What does this have to do with Erlang? As far as I know, Erlang doesn't have a concept of a "stream" nor any particular mechanism for handling back-pressure.


This is good for existing-Java ecosystems. Not everyone can just up and full-rewrite into a new language!


More importantly, these kinds of developments bring the features of hipper, HN-popular languages to the multitude of enterprise Java devs who will likely never be approved to write anything in Erlang, green field project or not.

It's always a good thing when a mainstream language gets better - it positively impacts a lot more people who don't get to use niche languages for their work.

EDIT: My grammar and spelling suck first thing in the morning.


I haven't used erlang - that said, one reason might be that it's dynamically typed by default, and that the extensions for a type system have had mixed success:

"Phil Wadler and Simon Marlow worked on a type system for over a year and the results were published in [20]. The results of the project were somewhat disappointing. To start with, only a subset of the language was type-checkable, the major omission being the lack of process types and of type checking inter-process messages."

http://learnyousomeerlang.com/types-or-lack-thereof#for-type...


v1.0.0#specification reads: > Or another implementation could fuse the operations to the final consumer: > nioSelectorThreadOrigin | map(f) filter(p) consumeTo(toNioSelectorOutput)

Having control over how to fuse a chain of functions is very interesting. Do any of the implementations allow use of mutable state when fusing a chain of functions with the same signature.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: