james
james

Reputation: 1687

Convert dynamic web project to JPA project?

I have a dynamic web project in eclipse luna EE. I am supposed to use EclipseLink and JPA to manage the persistence. I want to create the entity classes for each of these classes from database tables in a mysql server. I saw the steps for this at : Generating entities from tables (help.eclipse.org)

The steps in the above tutorial are applicable only to a JPA project. So, I right click my project > configure and see convert to JPA project, convert to plugin project, convert to maven project.

There is another way to convert a project to JPA. Right click project > JPA tools etc.. But I do not see the JPA tools option there.

I was thinking of converting it to a JPA project. But, I am not confident if I should do it. Will my dynamic web app continue to work properly if I do it ? What is the meaning of those 3 configuration options ? I'd like to know before I proceed.

Thank you.

Upvotes: 2

Views: 6776

Answers (1)

Paul Samsotha
Paul Samsotha

Reputation: 209132

You can just add technology facets to your project, instead of configuring it to a different type of project.

Simply

Right click on project -> Properties -> Project Facet -> Convert to faceted form (if needed) -> JPA.

The link that says "Further configuration required(available)" you may want to configure a JPA implementation. To use EclipseLink:

You should see JPA Facet dialog. Select EclipseLink from Platform. Select User library from Type. Click "Download Library (disk icon)" on the right. You should be able to figure the rest

Upvotes: 9

Related Questions