X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=mod%2Fbpgenerator%2Fonap%2Fsrc%2Fmain%2Fjava%2Forg%2Fonap%2Fblueprintgenerator%2Fservice%2Fcommon%2FNodeService.java;h=50451dba6fee96ddeccaa8fa6e7b6c2ef1ba38c6;hb=72c2d38329865afa6692454b4fb90ab6f8a70638;hp=ab1b7f20dc069289b6592dcc7fb1424db947a639;hpb=87f19cde0f6532f5138822fa6f188b763a123235;p=dcaegen2%2Fplatform.git diff --git a/mod/bpgenerator/onap/src/main/java/org/onap/blueprintgenerator/service/common/NodeService.java b/mod/bpgenerator/onap/src/main/java/org/onap/blueprintgenerator/service/common/NodeService.java index ab1b7f2..50451db 100644 --- a/mod/bpgenerator/onap/src/main/java/org/onap/blueprintgenerator/service/common/NodeService.java +++ b/mod/bpgenerator/onap/src/main/java/org/onap/blueprintgenerator/service/common/NodeService.java @@ -4,6 +4,7 @@ * * org.onap.dcae * * ================================================================================ * * Copyright (c) 2020 AT&T Intellectual Property. All rights reserved. + * * Copyright (c) 2021 Nokia. 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. @@ -74,7 +75,7 @@ public class NodeService { * @return */ public Map createOnapNode( - Map> inputs, + Map> inputs, OnapComponentSpec onapComponentSpec, String override) { @@ -83,7 +84,7 @@ public class NodeService { Map onapResponse = interfacesService .createInterface(inputs, onapComponentSpec); - inputs = (Map>) onapResponse.get("inputs"); + inputs = (Map>) onapResponse.get("inputs"); Map interfaces = new TreeMap<>(); interfaces.put( @@ -110,7 +111,7 @@ public class NodeService { Map propertiesResponse = propertiesService.createOnapProperties(inputs, onapComponentSpec, override); - inputs = (Map>) propertiesResponse.get("inputs"); + inputs = (Map>) propertiesResponse.get("inputs"); onapNode.setProperties( (org.onap.blueprintgenerator.model.common.Properties) propertiesResponse .get("properties")); @@ -130,7 +131,7 @@ public class NodeService { */ public Map createDmaapNode( OnapComponentSpec onapComponentSpec, - Map> inputs, + Map> inputs, String override) { Map response = new HashMap<>(); @@ -140,7 +141,7 @@ public class NodeService { Map dmaapResponse = interfacesService.createInterface(inputs, onapComponentSpec); - inputs = (Map>) dmaapResponse.get("inputs"); + inputs = (Map>) dmaapResponse.get("inputs"); Map interfaces = new TreeMap<>(); interfaces.put( @@ -154,10 +155,10 @@ public class NodeService { Map pubRelations = new LinkedHashMap(); if (blueprintHelperService.isMessageRouterType(publishes.getType())) { pubRelations.put("type", Constants.PUBLISH_EVENTS); - pubRelations.put("target", publishes.getConfig_key() + Constants._TOPIC); + pubRelations.put("target", publishes.getConfig_key() + Constants.A_TOPIC); } else if (blueprintHelperService.isDataRouterType(publishes.getType())) { pubRelations.put("type", Constants.PUBLISH_FILES); - pubRelations.put("target", publishes.getConfig_key() + Constants._FEED); + pubRelations.put("target", publishes.getConfig_key() + Constants.A_FEED); } relationships.add(pubRelations); } @@ -168,10 +169,10 @@ public class NodeService { Map subRelations = new LinkedHashMap(); if (blueprintHelperService.isMessageRouterType(subscribes.getType())) { subRelations.put("type", Constants.SUBSCRIBE_TO_EVENTS); - subRelations.put("target", subscribes.getConfig_key() + Constants._TOPIC); + subRelations.put("target", subscribes.getConfig_key() + Constants.A_TOPIC); } else if (blueprintHelperService.isDataRouterType(subscribes.getType())) { subRelations.put("type", Constants.SUBSCRIBE_TO_FILES); - subRelations.put("target", subscribes.getConfig_key() + Constants._FEED); + subRelations.put("target", subscribes.getConfig_key() + Constants.A_FEED); } relationships.add(subRelations); } @@ -193,7 +194,7 @@ public class NodeService { Map propertiesResponse = propertiesService.createDmaapProperties(inputs, onapComponentSpec, override); - inputs = (Map>) propertiesResponse.get("inputs"); + inputs = (Map>) propertiesResponse.get("inputs"); dmaapNode.setProperties( (org.onap.blueprintgenerator.model.common.Properties) propertiesResponse .get("properties")); @@ -211,11 +212,11 @@ public class NodeService { * @return */ public Map createFeedNode( - Map> inputs, String name) { + Map> inputs, String name) { Map response = new HashMap<>(); Node feedNode = new Node(); - LinkedHashMap stringType = new LinkedHashMap(); + Map stringType = new LinkedHashMap(); stringType.put("type", "string"); feedNode.setType(Constants.FEED); @@ -242,11 +243,11 @@ public class NodeService { * @return */ public Map createTopicNode( - Map> inputs, String name) { + Map> inputs, String name) { Map response = new HashMap<>(); Node topicNode = new Node(); - LinkedHashMap stringType = new LinkedHashMap(); + Map stringType = new LinkedHashMap(); stringType.put("type", "string"); topicNode.setType(Constants.TOPIC);