resources.report.rules.pmd.J2EE_Rules.html Maven / Gradle / Ivy
J2EE_Rules
J2EE_Rules
E_Rules">J2EE Rules
UseProperClassLoader:
In J2EE getClassLoader() might not work as expected. Use Thread.currentThread().getContextClassLoader() instead.
MDBAndSessionBeanNamingConvention:
The EJB Specification state that any MessageDrivenBean or SessionBean should be suffixed by Bean.
RemoteSessionInterfaceNamingConvention:
Remote Home interface of a Session EJB should be suffixed by 'Home'.
LocalInterfaceSessionNamingConvention:
The Local Interface of a Session EJB should be suffixed by 'Local'.
LocalHomeNamingConvention:
The Local Home interface of a Session EJB should be suffixed by 'LocalHome'.
RemoteInterfaceNamingConvention:
Remote Interface of a Session EJB should NOT be suffixed.
DoNotCallSystemExit: Web applications should not call System.exit(), since only the web container or the
application server should stop the JVM.
StaticEJBFieldShouldBeFinal:
According to the J2EE specification (p.494), an EJB should not have any static fields
with write access. However, static read only fields are allowed. This ensures proper
behavior especially when instances are distributed by the container on several JREs.
DoNotUseThreads:
The J2EE specification explicitly forbid use of threads.