Dev/connection impl #84
Annotations
1 error and 5 warnings
|
Logger calls should be surrounded by log level guards.:
src/main/java/uk/gov/hmcts/cp/services/CaseUrnMapperService.java#L39
Whenever using a log level, one should check if it is actually enabled, or
otherwise skip the associate String creation and manipulation, as well as any method calls.
An alternative to checking the log level are substituting parameters, formatters or lazy logging
with lambdas. The available alternatives depend on the actual logging framework.
GuardLogStatement (Priority: 2, Ruleset: Best Practices)
https://docs.pmd-code.org/snapshot/pmd_rules_java_bestpractices.html#guardlogstatement
|
|
Local variable 'headers' could be declared final:
src/main/java/uk/gov/hmcts/cp/services/CaseUrnMapperService.java#L70
A local variable assigned only once can be declared final.
LocalVariableCouldBeFinal (Priority: 3, Ruleset: Code Style)
https://docs.pmd-code.org/snapshot/pmd_rules_java_codestyle.html#localvariablecouldbefinal
|
|
Parameter 'caseUrn' is not assigned and could be declared final:
src/main/java/uk/gov/hmcts/cp/services/CaseUrnMapperService.java#L60
Reports method and constructor parameters that can be made final because they are never reassigned within the body of the method.
This rule ignores unused parameters so as not to overlap with the rule {% rule java/bestpractices/UnusedFormalParameter %}.
It will also ignore the parameters of abstract methods.
MethodArgumentCouldBeFinal (Priority: 3, Ruleset: Code Style)
https://docs.pmd-code.org/snapshot/pmd_rules_java_codestyle.html#methodargumentcouldbefinal
|
|
A method should have only one exit point, and that should be the last statement in the method:
src/main/java/uk/gov/hmcts/cp/services/CaseUrnMapperService.java#L54
A method should have only one exit point, and that should be the last statement in the method.
OnlyOneReturn (Priority: 3, Ruleset: Code Style)
https://docs.pmd-code.org/snapshot/pmd_rules_java_codestyle.html#onlyonereturn
|
|
Local variable 'body' could be declared final:
src/main/java/uk/gov/hmcts/cp/services/CaseUrnMapperService.java#L42
A local variable assigned only once can be declared final.
LocalVariableCouldBeFinal (Priority: 3, Ruleset: Code Style)
https://docs.pmd-code.org/snapshot/pmd_rules_java_codestyle.html#localvariablecouldbefinal
|
|
Local variable 'responseEntity' could be declared final:
src/main/java/uk/gov/hmcts/cp/services/CaseUrnMapperService.java#L33
A local variable assigned only once can be declared final.
LocalVariableCouldBeFinal (Priority: 3, Ruleset: Code Style)
https://docs.pmd-code.org/snapshot/pmd_rules_java_codestyle.html#localvariablecouldbefinal
|
Artifacts
Produced during runtime
| Name | Size | Digest | |
|---|---|---|---|
|
PMD Report
Expired
|
1.4 KB |
sha256:0f097be670c2435aa72b5a048103db8902dfa8b555ac0e5504f31d956c89fe39
|
|