Thursday, January 26, 2006

Using Code Metrics for Targeted Code Refactoring

I had a chance to attend Andrew Glover's Using Code Metrics for Targeted Code Refactoring, at MADJUG last night.

Having very little exposure to source metrics, the highlights for me were the demos of using JavaNCSS, PMD, and the Eclipse Metrics Plugin. All very cool - my plan is to check out PMD. It seemed to provide the functionality that I'd be looking for initially, so we'll see what it thinks of some of this code I've been writing lately.

Other than the tools, the talk was largely centured on Andrew's favorite metric: Cyclomatic Complexity. He ran some ridiculous code through the aforementioned tools to produce some reports illustrating just how outrageous it was. More importantly, he did a very good job of illustrating what "outrageous" really meant: hard to test, hard to maintain, and just plain painful to read. More on his thoughts here.

The topic also very much reminded me of a post from Venkat last week.

0 Comments:

Post a Comment

<< Home