Blog Archives

Part #1: JPA Hibernate Spring Maven Eclipse Tutorial – setting up pom.xml

Any non trivial application needs to talk to databases. JPA is for ORM (Object to Relational Mapping) frameworks like Hibernate as JDBC is database connectivity.

The finished project artifacts are shown below, and it consists of Java classes, properties files, and Spring “JavaConfig” files with @Configuration annotation.

Let’s start with bringing in the dependent jar files via maven pom.xml in this part.

Read more ›



Part #2: JPA Hibernate Spring Maven Eclipse Tutorial – JPA configs and repository

This extends Part #1: JPA Hibernate Spring Maven Eclipse Tutorial. Spring wires dependencies with “MyDomainConfiguration” JavaConfig file. You have a Service Layer –> DAO (or Repository) Layer –> Entity (i.e. maps relational data to an object). … Read more ›...



Part #3: JPA Hibernate Spring Maven Eclipse Tutorial – testing data access with HSQLDB

This tutorial focuses on testing data access logic with spring-test and hsqldb. This extends Part #2: JPA Hibernate Spring Maven Eclipse Tutorial – JPA configs and repository Testing the mapping of entities managed by hibernate and wiring up of JPA, Hibernate, etc via Spring. Schema and mock data similar to...



Spring MVC RESTful with JPA, Hibernate & MySQL database beginner in 13 steps

This tutorial combines both

1) Spring 4 MVC RESTful Web Service Beginner Tutorial step by step, which focuses on the RSTful web service and

2) JPA with Hibernate & MySQL database tutorial step by step, which focuses on JPA and Hibernate.

Read more ›



Spring MVC Web Application with JPA, Hibernate & MySQL

ControllerService LayerDAO LayerJPA/HibernateMySQL Database

Step 1: The pom.xml with JSTL, Spring MVC, JPA, and Hibernate libraries are included as well.

Define the model class Account.java

Step 2: Define the Account.java with 3 fields &

Read more ›



800+ Java Q&As & tutorials

Top