Wednesday, February 27, 2008

A couple more Maven2 Plugins

Last week I wrote about using the Maven Build Helper Plugin and just started wandering how many other plugins were out there that could be very useful for me, but that I had not yet discovered. So, after a little searching, I found two other plugins that I really wish I would have known about before this. Note however that I have not tried using them to verify their capabilities.


Maven 2 License Plugin

I really, really could have used in the past. I work on about 5 Open Source projects on Java.Net. Most of those started out being built internally. So right before that initial commit you've got to insert a header in every single file. Additionally, I work on DoD contracts and when we deliver code at the end of each quarter, it must include a Government Purpose Rights header. Yes, that includes replacing the open source headers with the GPR headers.

Anyway, I'll list the features of the plugin so you can decide if you want to go check out the project site here.

  • Check: check if header is missing in some source file
  • Reformat: add headers if missing
  • Custom mappings: enables easy support of new file extensions
  • Variable replacement: You can add some variable in your header, such as ${year}, ${owner} and they will be replaced by the corresponding values taken from the pom or system properties.


JMeter Maven Plugin

I'm not using JMeter on my current project, but I have used it on several previous projects. And, there's nothing better than being able to automate a testing process into your build. That's right, this plugin will run your JMeter tests during your build. Unfortunately, it seems like there may be a lack of documentation. However, I've located one additional resource that even includes report generation in it's example of how to use this plugin.

Check out the plugin's site here.

Enjoy!

1 comment:

Ronnie76er said...

Hey Chad,

Try here:
http://www.ronniealleva.org/index.php/maven-jmeter-plugin/

I updated it to work with the latest version of JMeter. You can also include some variables into the pom file which will do the same as putting -D on the command line when running JMeter. The page will explain a bit more.

I had piggybacked on some of the stuff James had done here:

http://jlorenzen.blogspot.com/2008/03/automated-performance-tests-using.html