Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Use of the ThreadGroup APIs may result in race conditions, memory leaks, and inconsistent object state.

Rule

Severity

Likelihood

Detectable

RepairableRemediation Cost

Priority

Level

THI01-J

Low

Probable

Yes

NoMedium

P4

L3

Automated Detection

ToolVersionCheckerDescription
Klocwork

Include Page
Klocwork_V
Klocwork_V

JAVA.THREADGROUP
Parasoft Jtest
Include Page
Parasoft_V
Parasoft_V
CERT.THI01.AUTGDo not use variables of the unsafe type 'java.lang.ThreadGroup'
SonarQube
Include Page
SonarQube_V
SonarQube_V
S3014"ThreadGroup" should not be used

Bibliography

[API 2006]

Class Thread
Class ThreadGroup:
  Method activeCount
  Method enumerate

[Bloch 2001]

Item 53, "Avoid Thread Groups"

[Bloch 2008]

Item 73, "Avoid Thread Groups"

[Goetz 2006]

Section 7.3.1, "Uncaught Exception Handlers"

[JavaThreads 2004]

Section 13.1, "ThreadGroups"

[Java Tutorials]

[JPL 2006]

Section 23.3.3, "Shutdown Strategies"

[SDN 2006]

Bug ID 4089701
Bug ID 4229558

...