Finding bugs with FindBugs

It is easy to get lost in the volume of defects found by static code review tools. Another Quality Assurance attack pattern is to clean up the defects package by package, concentrating developer time on the most used features.

This recipe will show you how to generate and report defects found by FindBugs for specific packages.

Getting ready

Install the Jenkins FindBugs plugin (

How to do it...

  1. From the command line, create a Maven project:
    mvn archetype:generate -DgroupId=nl.berg.packt.FindBugs_all -DartifactId=FindBugs_all -DarchetypeArtifactId=maven-archetype-quickstart -Dversion=1.0-SNAPSHOT
  2. In pom.xml, add a build section just before the</project> tag, with ...

Get Jenkins Continuous Integration Cookbook now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.