r/java • • Sep 06 '17

JavaEE is now on GitHub

https://github.com/javaee/
203 Upvotes

64 comments sorted by

View all comments

Show parent comments

1

u/aretebit Sep 07 '17

Lol sorry I meant latest Java EE, not the last one. Java EE replicated everything from Spring because their job is set the standard and Spring became the defacto industry standard (and pretty much still it is). For example Java EE CDI is Spring core, MVC is Spring MVC, Batch is Spring Batch, etc.

1

u/henk53 Sep 07 '17

/u/aretebit are you going to explain yourself further?

1

u/aretebit Sep 07 '17

What do you want me to explain further? Is my word against yours. If you lived those times when everyone left java ee for Spring (absolutely everyone, the only one job offers for java ee were for maintaining code, because of how awful it was) you couldn't deny my statements. Oracle saw that the founder of Spring was right and they had to adopt Spring's features to survive. My answer is: Yes really. If you do not believe me go and argue against wikipedia guys becuase I have better things to do that argue with dogmatic people: "Starting from Java EE 6, Java EE is trying to incorporate and standardize concepts/features from and merge with Spring framework. The SOAP with Attachments API for Java (SAAJ) is now part of Java SE 6, and is thus available to Java EE 6 applications without needing to be included in the EE specification.[1] The Java API for RESTful Web Services (JAX-RS) is now included in Java EE.[2] Java EE 6 also standardized DI, AOP and others from Spring into Contexts and Dependency Injection for Java, Dependency Injection for Java, Bean Validation, Managed Beans, and Interceptors." (from: https://en.wikipedia.org/wiki/Java_EE_version_history).

Even Oracle people shows gratitude: "Thank you Spring framework for filling the interim gap and providing functionality that is now included in the mainstream Java EE 6 application servers. The Java EE platform has evolved over the years learning from frameworks like Spring and provides all the functionality to build an enterprise application. Thank you very much Spring framework!" (from: https://blogs.oracle.com/arungupta/why-is-java-ee-6-better-than-spring)

My answer is yes really, in java ee they simply copied what was working with spring because it became extremely popular and java ee clearly failed. And yes really, it became de facto and still it is in some grade, if you do not believe me read the first page of "Learning Spring Application Development" by Ravi Kant Soni (2015) which says: "Spring is now a long-time de-facto standard for Java enterprise software development."

CDI is a cheap copy of spring IOC. I am not talking about the invention of DI nor batch, is the way of doing it, and they just decided catch it because it became very popular in spring.

Sorry I am not active user and don't know/ can't format this text nicely.

2

u/henk53 Sep 08 '17

/u/aretebit a vague statement on Wikipedia is not necessarily right of course. It likely reflects an opinion of a Spring fan who thinks juist like you. I don't see a reference there that proves that statement.

The problem is that people all too commonly parrot each other and the urban myth is strong that Java EE supposedly took so much from Spring.

Now Spring has undoubtedly influenced Java EE, especially the developers first approach. But specific technologies, less than you think.

JPA for instance was based on TopLink and Hibernate. It's not a Spring invention nor technology.

CDI is NOT a cheap copy of Spring. You probably don't know CDI well. As explained here already; CDI was inspired by JSF Managed Beans, EJB, Seam and Guice.

The scopes (request scope, session scope, application scope) came directly from JSF. The named aspect of beans and the ability to reference them from Expression Language came directly from JSF as well. The proxy concept and the interceptors came from EJB, in fact the interceptor spec is still part of EJB. The annotation approach came from EJB as well. EJB started with the very simple @Stateless annotation vs a ton of XML in some file.

So while it's undoubtedly popular among Spring fans to give Spring credit for all those things, if you look in history it's just not true.

Then take a look at other popular Java EE technologies. Expression Language... not a Spring invention either. It originates from an Apache JSP library which later became JSTL. Didn't Spring actually copied that in Spring EL?

Bean Validation... not a Spring invention either. It came from Hibernate.

JTA... again not Spring, this is based on quite old code from IBM from even before Java 1.0 (~1995).

JAX-RS, not really Spring either. You could argue it looked at Spring MVC and Spring MVC influenced it, but JAX-RS goes way beyond Spring MVC and is overal clearly the better REST API.