Skip to content

Database schema change - whole app refactor #28

Database schema change - whole app refactor

Database schema change - whole app refactor #28

Triggered via pull request August 8, 2024 16:18
Status Success
Total duration 37s
Artifacts 1

pmdscan.yml

on: pull_request
scan-the-code
27s
scan-the-code
Fit to window
Zoom out
Zoom in

Annotations

10 errors and 13 warnings
Logger calls should be surrounded by log level guards.: file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/clients/car/CarApiClient.java#L61
Whenever using a log level, one should check if the loglevel is actually enabled, or otherwise skip the associate String creation and manipulation. 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/pmd-doc-7.4.0/pmd_rules_java_bestpractices.html#guardlogstatement
Logger calls should be surrounded by log level guards.: file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/clients/car/CarApiService.java#L25
Whenever using a log level, one should check if the loglevel is actually enabled, or otherwise skip the associate String creation and manipulation. 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/pmd-doc-7.4.0/pmd_rules_java_bestpractices.html#guardlogstatement
Logger calls should be surrounded by log level guards.: file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/clients/car/CarApiService.java#L27
Whenever using a log level, one should check if the loglevel is actually enabled, or otherwise skip the associate String creation and manipulation. 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/pmd-doc-7.4.0/pmd_rules_java_bestpractices.html#guardlogstatement
Logger calls should be surrounded by log level guards.: file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/clients/weather/WeatherApiClient.java#L60
Whenever using a log level, one should check if the loglevel is actually enabled, or otherwise skip the associate String creation and manipulation. 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/pmd-doc-7.4.0/pmd_rules_java_bestpractices.html#guardlogstatement
Logger calls should be surrounded by log level guards.: file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/clients/weather/WeatherApiClient.java#L77
Whenever using a log level, one should check if the loglevel is actually enabled, or otherwise skip the associate String creation and manipulation. 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/pmd-doc-7.4.0/pmd_rules_java_bestpractices.html#guardlogstatement
Return an empty collection rather than null.: file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/offer/SelectedOfferService.java#L37
For any method that returns an collection (such as an array, Collection or Map), it is better to return an empty one rather than a null reference. This removes the need for null checking all results and avoids inadvertent NullPointerExceptions. See Effective Java, 3rd Edition, Item 54: Return empty collections or arrays instead of null ReturnEmptyCollectionRatherThanNull (Priority: 1, Ruleset: Error Prone) https://docs.pmd-code.org/pmd-doc-7.4.0/pmd_rules_java_errorprone.html#returnemptycollectionratherthannull
The constant name 'logger' doesn't match '[A-Z][A-Z_0-9]*': file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/security/JwtAuthenticationFilter.java#L28
Configurable naming conventions for field declarations. This rule reports variable declarations which do not match the regex that applies to their specific kind ---e.g. constants (static final), enum constant, final field. Each regex can be configured through properties. By default this rule uses the standard Java naming convention (Camel case), and uses the ALL_UPPER convention for constants and enum constants. FieldNamingConventions (Priority: 1, Ruleset: Code Style) https://docs.pmd-code.org/pmd-doc-7.4.0/pmd_rules_java_codestyle.html#fieldnamingconventions
Logger calls should be surrounded by log level guards.: file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/security/JwtAuthenticationFilter.java#L51
Whenever using a log level, one should check if the loglevel is actually enabled, or otherwise skip the associate String creation and manipulation. 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/pmd-doc-7.4.0/pmd_rules_java_bestpractices.html#guardlogstatement
Logger calls should be surrounded by log level guards.: file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/security/JwtAuthenticationFilter.java#L56
Whenever using a log level, one should check if the loglevel is actually enabled, or otherwise skip the associate String creation and manipulation. 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/pmd-doc-7.4.0/pmd_rules_java_bestpractices.html#guardlogstatement
Logger calls should be surrounded by log level guards.: file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/security/JwtAuthenticationFilter.java#L61
Whenever using a log level, one should check if the loglevel is actually enabled, or otherwise skip the associate String creation and manipulation. 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/pmd-doc-7.4.0/pmd_rules_java_bestpractices.html#guardlogstatement
scan-the-code
The following actions uses Node.js version which is deprecated and will be forced to run on node20: actions/checkout@v3, actions/setup-java@v3, pmd/pmd-github-action@v1, github/codeql-action/upload-sarif@v2. For more info: https://github.blog/changelog/2024-03-07-github-actions-all-actions-will-run-on-node20-instead-of-node16-by-default/
This utility class has a non-private constructor: file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/AppBackendApplication.java#L12
For classes that only have static methods, consider making them utility classes. Note that this doesn't apply to abstract classes, since their subclasses may well include non-static methods. Also, if you want this class to be a utility class, remember to add a private constructor to prevent instantiation. (Note, that this use was known before PMD 5.1.0 as UseSingleton). UseUtilityClass (Priority: 3, Ruleset: Design) https://docs.pmd-code.org/pmd-doc-7.4.0/pmd_rules_java_design.html#useutilityclass
Parameter 'args' is not assigned and could be declared final: file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/AppBackendApplication.java#L14
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/pmd-doc-7.4.0/pmd_rules_java_codestyle.html#methodargumentcouldbefinal
Missing commented default access modifier on constructor 'CarApiClient(CarApiConfig)': file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/clients/car/CarApiClient.java#L28
To avoid mistakes if we want that an Annotation, Class, Enum, Method, Constructor or Field have a default access modifier we must add a comment at the beginning of its declaration. By default, the comment must be `/* default */` or `/* package */`, if you want another, you have to provide a regular expression. This rule ignores by default all cases that have a `@VisibleForTesting` annotation or any JUnit5/TestNG annotation. Use the property "ignoredAnnotations" to customize the recognized annotations. CommentDefaultAccessModifier (Priority: 3, Ruleset: Code Style) https://docs.pmd-code.org/pmd-doc-7.4.0/pmd_rules_java_codestyle.html#commentdefaultaccessmodifier
Parameter 'carApiConfig' is not assigned and could be declared final: file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/clients/car/CarApiClient.java#L28
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/pmd-doc-7.4.0/pmd_rules_java_codestyle.html#methodargumentcouldbefinal
Parameter 'year' is not assigned and could be declared final: file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/clients/car/CarApiClient.java#L41
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/pmd-doc-7.4.0/pmd_rules_java_codestyle.html#methodargumentcouldbefinal
Parameter 'make' is not assigned and could be declared final: file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/clients/car/CarApiClient.java#L41
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/pmd-doc-7.4.0/pmd_rules_java_codestyle.html#methodargumentcouldbefinal
Parameter 'type' is not assigned and could be declared final: file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/clients/car/CarApiClient.java#L41
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/pmd-doc-7.4.0/pmd_rules_java_codestyle.html#methodargumentcouldbefinal
Local variable 'url' could be declared final: file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/clients/car/CarApiClient.java#L42
A local variable assigned only once can be declared final. LocalVariableCouldBeFinal (Priority: 3, Ruleset: Code Style) https://docs.pmd-code.org/pmd-doc-7.4.0/pmd_rules_java_codestyle.html#localvariablecouldbefinal
Local variable 'responseEntity' could be declared final: file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/clients/car/CarApiClient.java#L53
A local variable assigned only once can be declared final. LocalVariableCouldBeFinal (Priority: 3, Ruleset: Code Style) https://docs.pmd-code.org/pmd-doc-7.4.0/pmd_rules_java_codestyle.html#localvariablecouldbefinal
Local variable 'responseBody' could be declared final: file:///home/runner/work/Car-Service-Garage-Backend/Car-Service-Garage-Backend/src/main/java/com/viepovsky/clients/car/CarApiClient.java#L60
A local variable assigned only once can be declared final. LocalVariableCouldBeFinal (Priority: 3, Ruleset: Code Style) https://docs.pmd-code.org/pmd-doc-7.4.0/pmd_rules_java_codestyle.html#localvariablecouldbefinal
scan-the-code
CodeQL Action v2 will be deprecated on December 5th, 2024. Please update all occurrences of the CodeQL Action in your workflow files to v3. For more information, see https://github.blog/changelog/2024-01-12-code-scanning-deprecation-of-codeql-action-v2/
Deprecation notice: v1, v2, and v3 of the artifact actions
The following artifacts were uploaded using a version of actions/upload-artifact that is scheduled for deprecation: "PMD Report". Please update your workflow to use v4 of the artifact actions. Learn more: https://github.blog/changelog/2024-04-16-deprecation-notice-v3-of-the-artifact-actions/

Artifacts

Produced during runtime
Name Size
PMD Report
812 KB