Dockerising Grails applications with an embedded Tomcat

The applications built on the Grails framework can be run (often referred to deployment) on either standalone or embedded Tomcat. Grails applications can be deployed in a number of ways,…

How to create a temporary file to store data

Your application has to write data out in a temporary file to reprocess them before rendering to users. The file will be created temporarily and swept our when the application…

Fastest way to get the first n elements of a List or an Array

Which is the fastest way to get the first n elements of a List or an Array? Let’s give a context where we want to extract some first elements from…

An annoyed error needed to be paid more attention when using RestBuilder grails plugin

In the previous post about consuming web services in Grails using RestBuilder grails plugin, I explained how to set up a call to the remote service provider. However, I have…

How to test database connection without using Hibernate ORM in Grails

You will likely encounter a headache problem when bringing a large project to cloud-based deployment development, especially testing the access of databases if you have to request of accessing internally…

How to consume web service from Grails 4 applications

Recently, I have shared my experience in using grails 2.5.x to consume RESTful API/WebServices. In addition, to know how to retrieve remote data via RESTful WebServices with Grails 3 or…

How to build and render data in JSON format with Grails

Nowadays, an awful lot of web based applications are using JSON as a principal data to load and render information rapidly. While some applications store data into persistence volume as…

How to consume web services in Grails

Frankly, implementing RESTful API endpoints/services is a vital part of any modern web-based applications these days because of inherent advantages of this technology. However, how do you consume RESTful services…

How to change default server port for Grails application

As a web developer, all of us are aware of the number 8080 as the holy port nobody can forget. In Grails based applications, there is no exception at all.…

Spring Autowired Annotation

In this post, we want to introduce to you an annotation that is quite common to ones already familiarised with Spring framework. It is @Autowired annotation that will be presented…