JPA + eclipselink + SAP Cloud Platform = database application running in the cloud

Source: Internet
Author: User
Tags java web

The implementation of the JPA (Java persistence API) provider has HIBERNATE,OPENJPA, Eclipselink, and so on.

This article describes how to connect Hana DB instances on the SAP cloud Platform through JPA + eclipse.

1. Log in to SAP Cloud Platform cockpit to create a new Hana DB instance:

Set the database ID and password for system user.

After successful creation, the HANA DB instance state is creating:

After a moment, the status becomes started, which is available.

2. The next step is to develop a Java application that uses JPA to operate this cloud-based DB instance.

The SDK for the SAP Cloud Platform Neo Environment comes with a JPA Hello World app, located under folder samples and named PERSISTENCE-WITH-JPA:

Direct import into Eclipse, targeted runtimes selected as Java Web Tomcat 8:

Then deploy the app from eclipse to the SAP Cloud Platform:

After successful deployment, get the app's access URL in the SAP Cloud Platform cockpit:

3. Bind the deployed Java application to the Hana DB instance created in the first step:

The binding succeeds so that the Java application can use the Hana DB instance in the cloud.

Test in a PC browser. This Hello World JPA app only designed a table that contains the first name and last name two columns.

On the phone side of the access:

To get more original Jerry's technical articles, please follow the public number "Wang Zixi" or scan the QR code below:

JPA + eclipselink + SAP Cloud Platform = database application running in the cloud

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.