The prerequisite is that you need the DataNucleus Maven2 plugin installed. You can download this plugin from the DataNucleus downloads area.
Set the database configuration in the "src/main/resources/META-INF/persistence.xml" file.
Make sure you have the JDBC driver jar specified in the "pom.xml" file
Run the command: "mvn clean compile" This builds everything, and enhances the classes
(c) Copyright 2008-2013 DataNucleus