Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Have you found success with a Spring and Hibernate Web Application

I am working on medium sized web application 4-5 tabs, user login for about 100k users. We are completing redesigning the application from scratch and using spring and hibernate, connected to MySQL.

Did you experience major issues and what where did Spring benefit your application.

like image 317
Berlin Brown Avatar asked Nov 28 '22 20:11

Berlin Brown


2 Answers

No major issues. Spring was particularly of benefit for:

  • Making all the configuration plumbing consistent and straightforward
  • Dependency Injection to support better factoring of code
  • Declarative "Open Session In View" functionality for Hibernate
  • Declarative Transaction Demarcation
  • The Acegi (now Spring Security) project made it easy to integrate a custom security model
  • The Spring data access support removes the need for a lot of boilerplate from any JDBC access - maybe not such a boost for Hibernate usage, but we had a mix of both. It also allows you to use JDBC & Hibernate together fairly seamlessly
like image 179
alasdairg Avatar answered Dec 05 '22 15:12

alasdairg


In addition to what has been said so far, I would focus on newer style annotations for both Spring (e.g. @Controller) and Hibernate (e.g. @Entity). It will further reduce your codebase leaving you with less code to maintain. On the downside, there is a pretty significant learning curve, but ultimately the lesson I learn time and again is that the benefits of Spring + Hibernate far outweigh the (learning curve) costs. You simply have to write a lot less code letting you focus on the business.

like image 37
Julien Chastang Avatar answered Dec 05 '22 14:12

Julien Chastang