From 06d701f833d791662bebb0ccfb8410008d537bc4 Mon Sep 17 00:00:00 2001 From: ToineSiebelink Date: Wed, 14 Jan 2026 16:29:40 +0000 Subject: [PATCH] Fix issues missed by checkstyle - Added a module in our checkstyle config to check for unused variable (very surprised this was never there) - the missing finals in ProvMnSException were a false positive since there was a @NoArgsContructor (surprised Sonar didnt realize that) - it was still a code smell though and I refactored the code so we didn't need the allArgsConstructor anymore (nor setters) - also fixed valid warning on access level noArgsCosntructor (checkstyle never caught those before so that's ok) Issue-ID: CPS-3128 Change-Id: I6acc5bd9bc6bd18f30a346e8049ce6ee456c580a Signed-off-by: ToineSiebelink --- .../src/main/resources/cps-checkstyle/cps-java-style.xml | 5 +++-- .../org/onap/cps/ncmp/rest/controller/ProvMnSController.java | 9 ++------- .../org/onap/cps/ncmp/api/exceptions/ProvMnSException.java | 12 ++++-------- .../java/org/onap/cps/ncmp/impl/provmns/ParameterHelper.java | 3 ++- .../src/main/java/org/onap/cps/impl/CpsDataServiceImpl.java | 3 +-- 5 files changed, 12 insertions(+), 20 deletions(-) diff --git a/checkstyle/src/main/resources/cps-checkstyle/cps-java-style.xml b/checkstyle/src/main/resources/cps-checkstyle/cps-java-style.xml index 6e1664a4a3..a7c36b85ab 100644 --- a/checkstyle/src/main/resources/cps-checkstyle/cps-java-style.xml +++ b/checkstyle/src/main/resources/cps-checkstyle/cps-java-style.xml @@ -1,6 +1,6 @@