Step 5. Exploring Persistence Settings

Time to complete this step: 15 minutes

The persistence.xml file defines the context for JPA persistence. In this step, you will use the JPA Persistence Configuration Editor to explore the persistence.xml file for your JPA web project.

The task in this step are:

To Use the JPA Persistence Configuration Editor to View the Persistence Configuration File

The JPA Persistence Configuration Editor provides a graphical interface that allows you to modify connection information, mapped classes, and JPA properties that are managed by your persistence.xml file. Optionally, you can also use the editor to edit the persistence.xml source file.

To View the Connection Properties

The Connection tab of the persistence.xml editor displays the current connection properties and allows you to modify the existing connection if you use a JDBC Datasource. If you choose to instead embed the connection properties directly in persistence.xml, you can use the Properties tab to edit them. This tutorial embeds the properties directly.

To View JPA Mapping Files

You can use the General tab to view and modify mapped classes.