Enterprise grade Java.
You'll read about Conferences, Java User Groups, Java, Integration, Reactive, Microservices and other technologies.

Monday, January 19, 2009

Grails with Glassfish v3 Prelude

09:00 Monday, January 19, 2009 Posted by Test No comments:
, , , ,
I got the change to take a deeper look at the new GlassFish v3 Prelude. Nazrul Islam published a personal top 10 of the biggest features in v3. One among others is the "Support for dynamic languages such as Ruby and Groovy". Have a look at the official OnePager or a presentation.

In this short howto I want to provide a brief step by step guide, on how to setup a sample Grails application and start it with the embedded GlassFish server.

#1 Download GlassFish v3 prelude from the official website (choose the distribution ,you like)
#2 Install or extract the archive to a suitable location
#3 Add your JDK/bin folder to the path variable (export with unix/linux)
#4 Start the server with <as-install>/bin/asadmin start-domain
#5 Access the admin console http://localhost:4848/
#6 Click on Update Tool, choose "Available AddOns", choose "Grails Scripting" (version 1.0.4-1.0 at the time of writing)
#7 Stop the server with <as-install>/bin/asadmin stop-domain
#8 Set/export GRAILS_HOME=<as-install>/glassfish/grails
#9 Execute GRAILS_HOME/bin/grails create-app <your_app_name>
#10 Change to the newly created directory <your_app_name>
#11 Execute GRAILS_HOME/bin/grails run-app
#12 Open your favorite browser and point it to: http://localhost:8080/<your_app_name>/

Congratulations! You are done!


Post a Comment