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 […]

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 […]

Himanshu Seth
Himanshu Seth
Read

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 extends Blog{ String textContent static constraints = { textContent […]

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 cmd, follow […]

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 { String text static belongsTo […]

Himanshu Seth
Himanshu Seth
Read

GrailsTechnology

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 […]

Deepak Mittal
Deepak Mittal
Read

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. Example: A website dealing with some kind […]

Salil
Salil
Read

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 […]

Imran Mir
Imran Mir
Read
Services