[BUG] Blank alternateId overwrites existing 13/138813/4
authordanielhanrahan <daniel.hanrahan@est.tech>
Mon, 19 Aug 2024 19:34:45 +0000 (20:34 +0100)
committerDaniel Hanrahan <daniel.hanrahan@est.tech>
Wed, 21 Aug 2024 11:15:23 +0000 (11:15 +0000)
commit8d6f9eb63315fc77e85ace9ddca7f2017da7e115
treeeb3837461efe6bb5ae8278bf7a7b7d796ee996e5
parent580fb73de1a1647abfcae156455fd4d299c2907f
[BUG] Blank alternateId overwrites existing

During CM-handle update, a blank "" alternateId will overwrite
an already-set alternateId.
Additionally during registration, if an alternateId consisting of
whitespace is supplied, it will be persisted with whitespace.
This fixes both issues by using isBlank/isNotBlank consistently.

Issue-ID: CPS-2372
Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech>
Change-Id: I44e536cf87a31c6e975a82ed37769c1d2548653a
cps-ncmp-service/src/main/java/org/onap/cps/ncmp/impl/inventory/CmHandleRegistrationService.java
cps-ncmp-service/src/main/java/org/onap/cps/ncmp/impl/inventory/CmHandleRegistrationServicePropertyHandler.java
cps-ncmp-service/src/main/java/org/onap/cps/ncmp/impl/inventory/models/YangModelCmHandle.java
docs/release-notes.rst
integration-test/src/test/groovy/org/onap/cps/integration/functional/ncmp/CmHandleUpdateSpec.groovy [new file with mode: 0644]