cps.git
2 weeks agocomplete flow for subscription delete 14/142114/17
shikha0203 [Tue, 23 Sep 2025 09:15:24 +0000 (10:15 +0100)]
complete flow for subscription delete

- Consume dataJobDeleted events and extract relevant details
- Query affected dataNodeSelectors and subscription details from DMI
- Remove target subscriber from arrays, keeping remaining subscribers intact
- If last subscriber is removed, delete entire entry
- Send the delete event to the relevant DMI
- Update tracking of subscription removal throughout the system

Issue-ID: CPS-2724
Change-Id: I9ed6c2553dd2573dd18f356efefa0a713c1c2627
Signed-off-by: shikha0203 <shivani.khare@est.tech>
4 weeks agoMerge "Refactor EventsProducer class to remove Generic type for legacyevent"
Toine Siebelink [Thu, 25 Sep 2025 16:19:21 +0000 (16:19 +0000)]
Merge "Refactor EventsProducer class to remove Generic type for legacyevent"

4 weeks agoMerge "Change parent node xPath for saving subscription"
Priyank Maheshwari [Thu, 25 Sep 2025 13:15:14 +0000 (13:15 +0000)]
Merge "Change parent node xPath for saving subscription"

4 weeks agoRefactor EventsProducer class to remove Generic type for legacyevent 18/142118/1
mpriyank [Wed, 24 Sep 2025 12:22:21 +0000 (13:22 +0100)]
Refactor EventsProducer class to remove Generic type for legacyevent

- EventsProducer refactored to not use generic type and instead use
  LegacyEvent type for all the events that still uses non-cloud events.
- Events are implementing LegacyEvent interface now just to
  differentiate b/w cloud and non-cloud events when creating a
  kafkatemplate to send events

Issue-ID: CPS-2990
Change-Id: Ic905ceadefca9e492cb999b633c86d13227c30c2
Signed-off-by: mpriyank <priyank.maheshwari@est.tech>
4 weeks agoMerge "Control Model loader execution Order"
Priyank Maheshwari [Thu, 25 Sep 2025 10:12:51 +0000 (10:12 +0000)]
Merge "Control Model loader execution Order"

4 weeks agoMerge "Local k8s env. running k6 test (Split-1)"
Priyank Maheshwari [Thu, 25 Sep 2025 09:52:26 +0000 (09:52 +0000)]
Merge "Local k8s env. running k6 test (Split-1)"

5 weeks agoChange parent node xPath for saving subscription 10/142110/1
emaclee [Tue, 23 Sep 2025 16:34:23 +0000 (17:34 +0100)]
Change parent node xPath for saving subscription

- wrong parent node xPath was used by calling wrong method ,
  should be /dataJob and not '/'

Issue-ID: CPS-2723
Change-Id: I62549bc1c0df4359de1f89d5951f351fdeed830d
Signed-off-by: emaclee <lee.anjella.macabuhay@est.tech>
5 weeks agoControl Model loader execution Order 09/142109/1
ToineSiebelink [Wed, 24 Sep 2025 08:31:45 +0000 (09:31 +0100)]
Control Model loader execution Order

- Use @Order annotation to execute model loader sequentially instead of parallel
- Removed duplicated steps between model loaders (just one)
- Improved and consistent logging for each model loader starting and stopping

Issue-ID: CPS-2988
Change-Id: Icd1bb365a65831fbef52f6d9881d8d23dbb3c8aa
Signed-off-by: ToineSiebelink <toine.siebelink@est.tech>
5 weeks agoMerge "Manual Implementation of ProvMnS controller"
Priyank Maheshwari [Tue, 23 Sep 2025 15:32:50 +0000 (15:32 +0000)]
Merge "Manual Implementation of ProvMnS controller"

5 weeks agoMerge "Consume 'ACCEPTED' create response event from DMI"
Priyank Maheshwari [Tue, 23 Sep 2025 15:01:26 +0000 (15:01 +0000)]
Merge "Consume 'ACCEPTED' create response event from DMI"

5 weeks agoConsume 'ACCEPTED' create response event from DMI 60/142060/6
emaclee [Wed, 17 Sep 2025 14:09:08 +0000 (15:09 +0100)]
Consume 'ACCEPTED' create response event from DMI

- added agreed schema for dmi out event response
- added method to consume event from DMI for create response
- added method to update subscription status where status is
  ACCEPTED

Issue-ID: CPS-2982
Change-Id: Idbb3046a2fa1aad9d03f06cbbc17d163696c3b7a
Signed-off-by: emaclee <lee.anjella.macabuhay@est.tech>
5 weeks agoMerge "Include a cm-handle-state at the top level"
Toine Siebelink [Tue, 23 Sep 2025 07:55:56 +0000 (07:55 +0000)]
Merge "Include a cm-handle-state at the top level"

5 weeks agoMerge "Uplift dependency versions to eliminate vulnerabilities"
Toine Siebelink [Tue, 23 Sep 2025 07:40:42 +0000 (07:40 +0000)]
Merge "Uplift dependency versions to eliminate vulnerabilities"

5 weeks agoManual Implementation of ProvMnS controller 14/142014/6
seanbeirne [Tue, 12 Aug 2025 15:04:47 +0000 (16:04 +0100)]
Manual Implementation of ProvMnS controller

- Implementation of ProvMnS using spring

Issue-ID: CPS-2966
Change-Id: Ia767b2779aa7b741230f295886f898246daf025c
Signed-off-by: seanbeirne <sean.beirne@est.tech>
5 weeks agoUplift dependency versions to eliminate vulnerabilities 03/142103/1
egernug [Mon, 22 Sep 2025 12:43:16 +0000 (13:43 +0100)]
Uplift dependency versions to eliminate vulnerabilities

-Springboot to 3.5.6
-Postgres to 42.7.8

Issue-ID: CPS-2747

Change-Id: I3161ba870ad9a16d0f11be2b019c8ae1fab393c4
Signed-off-by: egernug <gerard.nugent@est.tech>
5 weeks agoInclude a cm-handle-state at the top level 31/142031/4
egernug [Wed, 10 Sep 2025 12:36:13 +0000 (13:36 +0100)]
Include a cm-handle-state at the top level

- Added cm-handle-state to YangModelCmHandle
- Amended tests to include new property

Issue-ID: CPS-2922

Change-Id: I82333eb69b4b5d77a76cb15868d7e7e6865de9e2
Signed-off-by: egernug <gerard.nugent@est.tech>
5 weeks agoBump lfit/releng-reusable-workflows from 0.2.18 to 0.2.19 99/142099/1
dependabot[bot] [Mon, 22 Sep 2025 00:45:50 +0000 (00:45 +0000)]
Bump lfit/releng-reusable-workflows from 0.2.18 to 0.2.19

Bumps [lfit/releng-reusable-workflows](https://github.com/lfit/releng-reusable-workflows) from 0.2.18 to 0.2.19.
- [Release notes](https://github.com/lfit/releng-reusable-workflows/releases)
- [Commits](https://github.com/lfit/releng-reusable-workflows/compare/8c3cf221da0e47955647647c9a254c1f807081ce...f318aaac9f4fce73a8059fe95ba9080833e018c2)

updated-dependencies:
- dependency-name: lfit/releng-reusable-workflows
  dependency-version: 0.2.19
  dependency-type: direct:production
  update-type: version-update:semver-patch

CIMAN-33

Change-Id: I6903eace93b637407f106b25592e8b1cd5adbec7
Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: onap.gh2gerrit <releng+onap-gh2gerrit@linuxfoundation.org>
5 weeks agoCI: Add Github2Gerrit workflow 77/142077/1
Kevin Sandi [Fri, 19 Sep 2025 19:54:02 +0000 (13:54 -0600)]
CI: Add Github2Gerrit workflow

Issue-ID: CIMAN-33
Change-Id: Ieffd064d98784d237ca19314cb1b3712691db2b6
Signed-off-by: Kevin Sandi <ksandi@contractor.linuxfoundation.org>
5 weeks agoLocal k8s env. running k6 test (Split-1) 68/142068/1
halil.cakal [Fri, 19 Sep 2025 11:41:41 +0000 (12:41 +0100)]
Local k8s env. running k6 test (Split-1)

- add a new service for kafka to provide broker external connectivity
- update resources with remedy values (hardware resources will be align
  with stakeholder requirements later)
- update kafka broker address to correct one for dmi-stub
- update licence headers for readme.md

Issue-ID: CPS-2967

Change-Id: I518f3c8f620efd3965efb6a5d1fa19a12ce28676
Signed-off-by: halil.cakal <halil.cakal@est.tech>
5 weeks agoMerge "Bug: Update operation executes on a data node that is not present in the database"
Priyank Maheshwari [Thu, 18 Sep 2025 11:29:31 +0000 (11:29 +0000)]
Merge "Bug: Update operation executes on a data node that is not present in the database"

5 weeks agoBug: Update operation executes on a data node that is not present in the database 33/142033/8
Arpit Singh [Thu, 11 Sep 2025 06:46:46 +0000 (12:16 +0530)]
Bug: Update operation executes on a data node that is not present in the database

Failing test where an attempt is made to update a data node that does not exist
in database.
The test shows that no exception is thrown when such datanode is
updated.

Issue-ID: CPS-2980
Change-Id: Ia42b66016be4e880e6207916c4f98b9aa3069dad
Signed-off-by: Arpit Singh <AS00745003@techmahindra.com>
6 weeks agoMerge "Remove CpsDataService dependency from DeltaReportExecutor"
Priyank Maheshwari [Wed, 17 Sep 2025 14:08:45 +0000 (14:08 +0000)]
Merge "Remove CpsDataService dependency from DeltaReportExecutor"

6 weeks agoRemove CpsDataService dependency from DeltaReportExecutor 25/141625/7
Arpit Singh [Mon, 25 Aug 2025 14:26:02 +0000 (19:56 +0530)]
Remove CpsDataService dependency from DeltaReportExecutor

CpsDataService is injected as bean in DeltaReportExecutor, This is
causing a cyclic dependency impacting CPS-2523(in progress).

The cyclic dependency forming is as follows:
CpsDataServiceImpl->CpsDeltaServiceImpl->DeltaReportExecutor->CpsDataService

The solution implemented is for DeltaReportExecutor to directly call
CpsDataPersistenceService

Since the cps delta service does not depend on CpsDataService, the
data validation steps which were present in CpsDataService have been
implemented in CpsDeltaServiceImpl and DeltaReportExecutor.

Issue-ID: CPS-2964
Change-Id: I1eecee22f67139eda111948d8aafad62c17340e2
Signed-off-by: Arpit Singh <AS00745003@techmahindra.com>
6 weeks agoSubscription CREATE flow 03/142003/11
emaclee [Mon, 8 Sep 2025 14:58:01 +0000 (15:58 +0100)]
Subscription CREATE flow

- cover scenarios of the following: add subscription for non
  existing details in database, add subscription for overlapping
  details
- method first persists subscription and then send relevant
  details to DMIs
- remove classes, files and configuration that was from legacy
  subscription implementation

Issue-ID: CPS-2723
Change-Id: Iee60da409ced76874e0208e4284b7d5cd00c9f6a
Signed-off-by: emaclee <lee.anjella.macabuhay@est.tech>
6 weeks agoMerge "Update JEX Parser method"
Toine Siebelink [Mon, 15 Sep 2025 16:32:03 +0000 (16:32 +0000)]
Merge "Update JEX Parser method"

6 weeks agoUpdate JEX Parser method 02/142002/10
ToineSiebelink [Fri, 5 Sep 2025 16:11:39 +0000 (17:11 +0100)]
Update JEX Parser method

-JEX parser needs to be updated to accommodate consumer and service methods in NCMP
-updated NcmpInEventConsumer and NcmpInEventConsumerSpec class
-Ensure REGEX for XPaths is safe and performant

Issue-ID: CPS-2976
Change-Id: Ibe55c2574d49561f989463702f4f8a495d9de35f
Signed-off-by: ToineSiebelink <toine.siebelink@est.tech>
7 weeks agoLast inspect on all modules 18/142018/3
ToineSiebelink [Tue, 9 Sep 2025 11:46:29 +0000 (12:46 +0100)]
Last inspect on all modules

- Mainly focussed on spelling mistakes (e.g. schema set instead of schemaset)
- Removed some unused code (overloaded but unused interface methods)
- spelling issues resolve in many timed method (names) by adding full stops.
  I think this only affects Graphana dashboards etc and should be OK
- Changed timeformat descriptions to say just "ISO standard format"
- Fixed latest SonarQube warnings
  (removed test from MultiPartFileUtilSpec as the scenarios are correctly unit-tested in ZipFileSizeValidatorSpec)

Issue-ID:CPS-2941

Change-Id: Ia654be16881b65b21522a554d6a70a3b38a6379e
Signed-off-by: ToineSiebelink <toine.siebelink@est.tech>
7 weeks agoMerge "Add test coverage for last missed branch in cps-service"
Priyank Maheshwari [Tue, 9 Sep 2025 10:18:56 +0000 (10:18 +0000)]
Merge "Add test coverage for last missed branch in cps-service"

7 weeks agoMerge "Make original delta report format consistent with delta report new format"
Priyank Maheshwari [Tue, 9 Sep 2025 10:16:30 +0000 (10:16 +0000)]
Merge "Make original delta report format consistent with delta report new format"

7 weeks agoMerge "More fixes suggested by Project-wide Inspect Code..."
Lee Anjella Macabuhay [Mon, 8 Sep 2025 13:46:16 +0000 (13:46 +0000)]
Merge "More fixes suggested by Project-wide Inspect Code..."

7 weeks agoAdd test coverage for last missed branch in cps-service 00/142000/1
ToineSiebelink [Mon, 8 Sep 2025 10:17:54 +0000 (11:17 +0100)]
Add test coverage for last missed branch in cps-service

- Add test for user-order leaf-list using test-tree model
 (see https://en.wikipedia.org/wiki/The_Rattlin%27_Bog)

Issue-ID: CPS-475
Change-Id: I1adf107289e7fa0a9f832bfdc4267c04615eaa28
Signed-off-by: ToineSiebelink <toine.siebelink@est.tech>
7 weeks agoUpdated onboardOrUpgradeModel in InventoryModelLoader to check if module revision... 90/141990/1
sourabh_sourabh [Thu, 4 Sep 2025 16:44:47 +0000 (17:44 +0100)]
Updated onboardOrUpgradeModel in InventoryModelLoader to check if module revision already installed for all scenario

 - Simplified conditional flow by removing duplicate revision checks.

Issue-ID: CPS-2974
Change-Id: I8e5ca62c60a33eb01abffbd917a98e18fefb22f0
Signed-off-by: sourabh_sourabh <sourabh.sourabh@est.tech>
7 weeks agoMore fixes suggested by Project-wide Inspect Code... 91/141991/1
ToineSiebelink [Thu, 4 Sep 2025 14:28:04 +0000 (15:28 +0100)]
More fixes suggested by Project-wide Inspect Code...

- Removed some code duplication highlighted by Inspect
- Refactored some logging duplication
- Corrected suspected duplicate logging by correcting the message (copy&paste error)
- Added 1 or 2 null checks as suggested by Inspect (might need test for coverage)

Issue-ID: CPS-2941
Change-Id: I2119535ecb2fc377309da3bd9e3777f71b711b9a
Signed-off-by: ToineSiebelink <toine.siebelink@est.tech>
7 weeks agoMerge "update and use cm data job subscription model"
Lee Anjella Macabuhay [Thu, 4 Sep 2025 15:47:17 +0000 (15:47 +0000)]
Merge "update and use cm data job subscription model"

7 weeks agoMerge "Fix issue with package name cmnotificationsubscription"
Lee Anjella Macabuhay [Thu, 4 Sep 2025 14:00:53 +0000 (14:00 +0000)]
Merge "Fix issue with package name cmnotificationsubscription"

7 weeks agoMerge "Add ReadinessHealthIndicator to expose migration readiness status"
Toine Siebelink [Thu, 4 Sep 2025 12:00:29 +0000 (12:00 +0000)]
Merge "Add ReadinessHealthIndicator to expose migration readiness status"

7 weeks agoFix issue with package name cmnotificationsubscription 89/141989/1
ToineSiebelink [Thu, 4 Sep 2025 10:49:28 +0000 (11:49 +0100)]
Fix issue with package name cmnotificationsubscription

- removed _1_0_0 postfix (inconsistent with others)
- renamed/moved to ../datajobs/subscriptions

Issue-ID: CPS-2941
Change-Id: I2d461ecabc8d404bb9e936ef0a528eb98735ac03
Signed-off-by: ToineSiebelink <toine.siebelink@est.tech>
7 weeks agoAdd ReadinessHealthIndicator to expose migration readiness status 69/141969/6
sourabh_sourabh [Tue, 2 Sep 2025 16:22:06 +0000 (17:22 +0100)]
Add ReadinessHealthIndicator to expose migration readiness status

- Reports READY when migrations are complete.
- Reports NOT READY when a migration or rollback is in progress.
- This will allow Helm (Kubernetes) and other monitoring tools to detect application readiness during migrations and act accordingly.

Issue-ID: CPS-2974
Change-Id: I72441e186178d4cbd0cd98e754ca6059b4ff0bb6
Signed-off-by: sourabh_sourabh <sourabh.sourabh@est.tech>
7 weeks agoupdate and use cm data job subscription model 88/141988/2
shikha0203 [Wed, 3 Sep 2025 16:35:14 +0000 (17:35 +0100)]
update and use cm data job subscription model

Issue-ID: CPS-2971
Change-Id: I68368d5253e4e8aacfc4279527202acf91caa6e2
Signed-off-by: shikha0203 <shivani.khare@est.tech>
7 weeks agoMerge "Refactor(deployment): make environment variables explicit for cps container"
Lee Anjella Macabuhay [Thu, 4 Sep 2025 09:02:22 +0000 (09:02 +0000)]
Merge "Refactor(deployment): make environment variables explicit for cps container"

8 weeks agoMerge "Code Inspection WHOLE project"
Lee Anjella Macabuhay [Wed, 3 Sep 2025 16:43:06 +0000 (16:43 +0000)]
Merge "Code Inspection WHOLE project"

8 weeks agoRefactor(deployment): make environment variables explicit for cps container 68/141968/3
sourabh_sourabh [Tue, 2 Sep 2025 13:56:25 +0000 (14:56 +0100)]
Refactor(deployment): make environment variables explicit for cps container

 - Replaced dynamic env loop with explicit environment variable definitions
  (DB_HOST, DB_USERNAME, DB_PASSWORD, DMI_USERNAME, DMI_PASSWORD, KAFKA_BOOTSTRAP_SERVER).
 - Made dmi stub env. variable from string to integer for ms

Issue-ID: CPS-2973
Change-Id: Icc2962f03fe078ac85d5097f8e5d56620c79800b
Signed-off-by: sourabh_sourabh <sourabh.sourabh@est.tech>
8 weeks agoMerge "update readme.md for cps charts"
Priyank Maheshwari [Wed, 3 Sep 2025 09:31:02 +0000 (09:31 +0000)]
Merge "update readme.md for cps charts"

8 weeks agoMerge "Inconsistency With JSON Response(List Items) Using ReplaceANode API"
Priyank Maheshwari [Wed, 3 Sep 2025 09:08:54 +0000 (09:08 +0000)]
Merge "Inconsistency With JSON Response(List Items) Using ReplaceANode API"

8 weeks agoMerge "Add requestID and clientID in cps core logs"
Priyank Maheshwari [Wed, 3 Sep 2025 07:52:54 +0000 (07:52 +0000)]
Merge "Add requestID and clientID in cps core logs"

8 weeks agoCode Inspection WHOLE project 72/141972/1
ToineSiebelink [Tue, 2 Sep 2025 15:55:15 +0000 (16:55 +0100)]
Code Inspection WHOLE project

- applied most of the simple/safe stuff
- Many @suppress unchecked-warnings
- Many @Serial annotations
- A lot of copyrights updates!

Issue-ID: CPS-2941
Change-Id: Id926ba1e9d7c6e0941355f89e5c736907e7af165
Signed-off-by: ToineSiebelink <toine.siebelink@est.tech>
8 weeks agoUpdated the k8s objects with correct labels 46/141946/3
mpriyank [Wed, 27 Aug 2025 13:35:22 +0000 (14:35 +0100)]
Updated the k8s objects with correct labels

- added the label for app=cps-and-ncmp to all the kubernetes objects
- also added the relevant components label based on the type of
  kubernetes object
- added a custom service account cps-hazelcast-service-account to just
  provide the least amount of priviledges
- added cps-hazelcast-rbac file so that the hazelcast members are able
  to discover using the k8s discovery service

Issue-ID: CPS-2960
Change-Id: I32d76fc3a955bd846c5e6aa0d78b80b8995a9c42
Signed-off-by: mpriyank <priyank.maheshwari@est.tech>
8 weeks agoModified Inventory loader to handle module install or upgrade based on flag 62/141962/7
sourabh_sourabh [Wed, 27 Aug 2025 10:44:10 +0000 (11:44 +0100)]
Modified Inventory loader to handle module install or upgrade based on flag

Issue-ID: CPS-2970
Change-Id: I5b8b0aa2db3fcad6da2a5dd774720f22855523cd
Signed-off-by: sourabh_sourabh <sourabh.sourabh@est.tech>
8 weeks agoInconsistency With JSON Response(List Items) Using ReplaceANode API 18/140718/19
Rudrangi Anupriya [Thu, 17 Jul 2025 11:09:13 +0000 (16:39 +0530)]
Inconsistency With JSON Response(List Items) Using ReplaceANode API

Jira - https://lf-onap.atlassian.net/browse/CPS-2800
Documentation - https://lf-onap.atlassian.net/wiki/x/gIDMAQ

- Updated DataRestController.java to return 201 for new nodes
- CpsDataService.java Changed method signature to return boolean
- Added logic to detect new nodes in CpsDataServiceImpl.java
- Implements the new logic for detecting and inserting new nodes in CpsDataPersistenceServiceImpl.java
- Added testcases for above changes

Issue-ID: CPS-2800
Change-Id: Ibc9bbb88ccbb07302355321c6d5c2eade0e7e5fb
Signed-off-by: Rudrangi Anupriya <ra00745022@techmahindra.com>
Signed-off-by: GM001016278 <gourav.malviya@techmahindra.com>
8 weeks agoFix more spelling mistakes 67/141967/1
ToineSiebelink [Tue, 2 Sep 2025 09:13:32 +0000 (10:13 +0100)]
Fix more spelling mistakes

- Remove time stamp formatting from comments (its OK in code)
  (also reused existing formatter utility)
- added . (full stops) separators in counter names to make them acceptable words

Issue-ID: CPS-2972
Change-Id: I6ee457fac880edd35b141b8c8b785208ca338e48
Signed-off-by: ToineSiebelink <toine.siebelink@est.tech>
8 weeks agoAdd requestID and clientID in cps core logs 15/140715/25
rajesh.kumar [Tue, 6 May 2025 10:48:04 +0000 (16:18 +0530)]
Add requestID and clientID in cps core logs

- This enhancment is to signicantly improve the traceability and debugging capabilities for specific request flowing through our system.

- Create new class MdcServletFilter.java and added the dofilter to handle Mapped Diagnostic Context setup for capture and link requestID and clientID.

- Added testcases MdcServletFilterSpec.groovy for above changes.

Issue-ID: CPS-2796
Change-Id: I56c34400dc73c71b936a51260efd060505baabdc
Signed-off-by: GM001016278 <gourav.malviya@techmahindra.com>
8 weeks agoupdate readme.md for cps charts 40/141940/2
halil.cakal [Tue, 26 Aug 2025 08:37:41 +0000 (09:37 +0100)]
update readme.md for cps charts

- update release name to cps for helm installation,
   as per requirement it will support only one release which is cps
- update port forwarding commands that are now uses the deployed
  services: cps-cps-and-ncmp-cps and cps-cps-and-ncmp-dmi-stub
- update get all command with correct label

Issue-ID: CPS-2956

Change-Id: Ia864d38b07f8a12f5a3d1b1d6a5358ada8377e23
Signed-off-by: halil.cakal <halil.cakal@est.tech>
8 weeks agoMake original delta report format consistent with delta report new format 84/141284/6
Arpit Singh [Thu, 19 Jun 2025 11:57:01 +0000 (17:27 +0530)]
Make original delta report format consistent with delta report new format

The old delta report only provides information about the leaf nodes that
changed.
The details about the data node are not provided as part of the delta
report.
The change adds node name and JSON sructure of the data node to the
original delta report format.

Issue-ID: CPS-2860
Change-Id: Iac51925f0d0a8ddf1958b47ad372090fbf0d75d9
Signed-off-by: Arpit Singh <AS00745003@techmahindra.com>
2 months agoupdating NcmpInEventConsumer to only log the event information 41/141941/8
shikha0203 [Mon, 25 Aug 2025 10:43:08 +0000 (11:43 +0100)]
updating NcmpInEventConsumer to only log the event information

-event handling will be done in next commit
-rebased

Issue-ID: CPS-2893
Change-Id: I6fe334ce66ef2b4f9e6f7916083821a73a5f7e8f
Signed-off-by: shikha0203 <shivani.khare@est.tech>
2 months agoPoC Code Cleanup WHOLE Project 47/141947/4
ToineSiebelink [Wed, 27 Aug 2025 15:55:00 +0000 (16:55 +0100)]
PoC Code Cleanup WHOLE Project

Check Nordix for comparing IntelliJ Clean Code Differences
(https://gerrit.onap.org/r/c/cps/+/141947)

Patch #1 : Community Edition
Patch #2 : Ultimate Edition
Patch #3 : Community Edition, Manually undo 2 incorrect updates
Patch #4 : #3 plus checkstyle (indentation) and copyright fixes
Patch #5 : #4 plus SonarQube warning fixes & refactoring

Issue-ID:CPS-2941
Change-Id: Idfefbbb501b96644295d043cf6141833da65b2a9
Signed-off-by: ToineSiebelink <toine.siebelink@est.tech>
2 months agoMerge "Data producer id field during cm handle create/update"
Toine Siebelink [Thu, 28 Aug 2025 12:35:13 +0000 (12:35 +0000)]
Merge "Data producer id field during cm handle create/update"

2 months agoData producer id field during cm handle create/update 37/141937/5
mpriyank [Mon, 25 Aug 2025 13:09:21 +0000 (14:09 +0100)]
Data producer id field during cm handle create/update

- updated the CmHandleCreate test to prove that the LcmEvent is not
  triggered during the Cm Handle Create Flow
- added new test for CmHandleUpdate to prove the LcmEvent is triggered
  when updating the data producer id field during the Cm Handle Update
  flow
- refactored the common code and moved it to CpsIntegrationBase spec

Issue-ID: CPS-2963
Change-Id: I11e8b5d7c803334e0eb2979001e783d24c61c6d3
Signed-off-by: mpriyank <priyank.maheshwari@est.tech>
2 months agoMerge "IntelliJ Code Inspection Updates (last NB comment)"
Lee Anjella Macabuhay [Tue, 26 Aug 2025 09:57:38 +0000 (09:57 +0000)]
Merge "IntelliJ Code Inspection Updates (last NB comment)"

2 months agoIntelliJ Code Inspection Updates (last NB comment) 38/141938/1
ToineSiebelink [Mon, 25 Aug 2025 16:22:36 +0000 (17:22 +0100)]
IntelliJ Code Inspection Updates (last NB comment)

Issue-ID: CPS-2941
Change-Id: Ib51ad47456b44ab4e33c9d146da892f20a2b6d6f
Signed-off-by: ToineSiebelink <toine.siebelink@est.tech>
2 months agoMerge "IntelliJ Code Inspection Updates"
Priyank Maheshwari [Fri, 22 Aug 2025 10:21:22 +0000 (10:21 +0000)]
Merge "IntelliJ Code Inspection Updates"

2 months agoIntelliJ Code Inspection Updates 77/141877/9
ToineSiebelink [Tue, 19 Aug 2025 11:43:19 +0000 (12:43 +0100)]
IntelliJ Code Inspection Updates

- Use Lombok where possible
- Removed unused (interface) methods
- Removed parameters where method was called with only 1 (always same) value.
    This lead to so manual refactoring, more specific method names etc.
    For data job read I logged some details to get over this as the implementation is currently on hold/blocked
- Use 'record' (instead of class) where possible
- Apply @serial annotation
- Fixed unused result from matcher.find() We used to catch exceptions instead which is very bad :-(
- Some unused constant/return values needed for consistency, used annotation to ignore thee warning
- Removed Enum private value that was identical to Enum itself
- Uncheck casting, just added annotation to prevent warning I think they are all safe because we know and control the model
- Use {} for logging instead on string concatenation
- Use <a></a> for links in Javadoc
- Added missed null-checks
- Manually updated groovy test classes that were affected by some of above
- Spelling and grammar, original about 200 errors
     using 'Id' (with uppercase) I was flagged as a grammar issue and I like the idea of consistently using 'id' lower case in descriptions
     most typos where actually fixed by adding some work to the dictionary like cmhandle, onap, etsi etc.
     about 10% were genuine errors which also 2 or 3 variables affected which I have corrected now
- Security
     flagged some (http) links with suppress as we cannot change them
     some dependency issues remaining, need to check with Ger, looks like correct early warning without need for any CIO job or other tools!
- CODE ANALYZER ON WHOLE PROJECT
      only 4 java updates! inserted 2 finals (1 reverted as it was needed for test!), removed unnecessary casting in 2 places
      incorrectly add = sing in a cert.properties file for socker which I reverted

Issue-ID: CPS-2941
Change-Id: I439237422b01d533ae1c9301cbfcedbebf922fd4
Signed-off-by: ToineSiebelink <toine.siebelink@est.tech>
2 months agoUpdate data producer id and send LCM event 49/141849/3
mpriyank [Wed, 13 Aug 2025 16:39:06 +0000 (17:39 +0100)]
Update data producer id and send LCM event

- Logic updated for setting the data producer id
   * null to value is allowed
   * some-value to other-value allowed
   * other-value to null is not allowed and ignored
   * some-value to some-value is not allowed and ignored
- LCM event is raised only when the data producer identifier is updated
- added testware for the same

Issue-ID: CPS-2935
Change-Id: I0c194ed5da37affd3f82889520685bb9c1d4cdae
Signed-off-by: mpriyank <priyank.maheshwari@est.tech>
2 months agoDisabling NCMP CSIT execution 81/141881/2
mpriyank [Wed, 20 Aug 2025 22:05:27 +0000 (23:05 +0100)]
Disabling NCMP CSIT execution

- temporarily disabling the NCMP CSIT execution as they are unstable at
  the moment

Issue-ID: CPS-2959
Change-Id: Ic60adcdbad98899de0b6c56623717ccdc4f8fc37
Signed-off-by: mpriyank <priyank.maheshwari@est.tech>
2 months agoMerge "REST operations using Delta Report"
Priyank Maheshwari [Wed, 20 Aug 2025 15:02:30 +0000 (15:02 +0000)]
Merge "REST operations using Delta Report"

2 months agoREST operations using Delta Report 84/140584/33
Arpit Singh [Fri, 28 Mar 2025 13:24:30 +0000 (18:54 +0530)]
REST operations using Delta Report

- Feature that uses the delta report to perform REST operations.
- The code uses underlying CPS data java interface logic to perform the
  REST operations.
- The REST operations are executed based on the 'action' identified in the
  delta report.
- The supported operations are: create, delete and update.
- Fixed indentation error in CpsDataServiceImpl

Issue-ID: CPS-2614
Change-Id: Ic1c9f5d2320afd8e4fb49b638e6636291124ea75
Signed-off-by: Arpit Singh <AS00745003@techmahindra.com>
2 months agoMerge "Modify methods in CmSubscriptionPersistenceService"
Priyank Maheshwari [Tue, 19 Aug 2025 18:16:07 +0000 (18:16 +0000)]
Merge "Modify methods in CmSubscriptionPersistenceService"

2 months agoMerge "JEX expression parser"
Priyank Maheshwari [Tue, 19 Aug 2025 16:03:07 +0000 (16:03 +0000)]
Merge "JEX expression parser"

2 months agoJEX expression parser 82/141682/11
shikha0203 [Tue, 12 Aug 2025 11:17:37 +0000 (12:17 +0100)]
JEX expression parser

-Splits a multiline selector string into individual lines
-Resolves the nearest alternate ID from a single selector
-Returns a list of alternate IDs

Issue-ID: CPS-2892
Change-Id: I067c99c81d5ad8da9c582537e7fcf2d8d22e7dc9
Signed-off-by: shikha0203 <shivani.khare@est.tech>
2 months agoModify methods in CmSubscriptionPersistenceService 71/141671/6
emaclee [Fri, 8 Aug 2025 16:36:11 +0000 (17:36 +0100)]
Modify methods in CmSubscriptionPersistenceService

- existing methods of CmSubscriptionPersistenceService to fit the new cm subscription model
- unit tests updated, not used tests removed
- DmiCacheHandler, DmiCacheHandlerSpec, CmSubscriptionComparator, CmSubscriptionComparatorSpec was only modified to pass tests due to changes on persistence service methods - these classes will be changed as part of CPS-2166 development

Issue-ID: CPS-2919
Change-Id: Ic0e470a9993b8a9d7414e301a199564490d0a044
Signed-off-by: emaclee <lee.anjella.macabuhay@est.tech>
2 months agoMerge "Knowledge Sharing: Groovy/Spock best practices refactoring"
Lee Anjella Macabuhay [Mon, 18 Aug 2025 10:25:23 +0000 (10:25 +0000)]
Merge "Knowledge Sharing: Groovy/Spock best practices refactoring"

2 months agoKnowledge Sharing: Groovy/Spock best practices refactoring 35/141835/4
ToineSiebelink [Thu, 14 Aug 2025 15:04:55 +0000 (16:04 +0100)]
Knowledge Sharing: Groovy/Spock best practices refactoring

This commit shows many bad (before)/good (after) practises with Spock/Groovy Unit test like
- Mocking behavior and checking invocation (don't do both normally)
- When to use the word 'some' or 'my' for test variables/strings
- Remove scenarios that only apply to helper classes i.e. no branching in object under test
- Groovy 'magic' instead of java code
- Correct use of GString
- Update descriptions to refer to current (helper) classes an not old ones
- Use of assert keyword
- Consistent check of status code using 3pp constants
- Use 1 line when it is not too long (I don't mind up to 100-120 characters but it is just personal preference)
- Use Static imports where it does not reduce readability

Issue-ID: CPS-2922
Change-Id: If3a803ba3138193fdb75aa0236f9b9875e09ff6c
Signed-off-by: ToineSiebelink <toine.siebelink@est.tech>
2 months agoChore: Add dependabot config 12/141812/1
Kevin Sandi [Wed, 13 Aug 2025 17:57:54 +0000 (11:57 -0600)]
Chore: Add dependabot config

Issue-ID: CIMAN-33
Change-Id: I09a0df4e370c636ea8b26e85a5cdd00c8e5363d0
Signed-off-by: Kevin Sandi <ksandi@contractor.linuxfoundation.org>
2 months agoMerge "RTD update for CM stack use case"
Toine Siebelink [Wed, 13 Aug 2025 14:00:56 +0000 (14:00 +0000)]
Merge "RTD update for CM stack use case"

2 months agoChore: Add dependabot config 04/141704/1
Kevin Sandi [Wed, 13 Aug 2025 01:44:50 +0000 (19:44 -0600)]
Chore: Add dependabot config

Issue-ID: CIMAN-33
Change-Id: Ie682a0ba6b80dfa0c5f18a1141e95a3c113a7233
Signed-off-by: Kevin Sandi <ksandi@contractor.linuxfoundation.org>
2 months agoMerge "Update schema for NCMP to DMI on datajob subscription"
Priyank Maheshwari [Tue, 12 Aug 2025 11:09:48 +0000 (11:09 +0000)]
Merge "Update schema for NCMP to DMI on datajob subscription"

2 months agoRTD update for CM stack use case 60/141660/2
mpriyank [Thu, 7 Aug 2025 15:36:00 +0000 (16:36 +0100)]
RTD update for CM stack use case

- added support for operational datastore in CPS
- note to process the CM Data Notifications from ONAP DMI PLUGIN which
  is configured for data synchronization

Issue-ID: CPS-2918
Change-Id: I808681a1fd14f9d69085439cad15fa315d7ceadf
Signed-off-by: mpriyank <priyank.maheshwari@est.tech>
2 months agoUpdate schema for NCMP to DMI on datajob subscription 55/141655/2
emaclee [Thu, 7 Aug 2025 08:47:20 +0000 (09:47 +0100)]
Update schema for NCMP to DMI on datajob subscription

- based on agreed with E// outlined in https://lf-onap.atlassian.net/wiki/spaces/DW/pages/87984624/CPS-2166+Forwarding+CM+Data+Notification+to+Topic+Defined+in+Subscription#Schema-Definitions
- added target folder structure by adding 'from_to_destination'
  prefix on the new schema and existing datajob operation in
  event schema

Issue-ID: CPS-2920
Change-Id: I03a94ff01fc9bd85953fce2d6bb6757ca84a14e2
Signed-off-by: emaclee <lee.anjella.macabuhay@est.tech>
2 months agoSplit the data sync request using module and root references 53/141653/4
mpriyank [Wed, 6 Aug 2025 12:48:07 +0000 (13:48 +0100)]
Split the data sync request using module and root references

- Introduced a method to get concatenated module and root node for a
  given cm handle(using already synched modules) to use options field
- The request is splitted as some devices dont support fetching the data
  using root url and the devices that support that can in turn return
  huge amount of data in one go.
- Updated the data sync logic to make multiple calls for the initial
  data sync
- The failing requests are ignored and the algorithm works on best
  effort basis
- Testware to support all the above use cases

Issue-ID: CPS-2758
Change-Id: I3d50ef8448705efdd004c6a1ee039e9691f14815
Signed-off-by: mpriyank <priyank.maheshwari@est.tech>
2 months agoMerge "Use new model on subscription model loader"
Priyank Maheshwari [Wed, 6 Aug 2025 08:23:20 +0000 (08:23 +0000)]
Merge "Use new model on subscription model loader"

2 months agoMerge "SONARQUBE ISSUES: 'equals' is deprecated"
Priyank Maheshwari [Tue, 5 Aug 2025 12:41:52 +0000 (12:41 +0000)]
Merge "SONARQUBE ISSUES: 'equals' is deprecated"

2 months agoUse new model on subscription model loader 50/141650/2
emaclee [Tue, 5 Aug 2025 09:34:10 +0000 (10:34 +0100)]
Use new model on subscription model loader

- remove integration test (notification related) for subscription as it is now invalid
  due to development
- modify unit tests with use of new model on onboarding
- onboard new model
- remove old model from repo

Issue-ID: CPS-2890
Change-Id: I47656abb45f8f8c55b1c9d60787510a41dc90f7f
Signed-off-by: emaclee <lee.anjella.macabuhay@est.tech>
2 months agoMerge "New schema for creation/deletion datajob subscription event"
Priyank Maheshwari [Tue, 5 Aug 2025 08:52:37 +0000 (08:52 +0000)]
Merge "New schema for creation/deletion datajob subscription event"

2 months agoSONARQUBE ISSUES: 'equals' is deprecated 49/141649/1
emaclee [Mon, 4 Aug 2025 19:35:23 +0000 (20:35 +0100)]
SONARQUBE ISSUES: 'equals' is deprecated

- equals by StringUtils is deprecated (see https://commons.apache.org/proper/commons-lang/apidocs/org/apache/commons/lang3/StringUtils.html#equals(java.lang.CharSequence,java.lang.CharSequence)
- replaced deprecated based on recommended (See https://commons.apache.org/proper/commons-lang/apidocs/org/apache/commons/lang3/Strings.html#equals(java.lang.CharSequence,java.lang.CharSequence)
- modified import org.apache.logging.log4j.util.Strings to
  import org.apache.commons.lang3.StringUtils for use of
  .isNotBlank to avoid conflict

Issue-ID: CPS-475
Change-Id: I581f839fa48221c3a75e5b23c76ca8d8108adbbc
Signed-off-by: emaclee <lee.anjella.macabuhay@est.tech>
2 months agoAllow get operation on the non-passthrough datastore 33/141633/3
mpriyank [Thu, 31 Jul 2025 11:50:48 +0000 (12:50 +0100)]
Allow get operation on the non-passthrough datastore

- Now that the data can be cached when the data sync is enabled , this
  patch allows to query that data using ncmp-passthrough-operational
  datastore
- Added testware to support the above feature
- Updated outstanding copyright from the last patch

Issue-ID: CPS-2912
Change-Id: I6b62c4b3e83b3cc1616e0dc353a4736f0815b50b
Signed-off-by: mpriyank <priyank.maheshwari@est.tech>
2 months agoBump CPS to 3.7.1 42/141642/3
egernug [Fri, 1 Aug 2025 12:55:17 +0000 (13:55 +0100)]
Bump CPS to 3.7.1

Issue-ID: CPS-2917

Change-Id: If98809f9aa3bdbc8dcf61a76a4e502ece448eadb
Signed-off-by: egernug <gerard.nugent@est.tech>
2 months agoAdded 3.7.0-container.yaml 40/141640/1
egernug [Fri, 1 Aug 2025 12:30:20 +0000 (13:30 +0100)]
Added 3.7.0-container.yaml

Issue-ID: CPS-2917

Change-Id: Iff2f30a313b28806d9f94761822f1d7c8ef706b8
Signed-off-by: egernug <gerard.nugent@est.tech>
2 months agoAdd maven stage yaml 3.7.0 39/141639/1
egernug [Fri, 1 Aug 2025 11:54:32 +0000 (12:54 +0100)]
Add maven stage yaml 3.7.0

Issue-ID: CPS-2917

Change-Id: I3ebf128fbdd4cab07c80d5e65a39ad06cfede703
Signed-off-by: egernug <gerard.nugent@est.tech>
2 months agoUpdate Release Notes for Release 3.7.0 36/141636/3
egernug [Fri, 1 Aug 2025 09:22:18 +0000 (10:22 +0100)]
Update Release Notes for Release 3.7.0

Issue-ID: CPS-2917

Change-Id: I31bd0627df8ccbf19fe8439c1b7a6b1cb30e4c9d
Signed-off-by: egernug <gerard.nugent@est.tech>
2 months agoMerge "Process Cm Avc Event in NCMP"
Lee Anjella Macabuhay [Thu, 31 Jul 2025 09:36:42 +0000 (09:36 +0000)]
Merge "Process Cm Avc Event in NCMP"

2 months agoProcess Cm Avc Event in NCMP 96/141596/9
mpriyank [Mon, 21 Jul 2025 11:21:46 +0000 (12:21 +0100)]
Process Cm Avc Event in NCMP

- process the cm avc event when the source system is set as ONAP DMI
  Plugin in the header
- handle the create , update , patch and delete operation to the CPS
  Cache.
- Testware to support the write operation
- Usage of the RestConf to Cps Path utility in this patch

Issue-ID: CPS-2777
Change-Id: I43233cf52f411a5d3cc20b03d0ef6e6e50399aa7
Signed-off-by: mpriyank <priyank.maheshwari@est.tech>
3 months agoIgnore SonarQube Deprecation Warnings 07/141607/2
ToineSiebelink [Wed, 30 Jul 2025 14:29:55 +0000 (15:29 +0100)]
Ignore SonarQube Deprecation Warnings

- Supressed warning for DeprecationHelper#mapOldConditionProperties
- Actual removal will be done later as part of CPS-2914

Issue-Id: CPS-2914
Change-Id: I3ca9a6f1754af5c34e7925ab76484aaceb482474
Signed-off-by: ToineSiebelink <toine.siebelink@est.tech>
3 months agoNew schema for creation/deletion datajob subscription event 02/141602/1
emaclee [Wed, 30 Jul 2025 09:24:23 +0000 (10:24 +0100)]
New schema for creation/deletion datajob subscription event

- schema is based on analysis and proposal in https://lf-onap.atlassian.net/wiki/spaces/DW/pages/87984624/CPS-2166+Forwarding+CM+Data+Notification+to+Topic+Defined+in+Subscription#Comparison-Subscription-Legacy-Create-Event-and-R1-DataJob-Event

Issue-ID: CPS-2713
Change-Id: I8b9b674720b4b8fdf8cd2153f46e47a8d587e7a8
Signed-off-by: emaclee <lee.anjella.macabuhay@est.tech>
3 months agoMerge "Replaced parameter includeCmHandlePropertiesInQuery by outputDmiProperties"
Toine Siebelink [Wed, 30 Jul 2025 09:31:48 +0000 (09:31 +0000)]
Merge "Replaced parameter includeCmHandlePropertiesInQuery by outputDmiProperties"

3 months agoUplift Springboot to version 3.5.4 97/141597/1
egernug [Tue, 29 Jul 2025 13:45:52 +0000 (14:45 +0100)]
Uplift Springboot to version 3.5.4

- Moved to Springboot 3.5.4 to eliminate vulnerability in netty

Issue-ID: CPS-2747

Change-Id: Id7d2592ccee8624f1ffcbfe77d7f09012e043610
Signed-off-by: egernug <gerard.nugent@est.tech>
3 months agoReplaced parameter includeCmHandlePropertiesInQuery by outputDmiProperties 93/141593/3
shikha0203 [Mon, 28 Jul 2025 14:54:04 +0000 (15:54 +0100)]
Replaced parameter includeCmHandlePropertiesInQuery by outputDmiProperties

Replaced includeCmHandlePropertiesInQuery query parameter in search CM  handle api by outputDmiProperties

Issue-ID: CPS-2908
Change-Id: I4c26ed66c7fbc2ddb58c0f36b6834d5ddb4c993f
Signed-off-by: shikha0203 <shivani.khare@est.tech>
3 months agoMerge "Remove old subscription documentation"
Toine Siebelink [Mon, 28 Jul 2025 12:58:44 +0000 (12:58 +0000)]
Merge "Remove old subscription documentation"

3 months agoRemove old subscription documentation 90/141590/2
emaclee [Mon, 28 Jul 2025 09:27:07 +0000 (10:27 +0100)]
Remove old subscription documentation

- removing old subscription documentation as part of new
  implementation of datajob subscriptions

Issue-ID: CPS-2910
Change-Id: I9eaca0ad685b8d8eb9c8ad0624eb248d09b55b1e
Signed-off-by: emaclee <lee.anjella.macabuhay@est.tech>
3 months agoMerge "Utility to convert restconf style path to cps path"
Lee Anjella Macabuhay [Mon, 28 Jul 2025 12:42:58 +0000 (12:42 +0000)]
Merge "Utility to convert restconf style path to cps path"

3 months agoUtility to convert restconf style path to cps path 75/141575/5
mpriyank [Fri, 18 Jul 2025 13:38:15 +0000 (14:38 +0100)]
Utility to convert restconf style path to cps path

- resource-identifier in passthrough request has restconf style path for
  the devices
- when listening cm avc event on successfull write operation , ncmp has
  to update the cache, hence the path needs to be converted to cps path
  to reuse cps-core services
- added testware to support this
- actual usage of this utility is in the next patch
- for simplicity, utility supports just one key in the path

Issue-ID: CPS-2759
Change-Id: Id3b6e629d134abc0c6b21117f5f157da90248dee
Signed-off-by: mpriyank <priyank.maheshwari@est.tech>
3 months agoCPS local Helm charts 09/141509/11
mpriyank [Tue, 8 Jul 2025 16:28:45 +0000 (18:28 +0200)]
CPS local Helm charts

  - added helm chart
  - added required services (cps, dmi etc)
  - added headless service to access hazelcast service
  - added README

Issue-Id: CPS-2783
Change-Id: I11f0b07b80625a80b414490d630407a262495867
Signed-off-by: leventecsanyi <levente.csanyi@est.tech>
Signed-off-by: mpriyank <priyank.maheshwari@est.tech>