This page describes an older version of the product. The latest stable version is 14.2.

Your First JPA Application


Summary: This tutorial explains how the sample Spring PetClinic application can be fine tuned to use GigaSpaces XAP JPA API and deployed into the GigaSpaces XAP platform

Before You Begin - Set Up Your Environment

Follow these instructions to download and install the latest version of XAP.

If you also wish to utilize the GigaSpaces XAP load balancing agent, you should download and install the Apache 2.2 Http Server{:target=”_blank”}.

Example Source Code and Build Scripts

You can download the example sources and build scripts on Github. Simply download the sources as zip or clone the repo to your machine (make sure to use the {{site.petclinic_jpa_branch}} branch).

Using XAP’s JPA Support to Scale the Spring PetClinic Sample Application - Step by Step

|animals.png|This tutorial explains how the Spring PetClinic sample application can be scaled by running on the Space, showing you how to:
Adjust the PetClinic domain model to use the distributed XAP JPA implementation
Utilize scalable distributed patterns such as partitioning, colocation of data and business logic and Map/Reduce to scale your JPA application
Deploy the application on to the GigaSpaces XAP runtime environment to achieve high availability and self healing capabilities|

Step1.jpg

Adjusting Your JPA Domain Model to XAP’s Distributed JPA Implementation ~15 minutes

Shows how to adjust the PetClinic’s JPA domain model to XAP’s JPA implementation and deals with issues such as data partitioning and indexing

object-model.png

</div>

  • The concepts basics of the GigaSpaces JPA implementation
  • The required adjustments to scale the PetClinic’s JPA domain model and work in with the Space’s distributed JPA implementation

Step2.jpg

Using the Power of the Space to Scale Your Data Access Layer ~15 minutes

Shows how to implement the PetClinic’s data access layer using Space based remoting and colocation of data and business logic.

continuous-scaling.png

</div>

  • How to use space remoting to implement ultra-fast embedded access to your data using JPA

Step3.jpg

Building & Running the Application ~15 minutes

Shows how to build and deploy the application to the GigaSpaces runtime environment

300px-Maven_logo.gif

</div>

  • Building and deploying the application
  • Scaling the web tier
  • Configuring highly available HTTP session backed by the space