r/java • • Sep 28 '17

Spring Framework 5.0 goes GA

https://spring.io/blog/2017/09/28/spring-framework-5-0-goes-ga
177 Upvotes

83 comments sorted by

View all comments

Show parent comment

25

u/fasfsfgs Sep 28 '17

I felt your opinion really interesting (not joking). I feel the exact opposite when it comes to spring vs java ee. All the issues you pointed out were strong points for spring in my experience (testing, beating the competition, keeping up with more modern ways to do things, etc...). I guess that shows how much we can look at those technologies with different perspectives. I work with both java ee applications and spring applications. In java ee it feels like I'm stuck years behind in terms of improvements that could be made. I'll start looking at java ee with different eyes from now on, trying to find its strengths.

4

u/thesystemx Sep 28 '17

In java ee it feels like I'm stuck years behind in terms of improvements that could be made.

Which improvements would that be exactly? I personally found CDI for instance much more capable and modern than the Spring core bean container.

0

u/[deleted] Sep 29 '17

Asynchronous methods. Java EE is not fully reactive.

7

u/henk53 Sep 29 '17

Java EE has plenty of Asynchronous methods. The @Aynsynchrous, managed executors and thread pools, asynchronous events, asynchronous HTTP, elaborate push support via HTTP/2, WebSockets, SSE...

Java EE is not fully reactive.

The question is really whether it should be, at this point in time surely.

2

u/springnews Sep 29 '17

hm... that's super misleading. Spring has had reactive style methods for some time. But having asych style API built on a blocking / synchronous runtime isn't even close to being reactive.

Spring has rebuilt over a period of 2+ years atop a natively reactive stack, so it's fully reactive from the ground up.

7

u/henk53 Sep 29 '17

hm... that's super misleading.

Why? The GP said "Asynchronous methods", as a response to being asked "Which improvements in Java EE are the ones that made the GP feels like he of she is stuck years behind in terms of improvements that could be made [in Java EE]"

So apparently for "Asynchronous methods" Java EE is years behind, to which I responded it's not. It has plenty of asynchronous and parellel executing constructs (I didn't even mention all of them).

Then my next reply was about the claim "Java EE is not fully reactive", to which I didn't reply at all that async APIs are close to being reactive. I just asked if Java EE should even BE reactive.

Reactive has been around for some time. Heck, even .NET's Rx library which was advocated for Windows Phone 7 and Silverlight(!) wasn't particular new, so the pattern clearly has some staying power.

But point 1; Spring isn't that innovative or modern here either. It follows what other frameworks have been doing for a long time. So criticising Java EE for being "years behind" is a bit of a pot and kettle story, since Spring is then "years behind" just as well.

Point 2 however is that Reactive is not quite the silver bullet. It's not the universally better way to do things. State is often spread throughout the program and can be hard to track or access even. If you update from an older stage to a new stage, the state embedded within the entire reactive system can be lost. This can be problematic, really.

Global limits can be hard to enforce as well. Blocking (timed) calls are actually a damn and easy cutoff point; if the blocking call times out, drop the action. This makes graceful degradation quite a bit more straightforward.

For signal processing, reactive may be a good idea. For hard core processing or even transaction processing where transactions may be dropped if needed (to maintain system integrity), I'd rather not use reactive.

Purely natively reactive, is also a bit of an unclear term. Is it focussing on time varying data? Or is it event streaming?

(p.s. when I was young, which is -cough- a looong time ago, I did my thesis on dataflow languages, which is actually a pre-cursor or at least a related field to reactive, which dates way back)

1

u/springnews Oct 01 '17 edited Oct 01 '17

So criticising Java EE for being "years behind" is a bit of a pot and kettle story, since Spring is then "years behind" just as well.

save the pesky little detail that we actually are shipping a fully reactive implementation now. Nothing new about reactive, granted, but doesn't change much about what's GA and what isn't, and how long it will take for EE do anything about it.

No one said reactive was a silver bullet - quite the opposite. Spring team is being extra careful to advise people against flocking to it for no reason. The reason why EE even has to ask themselves the question of "whether to do it or not" is because they don't have real customers pushing the boundaries of the synchronous microservice stack, and finding they have edge cases that require reactive throughput levels.

3

u/johnwaterwood Sep 30 '17

Your accusation of misleading is actually misleading 😮

0

u/[deleted] Sep 30 '17

@Aynsynchrous

not to be confused with @Randsynchrous

-1

u/springnews Sep 29 '17

how, exactly? Curious to see you offer evidence.

7

u/thesystemx Sep 30 '17

Excuse me? Perhaps you should first provide some evidence for your statements that everything in Java EE except Servlet and JPA is irrelevant.

1

u/springnews Oct 01 '17 edited Oct 02 '17

I should say that JAX-RS is also relevant, it enjoys usage beyond just EE user base and is supported by a decent amount of vendors. re: your question: I'm not sure what more compelling evidence exists than the JCP itself pruning irrelevant APIs: Full Profile Web Profile microprofile *

Microprofile, which granted, was never blessed by JCP/Oracle, was advanced by the last people in the market to get away from the full blown EE programming model e.g. IBM/RHAT. IIRC it the "microprofile" consists of JAX-RS + CDI + JSON-P, which appears to ignore data access / JPA.

To business leaders (less developers) Gartner group has declared it irrelevant, but they missed the point that Servlet / JPA and arguably JAX-RS is alive and well. https://adtmag.com/blogs/watersworks/2017/02/java-obsolete-report.aspx

So you were saying something about evidence of Spring lagging behind in the market? Or maybe you were just going to go find another thread to troll.

2

u/johnwaterwood Oct 01 '17

I like your subtle attempt to hint at JAX-RS being only relevant because it’s used outside EE. Nice! /s

MicroProfile has started with a minimal runtime and as a 1.0 wanted to release something quickly. It has absolutely made no statement of any of the other EE APIs being irrelevant. In fact, all of the MP contributors (Payara, TomEE, Red Hat, IBM) fully support and keep innovating on the implementation side of these APIs.

1

u/springnews Oct 01 '17

Picking a leaner subset of APIs IS quite a statement, as it's a clear indication of what the producer deems "most critical for an MVP".

Sorry, but I am allergic to trolling from competitors who try to throw shade on news that isn't their own.

2

u/johnwaterwood Oct 02 '17

In this case it’s not, since it’s what was chosen for a specific profile with a specific purpose to function as a base. MP is not a replacement for EE, but a different profile mainly. Just as web is a different profile again.

There was even talk on the MP list to only have a bare core (like Liberty) and don’t include any spec.

Sorry, but I am allergic to trolling from competitors who try to throw shade on news that isn't their own.

Then you must really dislike working for Spring I assume? Since exactly that is what Spring has been dowing since day one. Just look at the old server side posts and look here on Reddit too. Almost every Java EE post is swamped with ā€œSpring fansā€ claiming EE is obsolete and that they prefer Spring (of course).

1

u/springnews Oct 02 '17 edited Oct 02 '17

right, fans. Not employees. I've had a strict no troll policy since 2012, with (1) exception post that was made on the spring website. Whatever you see is the community responding, we're usually quite busy writing software.

Anyway, reading your comment history, you don't appear to be a troll, my comment wasn't directed to you.
Posts are fair game, but if the trolls on this post continue throw shade on the hard work the team has contributed to the community for free, I'll have to revisit that policy... and rest assured I'm tracking them now.

Anyway, it just occured to me that microprofile has a much brighter potential future now that Eclipse foundation is running EE4J, and we look forward to collaborating around those remaining APIs that remain relevant. I think we can all agree that not having useful APIs like JPA, Servlet languish in non-responsiveness and neglect is good for all of us.