Reputation: 10152
When I first step into reactive programming in Android I found rxJava and rxAndroid which prefer by many developers in the world. But today I found another library called Agera of Google which still in maintain process (last commit is 2 months ago).
It looks like rxJava at first glance, but has more meaningful api names which help me easy to understand reactive programming. More important, awesome developers at Google is using it in their project (Google Play Movies) and I believe there is reason for that.
I want to know whether Google Agera supposed to be more light-weight? And how about the performance compare to rxJava and rxAndroid? Is there any big company use it in production? Did I need to learn it to understand reactive programming in Android?
Upvotes: 3
Views: 987
Reputation: 13321
A nice comparison from David Karnok (RxJava maintainer) can be found in the issues on Github.
I've glanced over the documentation and my impression is that Agera is almost a 1st generation reactive library with strong 0th generation ties. To put it in perspective:
0th generation is when you have addListener/removeListener and update() with or without an actual value. java.util.Observable and most GUI frameworks can be considered 0th gen. It is possible, although generally cumbersome to make a composable, native library out of them.
1st generation is what the Microsoft folks invented back in ~2009. It's a step upwards with straightforward architecture and great composability. However, their concept has some shortcomings discovered in late ~2013. Example: Rx.NET, Reactive4Java
I know this is an optional library, don't use it if you don't like it. Don't get me wrong, it's not about how many operators you have, how strong do you inline your reactive library with the underlying platform or that you don't care about backpressure in GUI. It's about the architectural experiences, pitfalls and possibilities of the Rx family that maybe could have helped/inspired this library. If Agera were based on Reactive-Streams or designed in spirit of it, I'd say okay, why not.
As for the original questions:
Isn't it RxJava reinvented?
No.
Is it supposed to be more light-weight?
Seems so API-vise, not sure about performance-vise
Complementary?
As complementary as addListener-based APIs are in general. The name conflict of Observable and Supplier may be of some inconvenience.
Or just inspired?
Apparently not inspired by Rx.
Google Play Movies and we like to open source code whenever possible
In Netflix' footsteps I see. You see, they got significant help along the way...
Upvotes: 7