My favorites | Sign in
Project Home Downloads Wiki Source
Search
for
IntellijFindBugsPlugins  
A summary of FindBugs plugins for IntelliJ IDEA
Updated Aug 3, 2010 by keithl

Reviews

Here's a quick run-down before we get to the individual reviews. There are three ways to run FindBugs within IntelliJ IDEA, via three separate plugins.

QAPlug-FindBugs FindBugs FindBugs-IDEA
Open-source No Yes Yes
Ease of use Good Good Cluttered, buggy
Integration / L&F Great Poor Great
Bug information Great Poor Great
Result filtering Some filters Poor Lots of filters
Analysis scope Lots of options Only project/module Lots of options
Configuration Detectors, analysis Analysis only Detectors, analysis
Custom FindBugs No No No
Analysis progress Great None Great
Runs in background No Yes Yes
Load/save analysis No No No (broken)
Downloads 2,700 4,700 13,600
Home Page link link link
Plugin Link link link link

These plugins can all be downloaded through IntelliJ's built-in plugin manager.

QAPlug-FindBugs

QAPlug provides code analysis for CheckStyle, FindBugs, and PMD.

Running FindBugs is easy and straightforward. To start, you click the main Analyze menu and select Analyze Code. You are presented with a standard IntelliJ dialog asking about the scope of the analysis. You can choose to analyze the whole project, specific files or folders, or one of IntelliJ's pre-defined scopes.

During analysis, a helpful progress bar shows you what's happening. Unfortunately the analysis cannot be run in the background, and clicking the Cancel button doesn't do anything.

The results window looks and acts like other IntelliJ result tabs (search, code inspection, etc). It allows you to optionally categorize bugs by severity (warning vs. error) and by package.

The detectors are configurable by clicking the configuration button on the results:

Note - one possible point of confusion is that the project must be built for this plugin to show any results. And any changes will not be reflected until building. This may confuse IntelliJ users since the built-in code analysis always operates on the source code.

Pro:

  • Simple interface
  • Tight integration, IntelliJ look&feel
  • Shows detailed information about bugs in the results window
  • Shows detailed progress
  • Allows custom analysis scope
  • Allows enabling/disabling individual detectors

Con:

  • Cannot provide own version of FindBugs, must use built-in version
  • Cannot run analysis in background
  • Analysis cannot be cancelled
  • Cannot load or save analyses

FindBugs plugin

The plugin called simply "FindBugs" provides a quick & dirty way to run FindBugs. To run it, you simply click the toolbar icon:

And configure the analysis:

The plugin then runs everything in the background using IntelliJ's background tasks feature. You can click the task in the status bar to see a progress bar for "copying resources":

Followed by the real FindBugs analysis progress bar, which doesn't move. And despite the little red X button to the right, FindBugs execution cannot be cancelled!

The results are shown in an IntelliJ compilation results window, which leaves you with some inappropriate terminology and toolbar buttons such as "Exclude from compilation":

Pro:

  • Allows configuration of bug priority and analysis effort
  • Allows analyzing individual module or project
  • Runs analysis in background

Con:

  • Cannot analyze just one file or folder
  • Analysis shows no progress
  • Analysis results cannot be sorted, filtered, or grouped
  • Cannot provide own version of FindBugs, must use built-in version
  • Does not show any details or documentation about bugs
  • Does not allow enabling or disabling individual detectors
  • Does not allow load/save of analyses

FindBugs-IDEA

FindBugs-IDEA is surely the most mature and robust FindBugs plugin for IntelliJ. It lacks the ease of use of QAPlug but provides much more in the way of configuration options and view customization.

First you click the Tools menu:

And you see a somewhat cluttered dialog for configuring the analysis. It includes a tab for the detectors (with a description of each one):

(I had to click "Restore Defaults" for the detectors to show up - bug!)

as well as a tab for filtering the results:

The analysis shows a somewhat helpful progress window and can run in the background and it can be cancelled!

When the analysis is complete, the results are shown in an toolwindow very much like IntelliJ's built-in results windows:

Here you can group by any combination of category, severity, priority, rank, and Java package.

The results window has a button to "export to XML/HTML", but it didn't work for me. First the Browse button didn't work, then when I typed the folder name by hand, I got this error message:

Yes, my desktop is writable. Using forward or back slashes didn't seem to help.

Pro:

  • Allows custom analysis scope
  • Allows enabling/disabling individual detectors
  • Allows configuring FindBugs analysis options
  • Shows detailed information about bugs, both in the configuration panel and the results window
  • Tight integration, IntelliJ look&feel
  • Shows detailed progress
  • Analysis can be run in background and can be cancelled

Con:

  • Sacrifices usability for configurability
  • Buggy - came across several bugs in the 20 minutes it took to write this review
  • Cannot provide own version of FindBugs, must use built-in version
  • Cannot load past analysis, and saving analysis doesn't work

Comment by krystian...@gmail.com, Feb 26, 2010

Hello Keith

First of all as a co-author of QAPlug, thank you for your comparison.

It's great to see a lot of advantages in "Pro" section for QAPlug. On the other hand, we will improve things described in "Con" in next releases.

Have you got any other suggestions? How this plugin should look like in your imagination?

Best regards Krystian Lider

Comment by ubu...@gmail.com, Jul 26, 2011

This review is a bit dated. I find the current version of QAPlug FindBugs? much nicer than "FindPlugs?-IDEA". What's missing from QAPlug FindBugs? for me is the ability to use standard FindBugs? "File Filters". Without them I cannot easily use the same settings in IntelliJ and on a build system that uses the FindBugs? command-line tool and "File Filters".

I have no affiliation with QAPlug or FindBugs?.


Sign in to add a comment
Powered by Google Project Hosting