Category Archives: Spring Framework

Spring and Hibernate Declarative Transaction Management Example

In this post, We will learn about Spring and Hibernate Declarative Transaction Management Example using a Demo Project. In hibernate framework, we usually provide all the database information in the hibernate.cfg.xml file. But when we integrate the hibernate application with spring, we really don’t need to create the hibernate.cfg.xml file. We can configure all the information in the applicationContext.xml file.… Read More »

Spring HibernateTempate Example

In this post, We will learn about Spring HibernateTempate Example using a Demo Project. In hibernate framework, we usually provide all the database information in the hibernate.cfg.xml file. But when we integrate the hibernate application with spring, we really don’t need to create the hibernate.cfg.xml file. We can configure all the information in the applicationContext.xml file. pom.xml We need to… Read More »

Spring 5 and Hibernate 5 integration CRUD Example

In this post, We will learn about Spring 5 and Hibernate 5 integration CRUD Example using a Demo Project. In hibernate framework, we usually provide all the database information in the hibernate.cfg.xml file. But when we integrate the hibernate application with spring, we really don’t need to create the hibernate.cfg.xml file. We can configure all the… Read More »

How to call stored procedures in the Spring Framework?

In this post, We will learn about How to call stored procedures in the Spring Framework using a Demo Project. The org.springframework.jdbc.core.simple.SimpleJdbcCall class is mainly used to call a stored procedure with IN and OUT parameters. We may use this approach while working with either of the databases such as MySQLApache Derby, DB2, Microsoft SQL… Read More »

Spring JDBC NamedParameterJdbcTemplate Example

In this post, We will learn about Spring JDBC NamedParameterJdbcTemplate Example using a Demo Project. Spring Framework provides easy integration with JDBC API and provides org.springframework.jdbc.core.JdbcTemplate nad org.springframework.jdbc.core.namedparam.NamedParameterJdbcTemplate utility classes that we can use to avoid writing boiler-plate code from our database operations logic such as Opening/Closing Connection, ResultSet, PreparedStatement, etc. Let’s have a look… Read More »

Spring with Jdbc java based configuration example

In this post, We will learn about Spring with Jdbc java based configuration example using a Demo Project. Spring Framework provides easy integration with JDBC API and provides org.springframework.jdbc.core.JdbcTemplate utility class that we can use to avoid writing boiler-plate code from our database operations logic such as Opening/Closing Connection, ResultSet, PreparedStatement, etc. Let’s have a… Read More »

Spring JDBC Annotation Example

In this post, We will learn about Spring JDBC Annotation Example using a Demo Project. Spring Framework provides easy integration with JDBC API and provides org.springframework.jdbc.core.JdbcTemplate utility class that we can use to avoid writing boiler-plate code from our database operations logic such as Opening/Closing Connection, ResultSet, PreparedStatement, etc. Let’s have a look at a… Read More »

Spring JDBC Integration Example

In this post, We will learn about Spring JDBC Integration Example using a Demo Project. Spring Framework provides easy integration with JDBC API and provides org.springframework.jdbc.core.JdbcTemplate utility class that we can use to avoid writing boiler-plate code from our database operations logic such as Opening/Closing Connection, ResultSet, PreparedStatement, etc. Let’s have a look at a… Read More »

getBean() overloaded methods in Spring Framework

In this post, We will learn about the getBean() overloaded methods in Spring Framework Example using a Demo Project. Spring BeanFactory has the following five getBean() Overloaded methods: Object getBean(String name) throws BeansException; <T> T getBean(Class<T> requiredType) throws BeansException; <T> T getBean(Class<T> requiredType, Object… args) throws BeansException; <T> T getBean(String name, Class<T> requiredType) throws BeansException;… Read More »

Spring JSR-250 Annotations with Example

In this post, We will learn about the Spring JSR-250 Annotations with Examples using a Demo Project. Spring Framework also supports JSR-250 annotations that include @Resource, @PostConstruct, and @PreDestroy annotations. These annotations are not really required because We already have other alternates or options to achieve  the same functionalities that we achieve using these annotations @Resource… Read More »