ClickStart: Building Maven-based Hibernate Apps on Tomcat in One Click

Written by: Harpreet Singh

Earlier, I wrote  about the productivity boosts offered by the ClickStart  application templates feature. The essence of the earlier blog is: ClickStarts are project templates (like Maven archetypes, if you know what they are) but on some serious steroids (in fact any more steroids and they could win the Tour De France (just kidding ;-)). A ClickStart template sets up the project code, sets up the corresponding repository, Jenkins job, the database and deploys the application. So, in one click, developers have a development to deployment environment ready. They can just leap in and start coding. See my earlier blog  that shows the steps to create a Java EE 6 web application.

This blog uses a ClickStart template to build a Maven-based web app with a database back-end accessed using Hibernate. The blog shows how to access the source and database created by the ClickStart. Fire up ClickStart (use the "Deploy Instantly to CloudBees" button at the end of this blog) or hover over the toolbar and... the "Hibernate and Tomcat" template and enter the application name

The template sets up the database, repository and Jenkins build for the application 

Bring up the application (the web URL is shown in Image 3) to play with it. Here is mine - I will keep this app live for the next few months.

Let us see where the source code repository and the database are at. The ClickStart template ends by listing out the URLs for the resources created (Image 3).

The source is created as a Git repository on CloudBees and a git clone  will get the repo to your machine. You can also use the Repository  entry on the toolbar to get to the repository management page - the repo page lists out the steps required to clone your sources.

The ClickStart creates a MySQL database and the database can be accessed by any of the usual MySQL clients. You can go to the DBs  entry on the toolbar to get to the database management page. The management page lists out the IP and other pertinent information to connect to your database.

I encourage you to try this out - once you do, you will never go back. My next blog will talk about two hot technologies (Backbone.js and REST apps) and I will show how to access the Jenkins builds.


Harpreet Singh
Senior Director, Product Management

Harpreet Singh

Harpreet has 12 years of experience in the software industry. Prior to CloudBees, he was at Oracle and Sun for 10 years in various roles, including leading the marketing efforts for Java EE 6 and GlassFish 3.1. He was also product manager for Hudson, launching it within Sun's GlassFish Portfolio.

Stay up to date

We'll never share your email address and you can opt out at any time, we promise.