Introduction to Spring Restful (JSON) + Hibernate with AngularJS

Background and Pre-request

This blog will show you how to build Spring Restful + Hibernate ORM models with AngularJS web application, the example here will use JSON to communicate between Spring controller and AngularJS web UI. After running through our example, you should be able to master Spring Restful and make HTTP JSON request using AngularJS.

Before the examples, you need to have:

  1. Java JDK 1.7 or later
  2. Eclipse 4.5.1 Mars or later
  3. Tomcat 7 or later
  4. MySQL 5.7 or later
  5. Maven plug-in (m2e)


With Eclipse Mars, you don’t need to install the Maven, because starting from Eclipse 4.3 Kepler, it already includes the Maven so that you don’t need to install Maven plug-in (m2e).


Please make sure:

  1. Install MySQL (using 5.7 for our example), you can download from
  2. Install JDK from Oracle (using JDK 1.7 for our example), you can download from
  3. Setup JAVA_HOME path

a. Right-click on “Computer”, and click on “Properties”.

b. Click on “Change Settings”

c. Click on “Environment Variables”

d. Under “User variables for XXXX”, click on “New” button to create a new user variable

Input “JAVA_HOME” as variable name and C:\{your_java_installed_path}\jdk1.7.0_55 as your variable value. If you are using different version of JDK, please update the path value.

  1. Download and install Eclipse (prefer Eclipse Mars or upper), you can download from
  1. Download and install Tomcat (prefer Tomcat 8 or upper) from
  2. After installed JDK, Tomcat and Eclipse, you can setup the JDK version and Server Runtime for your Eclipse.
  3. Open the Eclipse
  4. Setup the JDK version : select “Window” => “Preferences” => “Java” => “Installed JREs” => setup your JRE home path:

9. Setup the Server Runtime : select “Window” => “Preferences” => “Server” => “Runtime Environments” => click “Add…”


Click “Next”, and fill in your tomcat installed path:


Click “Finish” to save it.


Development environment has been setup successfully, you can now start playing with the examples in the coming blogs.

Please rate this