Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.

Close

AvoidThreadGroup Violations in PMD 4.2.6

2011-10-27
2012-10-07
  • Randy Doffing
    Randy Doffing
    2011-10-27

    Our site recently moved from PMD 4.2.5 to 4.2.6. We are now receiving
    AvoidThreadGroup violations in various places. Our rulesets or our code hasn't
    changed in these areas.
    The following are a couple of code samples that are being flagged as
    AvoidThreadGroup voilations:
    1) throw new java.io.InvalidClassException(...);
    2) new java.text.SimpleDateFormat("dd/MM/yyyyhhmm");
    3) new java.beans.PropertyChangeEvent(...);

     
  • Randy Doffing
    Randy Doffing
    2011-10-31

    A co-worker of mine discovered that by removing the package path in the class
    reference - and moving it to an import -- these PMD violations went away. That
    is the work-around that we have implemented in our projects.