Tutorial: Customizing the Transaction server using REST and JPA services

In this tutorial, you use REST services to create a JPA-based customization on the Transaction server.

As a merchant, you want shoppers to associate their shopping accounts with their Facebook ID when they register with you. Later, you want to deliver promotion and discount information to the shopper through Facebook. In order to do this you will need to customize the persistence layer as well as REST layer of the Transaction server. This tutorial does not include any User Interface customizations involved in the storefront enhancement.

The tutorial highlights the use of the JPA programming model. Previous versions of HCL Commerce used EJB and DSL. JPA is a modern persistence technology which simplifies persistence layer customization and reduces your development and deployment effort.

After completing this tutorial, you should be able to Perform Transaction server customizations based on JPA and the REST framework, rather than the EJB&DSL and SOA/SOI service framework used in previous versions of .This tutorial uses the sample JPA code in the WebSphereCommerceServerExtensionsData folder, and the sample REST code in the WebSphereCommerceServerExtensionsLogic folder..

Time required

Expect this tutorial to take TWO hours to complete. The tutorial takes longer if you explore concepts that are related to this tutorial.

Skill level

This tutorial is intended for advanced HCL Commerce developers responsible for customizing the Transaction server. To complete this tutorial, you must be familiar with the following terms and concepts:
  • REST service
  • SQL
  • XML
  • Rational Application Developer
  • JPA
  • Java
  • Annotation

System requirements

No additional or special system requirements are needed to complete this tutorial.

Tutorial resources

Before you begin, ensure that you download and extract any compressed files that contain the required code samples. Place the samples in a temporary directory that is named working_dir, such as C:\restconfig. To complete this tutorial, use the following resources: