This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
The moose likes Struts and the fly likes Is Spring JdbcTemplate expensive to create Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Is Spring JdbcTemplate expensive to create" Watch "Is Spring JdbcTemplate expensive to create" New topic

Is Spring JdbcTemplate expensive to create

Sonny Gill
Ranch Hand

Joined: Feb 02, 2002
Posts: 1211


How expensive is it to create a JdbcTemplate object?
Would creating it at the start of every method be too expensive (I guess it would) ?

Rod recommends keeping it as an instance variable in the DAO's since it is thread safe. What is the recommendation if you need to make a JDBC call in a model object that loads the data directly from the DB?

And while we are talking about Spring, has anybody tried using Spring MVC to generate Client side validation JavaScript. I remember reading a post made by Matt Riable once about it, but it did not appear very straight forward.



The future is here. It's just not evenly distributed yet. - William Gibson
Sonny Gill LinkedIn
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link:
subject: Is Spring JdbcTemplate expensive to create
jQuery in Action, 3rd edition