+ private static String getAllBlueprintParametersInJson(BlueprintArtifact blueprintArtifact) {
+ ObjectNode node = JacksonUtils.getObjectMapperInstance().createObjectNode();
+ Yaml yaml = new Yaml();
+ Map<String, Object> inputsNodes = ((Map<String, Object>) ((Map<String, Object>) yaml
+ .load(blueprintArtifact.getDcaeBlueprint())).get("inputs"));
+ inputsNodes.entrySet().stream().filter(e -> !e.getKey().contains("policy_id")).forEach(elem -> {
+ Object defaultNode = ((Map<String, Object>) elem.getValue()).get("default");
+ if (defaultNode != null && defaultNode instanceof String) {
+ node.put(elem.getKey(), (String) defaultNode);
+ } else if (defaultNode != null) {
+ node.putPOJO(elem.getKey(), defaultNode);
+ } else {
+ node.put(elem.getKey(), "");
+ }
+ });
+ node.put("policy_id", "AUTO_GENERATED_POLICY_ID_AT_SUBMIT");
+ return node.toString();
+ }
+