summaryrefslogtreecommitdiffstats
path: root/models-interactions/model-yaml/src
diff options
context:
space:
mode:
authorJim Hahn <jrh3@att.com>2020-03-12 18:55:21 -0400
committerJim Hahn <jrh3@att.com>2020-03-12 19:36:44 -0400
commit309c49634bf9fcb53458d3e5f07684cb7bfbdd6f (patch)
treec3d020e98b3ea052f34588a036310ecf0c7032f9 /models-interactions/model-yaml/src
parent77c21cec25d98cf5832acfab38a532006c639669 (diff)
Revert some UUID variable names
Unfortunately, some code uses "new Yaml(...)" to decode policies and "Yaml" doesn't understand GSON annotations. As a result, this means that the field names must match the serialized name, thus they must continue to end with "UUID" instead of "Uuid". Issue-ID: POLICY-1910 Signed-off-by: Jim Hahn <jrh3@att.com> Change-Id: I97c2f5c7e59b758b13a1dbcceed709b2e2e064a2
Diffstat (limited to 'models-interactions/model-yaml/src')
-rw-r--r--models-interactions/model-yaml/src/main/java/org/onap/policy/controlloop/policy/builder/impl/ControlLoopPolicyBuilderImpl.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/models-interactions/model-yaml/src/main/java/org/onap/policy/controlloop/policy/builder/impl/ControlLoopPolicyBuilderImpl.java b/models-interactions/model-yaml/src/main/java/org/onap/policy/controlloop/policy/builder/impl/ControlLoopPolicyBuilderImpl.java
index f1a9540c0..47f6f1494 100644
--- a/models-interactions/model-yaml/src/main/java/org/onap/policy/controlloop/policy/builder/impl/ControlLoopPolicyBuilderImpl.java
+++ b/models-interactions/model-yaml/src/main/java/org/onap/policy/controlloop/policy/builder/impl/ControlLoopPolicyBuilderImpl.java
@@ -114,7 +114,7 @@ public class ControlLoopPolicyBuilderImpl implements ControlLoopPolicyBuilder {
if (service == null) {
throw new BuilderException("Service must not be null");
}
- if (service.getServiceUuid() == null && Strings.isNullOrEmpty(service.getServiceName())) {
+ if (service.getServiceUUID() == null && Strings.isNullOrEmpty(service.getServiceName())) {
throw new BuilderException("Invalid service - need either a serviceUUID or serviceName");
}
if (controlLoopPolicy.getControlLoop().getServices() == null) {
@@ -134,7 +134,7 @@ public class ControlLoopPolicyBuilderImpl implements ControlLoopPolicyBuilder {
if (service == null) {
throw new BuilderException("Service must not be null");
}
- if (service.getServiceUuid() == null && Strings.isNullOrEmpty(service.getServiceName())) {
+ if (service.getServiceUUID() == null && Strings.isNullOrEmpty(service.getServiceName())) {
throw new BuilderException("Invalid service - need either a serviceUUID or serviceName");
}
boolean removed = controlLoopPolicy.getControlLoop().getServices().remove(service);