aboutsummaryrefslogtreecommitdiffstats
path: root/ms/controllerblueprints/modules/service/src/main/java
diff options
context:
space:
mode:
authorBrinda Santh <brindasanth@in.ibm.com>2018-08-27 19:53:34 -0400
committerBrinda Santh <brindasanth@in.ibm.com>2018-08-27 19:53:34 -0400
commit862ccc534007c84cccbe5caf3f3d2eef9757bc31 (patch)
tree8090eb6306fe6f5ba8d5985aeb8f063486f63bc1 /ms/controllerblueprints/modules/service/src/main/java
parent86242e35b19d81bc2d6aa377928830aed2cf3ba3 (diff)
Controller Blueprints Microservice
Remove hard coded resource sources definitions such as Input, DB, MDSAL and Default and their dependencies. Change-Id: I6e00df176415560aa5bbbbf066e5a046878f3c58 Issue-ID: CCSDK-488 Signed-off-by: Brinda Santh <brindasanth@in.ibm.com>
Diffstat (limited to 'ms/controllerblueprints/modules/service/src/main/java')
-rw-r--r--ms/controllerblueprints/modules/service/src/main/java/org/onap/ccsdk/apps/controllerblueprints/service/ApplicationRegistrationService.java8
-rw-r--r--ms/controllerblueprints/modules/service/src/main/java/org/onap/ccsdk/apps/controllerblueprints/service/validator/ResourceDictionaryValidator.java26
2 files changed, 3 insertions, 31 deletions
diff --git a/ms/controllerblueprints/modules/service/src/main/java/org/onap/ccsdk/apps/controllerblueprints/service/ApplicationRegistrationService.java b/ms/controllerblueprints/modules/service/src/main/java/org/onap/ccsdk/apps/controllerblueprints/service/ApplicationRegistrationService.java
index 074f18d0..6d0ec889 100644
--- a/ms/controllerblueprints/modules/service/src/main/java/org/onap/ccsdk/apps/controllerblueprints/service/ApplicationRegistrationService.java
+++ b/ms/controllerblueprints/modules/service/src/main/java/org/onap/ccsdk/apps/controllerblueprints/service/ApplicationRegistrationService.java
@@ -1,5 +1,6 @@
/*
* Copyright © 2017-2018 AT&T Intellectual Property.
+ * Modifications Copyright © 2018 IBM.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -16,8 +17,6 @@
package org.onap.ccsdk.apps.controllerblueprints.service;
-import org.onap.ccsdk.apps.controllerblueprints.resource.dict.ResourceDictionaryConstants;
-import org.onap.ccsdk.apps.controllerblueprints.resource.dict.data.*;
import org.springframework.stereotype.Component;
import javax.annotation.PostConstruct;
@@ -31,9 +30,6 @@ public class ApplicationRegistrationService {
}
public void registerDictionarySources(){
- SourceDeserializer.registerSource(ResourceDictionaryConstants.SOURCE_DB, SourceDb.class);
- SourceDeserializer.registerSource(ResourceDictionaryConstants.SOURCE_INPUT, SourceInput.class);
- SourceDeserializer.registerSource(ResourceDictionaryConstants.SOURCE_MDSAL, SourceMdsal.class);
- SourceDeserializer.registerSource(ResourceDictionaryConstants.SOURCE_DEFAULT,SourceDefault.class);
+
}
}
diff --git a/ms/controllerblueprints/modules/service/src/main/java/org/onap/ccsdk/apps/controllerblueprints/service/validator/ResourceDictionaryValidator.java b/ms/controllerblueprints/modules/service/src/main/java/org/onap/ccsdk/apps/controllerblueprints/service/validator/ResourceDictionaryValidator.java
index eb2448e7..ff0b4ac5 100644
--- a/ms/controllerblueprints/modules/service/src/main/java/org/onap/ccsdk/apps/controllerblueprints/service/validator/ResourceDictionaryValidator.java
+++ b/ms/controllerblueprints/modules/service/src/main/java/org/onap/ccsdk/apps/controllerblueprints/service/validator/ResourceDictionaryValidator.java
@@ -1,5 +1,6 @@
/*
* Copyright © 2017-2018 AT&T Intellectual Property.
+ * Modifications Copyright © 2018 IBM.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -18,9 +19,6 @@ package org.onap.ccsdk.apps.controllerblueprints.service.validator;
import com.google.common.base.Preconditions;
import org.apache.commons.lang3.StringUtils;
-import org.onap.ccsdk.apps.controllerblueprints.core.BluePrintException;
-import org.onap.ccsdk.apps.controllerblueprints.core.utils.JacksonUtils;
-import org.onap.ccsdk.apps.controllerblueprints.resource.dict.data.DictionaryDefinition;
import org.onap.ccsdk.apps.controllerblueprints.service.domain.ResourceDictionary;
/**
@@ -35,28 +33,6 @@ public class ResourceDictionaryValidator {
private ResourceDictionaryValidator() {}
/**
- * This is a validateResourceDictionaryDefinition
- *
- * @param definitionContent
- * @return boolean
- * @throws BluePrintException
- */
- public static boolean validateResourceDictionaryDefinition(String definitionContent)
- throws BluePrintException {
- boolean valid = true;
- if (StringUtils.isNotBlank(definitionContent)) {
- DictionaryDefinition dictionaryDefinition =
- JacksonUtils.readValue(definitionContent, DictionaryDefinition.class);
- if (dictionaryDefinition == null) {
- throw new BluePrintException(
- "Resource dictionary definition is not valid content " + definitionContent);
- }
-
- }
- return valid;
- }
-
- /**
* This is a validateResourceDictionary method
*
* @param resourceDictionary