quality@glassfish.java.net

Findbugs update.

From: Aditya Dada <Aditya.Dada_at_Sun.COM>
Date: Wed, 26 Apr 2006 19:54:53 -0400

Sometime ago, I blogged about findbugs, and its use on glassfish. (see:
http://weblogs.java.net/blog/aditya_dada/)
Findbugs tool has been very helpful in finding out high priority issues
like infinite loops. In the past, and with the help of Jerome Dochez, we
were able to inform the teams whose code included an infinite loop, and
get it corrected. Some infinite loops present in the third-party code is
still out of our scope to get fixed during timeframes that suit us. We
have been able to reduce the number from an all time high of 8 to 4,
now. For those interested, here are the culprits that still remain in
Glassfish code:

Infinite Loop #1
    In class com.sun.messaging.jmq.util.CacheHashMap
    In method com.sun.messaging.jmq.util.CacheHashMap.capacity()
    At CacheHashMap.java:[line 43]

Infinite Loop #2
    In class com.sun.org.apache.commons.modeler.Registry
    In method
com.sun.org.apache.commons.modeler.Registry.setServer(javax.management.MBeanServer)
    At Registry.java:[line 551]

Infinite Loop #3
    In class com.sun.xml.stream.ZephyrWriterFactory
    In method
com.sun.xml.stream.ZephyrWriterFactory.createXMLStreamWriter(javax.xml.transform.Result)
    At ZephyrWriterFactory.java:[line 85]

Infinite Loop #4
    In class oracle.toplink.essentials.sessions.Project
    In method
oracle.toplink.essentials.sessions.Project.getClassDescriptorForAlias(String)
    At Project.java:[line 778]


While on the topic of FindBugs, I think it is appropriate to mention,
and applaud, the effort of the JSF team, that found, and then fixed all
high priority warnings found by Findbugs. Way to go JSF team!

-Aditya

-- 
"Any project can be estimated accurately (once it's completed)."