i am building a real time application and was just trying to understand whats a good way to impliment it in spring and hibernate.
I was reading this article on it:
This above article uses Hibernate objects as Spring Beans, so that means hibernate objects will be defined in spring configuration file as beans.
But my application architecture is this:
jsp--> SpringConfigFlie --> Validatior calss ---->Controller class--> business delegate->dao-->hibernate-
Therefore in my architecture i am not calling hibernate until i reach the DAO.
comparing my architecure with the one in article, which one is better and why?
Also in the article the database configuration is done in spring config file like this
<bean id="myDataSource" class="org.apache.commons.
<property name="driverClassName" value="com.mysql.jdbc.Driv
<property name="url" value="jdbc:mysql://localh
<property name="username" value="root"/>
<property name="password" value="pwForRoot"/>
Is that good way to do it? I thought the database configuration is written in the hibernate config file (hibernate.cfg.xml).
There are too many resources on the web on spring-hibernate. Does anyone know how it is actually implimented in real tme projects ?
any responces/inputs will be greatly appreciated.