Grails

Adding interactive charts to web pages using Highcharts

I recently had to add charts to a web page in my project. I used Highcharts library for this. It is very dynamic allowing you to change graphs even after the chart has been drawn. To display a graph we need a div with an ID. Let's say we have div with ID "chartDivId" and we want to display two lines in the chart. We can use the...

by Aseem Bansal
Tag: grails development
26-May-2015

Grails

Groovy & Grails: Gr8 without Pivotal

Couple of days back, we got to know about Pivotal deciding to end the sponsorship of Groovy and Grails project from 31st March 2015 through Guillaume Laforge's blog post and Graeme Rocher's post  Like many others in the community, news has taken us by quite some surprise. Just to give everyone context, we are a Technology services...

by Himanshu Seth
Tag: grails development
21-Jan-2015

Grails

Inheritance in Grails

In Grails, we can have inheritance with the abstract base class as well as persistent base class. Lets take an example to explain this.(All the classes are in the package com.intelligrape.example) [java] class Blog{ String authorName static constraints = { authorName (nullable:false) } } class TextBlog ...

by Uday Pratap Singh
Tag: grails development
03-Sep-2012

Grails

How to configure SSL on Tomcat server and run Grails/Java application on HTTPS

To run your Grails application on SSL, firstly you need to configure the Tomcat server. Here in this example, I will show how to configure Tomcat instance and run Grails/Java application. For SSL/HTTPS: We need .keystore file. You can generate it by using command“keytool -genkey”. Run this command on linux terminal or window...

by Mohit Garg
Tag: grails development
29-Jun-2012

Grails

Criteria Query with Left Outer Join

In Grails app development, when using criteria queries, we often find cases for Outer joins. Lets take an example. We have two domain classes with us: [java] class Blog { String title String content static hasMany = [comments: Comment] static constraints = { } } [/java] and [java] class Comment { ...

by Himanshu Seth
Tag: grails development
01-Nov-2011

Grails, Technology

Why use Grails?

Last week, I was talking to a prospective client, who instead of asking me, why we should go with TO THE NEW, asked me, why should we go with Grails? Considering the fact that I have been working with Grails for over 3 years and we are a Groovy/Grails focussed shop, it should have been an easy question to answer; but there were so many...

by Deepak Mittal
Tag: grails development
16-Jan-2011

Grails

How to use Thread-Pooling using Groovy

Grails Development is challenging and most Groovy and Grails projects require in-depth understanding of thread-pooling. As a Groovy developer, I really like the thread-pooling API (in java.util.concurrent package), especially when you are hitting x number of API dealing with outside network to fetch information for a single request. ...

by Salil
Tag: grails development
16-Jan-2011

Grails

Rich Domain Model in Grails

I have been working on grails for quite some time now. As a beginner, I had doubts about where to place the business logic in grails. Seeing the CRUD, one can easily be misled into putting most of the code in the actions, but as the code base goes bigger, it becomes difficult to manage those actions. Coming from the java background, with...

by Imran Mir
Tag: grails development
14-Oct-2010