wood burning stoves 2.0*
The moose likes Ant, Maven and Other Build Tools and the fly likes Maven - JSP Static Code Analysis Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Bookmark "Maven - JSP Static Code Analysis" Watch "Maven - JSP Static Code Analysis" New topic
Author

Maven - JSP Static Code Analysis

Anish Pyne
Greenhorn

Joined: Aug 23, 2010
Posts: 15
Are there any Maven plugins or stand alone tools available to do static analysis of JSP code? I am handling a very old application with lots of JSPs having badly coded scriplets in them. Getting rid of all the scriplets will take a long time hence next best is to improve the code as much as possible. Need something similiar like FindBugs which does awesome code analysis of .java code.
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 30537
    
150

PMD will look at JSPs. It has a Maven plugin, but PMD only works on well formed JSP files. I recommend writing your own pre-processort to get rid of the HTML code to "simulate" well formedness and then run PMD via the Maven plugin.


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Maven - JSP Static Code Analysis