Maven plugins for Glassfish ecosystem

GlassfishThis post is only a snapshot of what is available at the time of writing to use Glassfish from maven., seen from the perspective of a simple maven plugin developer (simple plugin or simple developer ?).

Before beginning asadmin-maven-plugin, I searched and tried several ways to use Glassfish from maven. Main use case is simply deployment and undeployment of applications.

There are two ways to do this “programmatically” :

  • using the asadmin command, Glassfish specific,
  • and using the JSR-88 api, app-server agnostic

Here are all the glassfish maven plugins I’ve found :

Appart from this, the exec-maven-plugin allows to execute external commands and some posts on the net provide examples of using this plugin to invoke the asadmin command from a maven pom. Some others posts talks about using ant tasks inside maven pom to invoke asadmin.

In fact asadmin-maven-plugin is based on what Wouter van Reeven explain in a post called Deploying to GlassFish using Maven2 on the AMIS Technology Blog. I was using the exec-maven-plugin the way it’s explained there in my projects when I realized how much xml I had to copy/paste around.

At the end of the day, asadmin-maven-plugin is just a convenience maven plugin to execute the asadmin glassfish command leveraging the “convention over configuration” concept that maven teached to me.

In conclusion, I hope that the support for JSR-88 will soon be available in Cargo as we, developers, mostly need the cargo’s integration api usable from unit tests. On the other side, I hope that beside the immediate need of a working solution I’ll have time to maintain and continue asadmin-maven-plugin development.

Next time I’ll publish some documentation about asadmin-maven-plugin configuration.

Advertisements

8 thoughts on “Maven plugins for Glassfish ecosystem

  1. Hi lyeung,

    This post already provided a link to your project.

    With your investment in jsr-88, have you in mind to work with the cargo team ? Just curious.

    Regards,
    eskatos

    1. @Phil

      Yes this plugin works well, it was not really usable when I wrote this post

      asadmin-maven-plugin stays easy to extends and close to asadmin way of doing things which can help peoples that knows asadmin well

      And with the upcoming glassfish v3 release, the maven tooling will be even better.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s