Link Details

Link 1170067 thumbnail
User 1216193 avatar

By bball
via java.dzone.com
Published: Jun 20 2014 / 10:56

I never thought that I have to write about this topic again, but I have to since a couple months ago I have to justify a decision of using Spring Framework in an enterprise environment. The decision to be made was whether we are going for JEE or using Spring Framework. The constraint was very clear:
  • 9
  • 4
  • 777
  • 3811

Comments

Add your comment
User 776377 avatar

lburnham123 replied ago:

2 votes Vote down Vote up Reply

It's perfectly possible to use Spring APis and JEE APIs within the same container, so I don't follow the rationale for "dumping [the] JEE standard". It sounds like you're mostly talking about problems raised by the use of old-style EJBs, but those are just one part of many in the JEE stack.

User 57404 avatar

ld89125 replied ago:

-2 votes Vote down Vote up Reply

This is not what I'm talking about. I'm saying that you cannot mix and match APIs and implementations within one JEE container without using something like Spring Framework. Just try to use JPA 1.0 in one web app and JPA 2.1 in another web app within the same JEE container (Weblogic, JBoss). It could work but always with hack. Just google it you'll find some problems I mentioned.

User 157014 avatar

rrahman replied ago:

3 votes Vote down Vote up Reply

Actually this is not correct at all. In fact, you can switch JPA versions in an application by specifying a version number in the descriptor. In reality, there is little reason to do this as you can simply not use newer features - because of backwards compatibility guarantees in Java EE, doing so is perfectly fine.

User 57404 avatar

ld89125 replied ago:

1 votes Vote down Vote up Reply

Please see my reply in the article. This is not about backward compatibility, it's about forward compatibility. This is about traditional operation which is slower to upgrade the app server and the development which needs to use the up-to-date APIs. If you are using the old OAS 10.x or Weblogic 10.x it is hard to be able to use JPA 2.1.

User 157014 avatar

rrahman replied ago:

1 votes Vote down Vote up Reply

I would say this is a Spring theology driven solution looking for a problem rather than an actual problem requiring a solution. If you can't rely on backwards compatibility, simply install a new runtime separately and put newer applications there. This is precisely users of widely used runtimes that focus on ease-of-use like Java EE, .NET, Rails and Play! don't have this supposed "problem" and focus of writing application code instead of creating custom patched application environments.

User 57404 avatar

ld89125 replied ago:

-1 votes Vote down Vote up Reply

But this is all about in my article. I'm writing the article because I always meet this such a problem (at least in my 10 years JEE experience). This is a general problem in JEE environment. Forward compatibility is never on focus in this whole JEE stuffs. IMO, forward compatibility can be reached by removing JEE umbrella standard + concentrating on Servlet / Web Container + decouple all the APIs. That's all I want to say. Spring Framework is only one framework which can support me going to this direction. My hope is that in couple of years you will be able to support such a requirement in Java world with or without Spring Framework.

User 157014 avatar

rrahman replied ago:

1 votes Vote down Vote up Reply

If anything the Spring model is very outdated. As you've apparently now acknowledged, every other modern solution including Java EE, .NET, Rails and Play! don't support that model because it gets in the way of ease-of-use. In fact, no mainstream platform including Spring supports forwards compatibility as it results in unpredictable and possibly incorrect behavior at runtime. I think you need to perhaps build better DevOps based relationships with your operations folks. A big part of their daily job is installing and updating software and it is highly unlikely to be a real problem if you have any real degree of decision making authority in your organization.

User 57404 avatar

ld89125 replied ago:

-1 votes Vote down Vote up Reply

Hmm don't sure whether I understand you correctly. IMO JEE umbrella is the one which is outdated and need to be removed. Using just Tomcat or Jetty (Servlet + Web container) + APIs (JPA, JMS, ...) + the correct implementations (Hibernate, ActiveMQ, ...) + Spring Framework allow me to be "forward compatible" and support me to be able to carefully update my production environment. And this is at the moment the one and only choice you have if you are in a traditional operation business.

User 157014 avatar

rrahman replied ago:

-1 votes Vote down Vote up Reply

The reality is that widely used modern platforms today like Java EE, .NET, Rails and even Node.js are in fact deployed to traditional businesses effectively for years. The Spring model is very outdated and more like old style C and C++ applications where you build custom runtimes yourself. In fact, the Spring guys have finally begun to modernize their development experience with Spring Boot, essentially validating the direction that everyone else has gone for years. The reality is that you should be modernizing your operational environment with DevOps practices and working more effectively with your operations folks. Platform installation and upgrades to up-to-date versions is something to learn to do well for effective IT shops, not try to avoid.

User 236075 avatar

henk replied ago:

1 votes Vote down Vote up Reply

Just run 1 application on 1 server. Problem solved.

User 57404 avatar

ld89125 replied ago:

-1 votes Vote down Vote up Reply

Again traditional operation won't accept to use different kind of app servers (for example Weblogic 10.x and Wildfly) in their production environment which is logically acceptable. Harmonize and stabilize are the key. Please read the article and the comments carefully. Thanks.

User 157014 avatar

rrahman replied ago:

1 votes Vote down Vote up Reply

In reality, most data centers in the real world are highly heterogeneous, running software of many versions from many vendors. Most competent operations folks have absolutely no issues with this in fact this is what is the case in our vast customer base of thousands if not millions of WebLogic deployments.

User 57404 avatar

ld89125 replied ago:

-1 votes Vote down Vote up Reply

Reza, there are other operations which don't have millions of WebLogic deployments ;-) There are still SMEs (Small Medium Enterprises). If you are talking about millions of WebLogic deployments means to me that money will never be the problem to upgrade. I'm talking about SMEs or small until middle IT divisions (ok, I did not mention this in my article, sorry for that) and tight resources. I hope that JEE is also targeting the SMEs and not only super big enterprises ;-)

User 157014 avatar

rrahman replied ago:

1 votes Vote down Vote up Reply

The large majority of the WebLogic customer base is actually small to medium sized companies and most of them are running highly mixed environments in reality. In fact I have never seen anything otherwise and I very much doubt many folks have either.

User 776377 avatar

lburnham123 replied ago:

1 votes Vote down Vote up Reply

Then those wold-school operations folks or departments will have to come to terms with internet-age technologies and development and deployment timelines, now won't they? Reza's comments about DevOps are right on the mark - a lot has happened in the continuous integration and continuous deployment space in recent years that's worth checking out. An ops team that impedes moving forward, or fraught developer/ops relations that cause such impedance, helps no one.

User 157014 avatar

rrahman replied ago:

2 votes Vote down Vote up Reply

It's definitely click-bait/flame-bait but there are ways to turn it into something useful :-).

Add your comment


Html tags not supported. Reply is editable for 5 minutes. Use [code lang="java|ruby|sql|css|xml"][/code] to post code snippets.

Voters For This Link (8)



Voters Against This Link (3)



Apache Hadoop
Written by: Piotr Krewski
Featured Refcardz: Top Refcardz:
  1. Play
  2. Akka
  3. Design Patterns
  4. OO JS
  5. Cont. Delivery
  1. Play
  2. Java Performance
  3. Akka
  4. REST
  5. Java