Apache logging services logo Apache log4j logo

PMD Results

The following document contains the results of PMD 5.0.2.

Files

org/apache/logging/log4j/core/appender/AsyncAppender.java

ViolationLine
Avoid empty catch blocks243 - 245
Avoid empty catch blocks278 - 280

org/apache/logging/log4j/core/appender/FailoverAppender.java

ViolationLine
Useless parentheses.133

org/apache/logging/log4j/core/appender/SyslogAppender.java

ViolationLine
Useless parentheses.127 - 131

org/apache/logging/log4j/core/appender/TLSSyslogAppender.java

ViolationLine
Useless parentheses.121 - 125

org/apache/logging/log4j/core/appender/TLSSyslogFrame.java

ViolationLine
Ensure you override both equals() and hashCode()59
Overriding method merely calls super59 - 61

org/apache/logging/log4j/core/appender/db/jdbc/ColumnConfig.java

ViolationLine
Useless parentheses.120
Useless parentheses.120
Useless parentheses.120

org/apache/logging/log4j/core/appender/db/jdbc/JDBCDatabaseManager.java

ViolationLine
Avoid unused private fields such as 'layout'.231

org/apache/logging/log4j/core/appender/db/jpa/converter/StackTraceElementAttributeConverter.java

ViolationLine
Avoid empty catch blocks71 - 73

org/apache/logging/log4j/core/appender/rewrite/RewriteAppender.java

ViolationLine
Overriding method merely calls super74 - 76

org/apache/logging/log4j/core/appender/rolling/PatternProcessor.java

ViolationLine
Useless parentheses.179
Avoid unused private methods such as 'patternContains(String,char...)'.257

org/apache/logging/log4j/core/appender/rolling/action/FileRenameAction.java

ViolationLine
These nested if statements could be combined80 - 83

org/apache/logging/log4j/core/async/DaemonThreadFactory.java

ViolationLine
Avoid using java.lang.ThreadGroup; it is not thread safe35

org/apache/logging/log4j/core/config/BaseConfiguration.java

ViolationLine
Avoid empty if statements187 - 194

org/apache/logging/log4j/core/config/ConfigurationFactory.java

ViolationLine
Avoid empty catch blocks285 - 287
Avoid empty catch blocks317 - 319
Avoid empty catch blocks375 - 377

org/apache/logging/log4j/core/config/Configurator.java

ViolationLine
Avoid unused local variables such as 'configLocation'.144
Avoid empty catch blocks148 - 150

org/apache/logging/log4j/core/config/JSONConfiguration.java

ViolationLine
Overriding method merely calls super161 - 163

org/apache/logging/log4j/core/config/LoggerConfig.java

ViolationLine
Overriding method merely calls super150 - 152

org/apache/logging/log4j/core/config/XMLConfiguration.java

ViolationLine
Useless parentheses.324

org/apache/logging/log4j/core/filter/MapFilter.java

ViolationLine
Useless parentheses.82
Useless parentheses.82

org/apache/logging/log4j/core/filter/StructuredDataFilter.java

ViolationLine
Useless parentheses.74
Useless parentheses.74

org/apache/logging/log4j/core/filter/ThreadContextMapFilter.java

ViolationLine
Useless parentheses.98
Useless parentheses.98

org/apache/logging/log4j/core/helpers/Booleans.java

ViolationLine
Useless parentheses.34

org/apache/logging/log4j/core/helpers/Closer.java

ViolationLine
Avoid empty catch blocks42 - 44
Avoid empty catch blocks70 - 72
Avoid empty catch blocks98 - 100

org/apache/logging/log4j/core/helpers/FileUtils.java

ViolationLine
Useless parentheses.54 - 55
Useless parentheses.55

org/apache/logging/log4j/core/helpers/Throwables.java

ViolationLine
Avoid empty catch blocks45 - 47

org/apache/logging/log4j/core/helpers/Transform.java

ViolationLine
Useless parentheses.48 - 51
Useless parentheses.126 - 133

org/apache/logging/log4j/core/helpers/UUIDUtil.java

ViolationLine
Avoid empty catch blocks99 - 101
Useless parentheses.180
Useless parentheses.180 - 181
Useless parentheses.181

org/apache/logging/log4j/core/impl/Log4jLogEvent.java

ViolationLine
Avoid unused method parameters such as 'stream'.385

org/apache/logging/log4j/core/impl/ThrowableFormatOptions.java

ViolationLine
Avoid empty if statements207 - 209

org/apache/logging/log4j/core/impl/ThrowableProxy.java

ViolationLine
Avoid empty catch blocks434 - 436
Avoid empty catch blocks463 - 465
Avoid empty catch blocks501 - 503

org/apache/logging/log4j/core/jmx/Server.java

ViolationLine
Avoid unused method parameters such as 'executor'.249
Avoid unused method parameters such as 'executor'.317
Avoid unused method parameters such as 'executor'.334

org/apache/logging/log4j/core/jmx/StatusLoggerAdminMBean.java

ViolationLine
Avoid modifiers which are implied by the context70

org/apache/logging/log4j/core/layout/HTMLLayout.java

ViolationLine
Avoid empty catch blocks219 - 221

org/apache/logging/log4j/core/layout/JSONLayout.java

ViolationLine
Useless parentheses.317

org/apache/logging/log4j/core/layout/RFC5424Layout.java

ViolationLine
Avoid unused private fields such as 'eventPrefix'.104
Useless parentheses.328
Useless parentheses.350
Useless parentheses.493

org/apache/logging/log4j/core/layout/XMLLayout.java

ViolationLine
Useless parentheses.340

org/apache/logging/log4j/core/lookup/StrSubstitutor.java

ViolationLine
Useless parentheses.759
Useless parentheses.835
Useless parentheses.835
Useless parentheses.1119

org/apache/logging/log4j/core/net/MulticastDNSAdvertiser.java

ViolationLine
Avoid empty catch blocks90 - 92
Avoid empty catch blocks236 - 238

org/apache/logging/log4j/core/net/Priority.java

ViolationLine
Useless parentheses.46

org/apache/logging/log4j/core/net/SocketServer.java

ViolationLine
Avoid empty catch blocks193 - 195
Avoid empty catch blocks223 - 225
Avoid empty catch blocks230 - 232
Avoid empty catch blocks232 - 234
Avoid empty catch blocks241 - 243

org/apache/logging/log4j/core/net/TCPSocketManager.java

ViolationLine
Avoid empty catch blocks201 - 203

org/apache/logging/log4j/core/net/UDPSocketServer.java

ViolationLine
Avoid empty catch blocks169 - 171
Avoid empty catch blocks176 - 178
Avoid empty catch blocks178 - 180
Avoid empty catch blocks187 - 189

org/apache/logging/log4j/core/net/ssl/KeyStoreConfiguration.java

ViolationLine
Avoid empty catch blocks80 - 81

org/apache/logging/log4j/core/pattern/AnsiEscape.java

ViolationLine
Avoid empty catch blocks325 - 327

org/apache/logging/log4j/core/pattern/CachedDateFormat.java

ViolationLine
Useless parentheses.211
Useless parentheses.268
Useless parentheses.268
Useless parentheses.268
Useless parentheses.380
Useless parentheses.380

org/apache/logging/log4j/core/pattern/MarkerPatternConverter.java

ViolationLine
Avoid unused constructor parameters such as 'options'.34

org/apache/logging/log4j/core/pattern/PatternParser.java

ViolationLine
Useless parentheses.522

org/apache/logging/log4j/core/pattern/StyleConverter.java

ViolationLine
Useless parentheses.60

org/apache/logging/log4j/core/pattern/UUIDPatternConverter.java

ViolationLine
Useless parentheses.53

org/apache/logging/log4j/core/selector/ClassLoaderContextSelector.java

ViolationLine
Avoid empty catch blocks115 - 117
Avoid empty catch blocks145 - 147

org/apache/logging/log4j/core/web/Log4jWebInitializerImpl.java

ViolationLine
Avoid empty catch blocks50 - 52