Deepak

Grails

How to invoke a GSP tag as a method in Grails GSP

Grails has a lot of gems. One of my favorites (besides GORM) is GSP tags -- Grails makes it so easy to create new tags, now there is no reason to write java/groovy code inside GSPs. One of the features about GSP tags that I discovered and used today is that it is possible to invoke a GSP tag as a method call and assign the output of...

by Deepak
16-Sep-2008

Grails

How to pass a bean or model to a template

When we want to render a view using a template and the template makes use of a model object, the model object needs to be passed to the template using GSP tags. I am writing this because it took me a while to figure this out. Thanks to the wonderful contributors on the mailing list who helped me with this. To render the view to a...

by Deepak
12-Sep-2008

Grails

Externalize application properties in a Grails app

Externalizing properties of an application has really come a long way, especially if you are using Grails. Just want to share as a quick tip how easy it is to externalize the properties in a Grails application. This is what all we have to do in-order to get something from a properties file. In config.groovy include the properties...

by Deepak
03-Sep-2008

Grails

How to customize homepage in Grails app

In this blog I want to share how can we customize home page while developing a Grails application. In grails, the default homepage is the web-app/index.gsp if we explicitly don`t specify any thing; but of-course that is not sufficient for all apps. We need to have a custom landing page instead of the default page provided by grails. ...

by Deepak
17-Aug-2008

Grails

Using jQuery and Grails to create chained selects / drop-downs

In grails web application development, use of frameworks has become essential . One of those frameworks which help us in making things simpler and life easy is jQuery. Why jQuery ? Fully Documented Great Community Tons of plugins Small size(14kb) Everything works in IE 6+,Firefox,Safari 2+,and Opera 9+ jQquery is a very...

by Deepak
17-Jul-2008

Grails

How to use table-per-subclass inheritance strategy instead of table-per-hierarchy

In this blog I want to share how to use table per sub-class instead of table per hierarchy, which is the default mechanism provided by Grails. I am not sure why Grails chose to use "table-per-hierarchy'. I always find it difficult to understand the table structure produced by "table-per-hierarchy". Moreover, it makes things difficult for...

by Deepak
15-Jun-2008

Grails

How to make Bootstraping environment specific in a Grails app?

BootStraping is something which is needed in most of the grails application. One of the frequently asked questions (and a valid requirement as well) is : How do you make Bootstraping happen only in a particular environment. This can be done by making use of one of the Grails utility class which allows you to inspect the environment in...

by Deepak
03-Jun-2008

Technology

Web Testing using Selenium – fix for error “java.lang.NullPointerException: sessionId should not be null; has this session been started yet?”

I have a big fan of Selenium and have been using Selenium for quite some time for testing of web-applications. Recently, I upgraded my machine to Ubuntu Hardy Heron and the next day, I found that all the selenium tests started failling on my machine. On digging through the logs, I found the following information in the Selenium Server...

by Deepak
07-May-2008

Technology

Installing IEs4Linux on Ubuntu Gutsy Gibbon

There are certain sites and applications which work only with Internet Explorer. One such application that I am currently working on is EMC Documentum Webtop. After getting fed-up of the warning message thrown by Webtop about unsupported browser and some weird behavior sometimes, I finally decided to install IE on my Ubuntu machine. ...

by Deepak
23-Apr-2008

Technology

Running VMWare on AMD 64 running Feisty Fawn

If you are running Feisty Fawn on AMD 64 machine and try to open a VMWare image, you will most-likely get this error message "Error while powering on: Failed to connect to peer process." The solution to this problem is to install the following the 32-bit libraries required by Ubuntu to recognize the 32-bit operating system. Use...

by Deepak
08-Apr-2008

Technology

Apache-Tomcat integration on Ubuntu server

Follow the steps mentioned below to integrate Apache with Tomcat on an Ubuntu system. The steps assume that Apache and Tomcat are already installed and working fine independently. Install Apache module for tomcat sudo apt-get install libapache2-mod-jk Create a file by the name "worker.properties" in /etc/apache2 directory....

by Deepak
13-Feb-2008

Technology

how to convert a .rpm to .deb

Installable software for Linux is mainly packaged as .rpm (for RedHat) & .deb (for Ubuntu & other debian based distributions). There can be cases when you want to install some application on your Ubuntu system & the same application might only be available as .rpm. Recently, I was in a similar situation when I had to...

by Deepak
04-Feb-2008