diff options
Diffstat (limited to 'models-interactions/model-impl/sdnc/src/main')
2 files changed, 7 insertions, 4 deletions
diff --git a/models-interactions/model-impl/sdnc/src/main/java/org/onap/policy/sdnc/SdncManager.java b/models-interactions/model-impl/sdnc/src/main/java/org/onap/policy/sdnc/SdncManager.java index 3679625ec..7612eeb3f 100644 --- a/models-interactions/model-impl/sdnc/src/main/java/org/onap/policy/sdnc/SdncManager.java +++ b/models-interactions/model-impl/sdnc/src/main/java/org/onap/policy/sdnc/SdncManager.java @@ -49,6 +49,7 @@ public final class SdncManager implements Runnable { // The REST manager used for processing REST calls for this Sdnc manager private RestManager restManager; + @FunctionalInterface public interface SdncCallback { public void onCallback(SdncResponse response); } @@ -133,7 +134,7 @@ public final class SdncManager implements Runnable { logger.info(body); response.setRequestId(sdncRequest.getRequestId().toString()); - if (!response.getResponseOutput().getResponseCode().equals("200")) { + if (!"200".equals(response.getResponseOutput().getResponseCode())) { logger.info( "Sdnc Heal Restcall failed with http error code {} {}", httpDetails.first, httpDetails.second ); diff --git a/models-interactions/model-impl/sdnc/src/main/java/org/onap/policy/sdnc/util/Serialization.java b/models-interactions/model-impl/sdnc/src/main/java/org/onap/policy/sdnc/util/Serialization.java index cfaa46fd0..090b4f9b6 100644 --- a/models-interactions/model-impl/sdnc/src/main/java/org/onap/policy/sdnc/util/Serialization.java +++ b/models-interactions/model-impl/sdnc/src/main/java/org/onap/policy/sdnc/util/Serialization.java @@ -2,6 +2,7 @@ * ============LICENSE_START======================================================= * Copyright (C) 2018 Huawei. All rights reserved. * Modifications Copyright (C) 2019 Nordix Foundation. + * Modifications Copyright (C) 2019 AT&T Intellectual Property. All rights reserved. * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -23,11 +24,12 @@ import com.google.gson.Gson; import com.google.gson.GsonBuilder; public final class Serialization { - private Serialization() { - } - + public static final Gson gsonPretty = new GsonBuilder().disableHtmlEscaping() .setPrettyPrinting() .create(); + private Serialization() { + + } } |