Spring Data Verification

This verification process ensures that STS, Maven and Spring Data JPA are working properly.

Create a folder for the Spring Data Sample

We'll use this in the steps below.

Download Spring Data Sample

Download and unzip the JPA Sample into the folder created above.  You will get a folder such as SpringSource-spring-data-jpa-examples-3c7e9cf, as shown in the diagram below.

Create a Workspace and import the Spring Data Projects

Next:
  1. Create a folder for your Workspace (e.g, Spring Data Sample WS as shown below)
  2. Open the workspace in STS
  3. Import > Existing Maven Project > SpringSource-spring-data-jpa-examples-3c7e9cf project from the previous step
    1. Important: you may encounter errors - correct them as described in the next section


Verify Proper STS / Maven Operation

You may encounter a "no market for maven-apt-plugin" error shown at right (click for full screen view), which you can correct as described below.

Get the Query DSL Feature



Update the project pom

Following yet another useful Forum entry, add this to the parent project pom:

<dependency>
  <groupId>org.apache.maven.plugins</groupId>
  <artifactId>maven-jar-plugin</artifactId>
  <version>2.3.1</version>
</dependency>


Observe the high-lighted xml changes in the diagram below.

Update Maven Project Configuration

Finally, right click the project and select Maven > Update Project Configuration as shown below.



Execute the jUnit Tests

Finally, locate and run each of the jUnit tests as shown below, and verify they operate without errors.  Perform the step below for each test:



Comments