Simple Spring Hibernate App

Open Spring Tool Suite File -> New -> Spring Template Project Persistence -> Simple Spring Hibernate Utility Project Project Name: hibernateExample Top Level Package: com.skills421.examples.hibernate01 Finish Modifying the Code to Extend our Simple JDBC App File -> New -> Class Package: com.skills421.examples Name: Person Now Create a simple POJO called Person as follows: We want to … Continue reading Simple Spring Hibernate App


Create a Simple JDBC App

Download and Install Spring Tool Suite Create a Maven Project Run Spring Tool Suite New -> Maven -> Maven Project Select the default quickstart archetype org.apache.maven.archetypes maven-archetype-quickstart Enter a Group Id and Artifact Id for the app: Group Id: com.skills421.jdbc Artifact Id: jdbcExample Edit Pom.xml Edit Run name = John Dunning age … Continue reading Create a Simple JDBC App

Creating a Simple Postgres Database

Download and install Postgres Download Postgres from the Download Site For the Mac, download the Postgres App Edit the Path Variable On a Mac Open a Terminal Session Add the following line to your .profile export PATH=$PATH:/Applications/ run your .profile . ./.profile Start the Postgres Database by clicking the Postgres app Create a Database psql … Continue reading Creating a Simple Postgres Database

Understanding Pom.xml

project This is the top-level element in all Maven pom.xml files. modelVersion This element indicates what version of the object model this POM is using. The version of the model itself changes very infrequently but it is mandatory in order to ensure stability of use if and when the Maven developers deem it necessary to change the … Continue reading Understanding Pom.xml

Installing Apache Maven

Download and install Java from here Download Apache Maven from here Follow the instructions to install Maven add the following lines to your .profile: . ./.profile mvn --version Create a Sample Project from the Command Line CD to your Development Root folder mvn archetype:generate -DartifactId=my-app -DarchetypeArtifactId=maven-archetype-quickstart -DinteractiveMode=false This creates the following directory structure: my-app +- pom.xml … Continue reading Installing Apache Maven