diff options
author | Rich Tabedzki <richard.tabedzki@att.com> | 2017-04-05 13:15:15 +0000 |
---|---|---|
committer | Rich Tabedzki <richard.tabedzki@att.com> | 2017-04-05 13:15:52 +0000 |
commit | f2f129f56c057854517394cc5680b02418fece7d (patch) | |
tree | 43632d50bff51aa214713357b313a875e3e6d5c5 /aai-service/provider/src/main/java/org/openecomp/sdnc/sli/aai/RelationshipRequest.java | |
parent | c11f9ffaa0d9f43371f6f85a20cd1f09c6595dfb (diff) |
[SDNC-5] summary
Synchronized source code with 17.07 after cleaning up deprecated code
Change-Id: Ieabd58d25bb405ad15ad255e1cf40797e91d937f
Signed-off-by: Rich Tabedzki <richard.tabedzki@att.com>
Diffstat (limited to 'aai-service/provider/src/main/java/org/openecomp/sdnc/sli/aai/RelationshipRequest.java')
-rw-r--r-- | aai-service/provider/src/main/java/org/openecomp/sdnc/sli/aai/RelationshipRequest.java | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/aai-service/provider/src/main/java/org/openecomp/sdnc/sli/aai/RelationshipRequest.java b/aai-service/provider/src/main/java/org/openecomp/sdnc/sli/aai/RelationshipRequest.java index b964ecb..d0d0e88 100644 --- a/aai-service/provider/src/main/java/org/openecomp/sdnc/sli/aai/RelationshipRequest.java +++ b/aai-service/provider/src/main/java/org/openecomp/sdnc/sli/aai/RelationshipRequest.java @@ -30,17 +30,17 @@ import org.openecomp.sdnc.sli.aai.data.AAIDatum; import com.fasterxml.jackson.core.JsonProcessingException; import com.fasterxml.jackson.databind.ObjectMapper; -import org.openecomp.aai.inventory.v8.RelationshipList; +import org.openecomp.aai.inventory.v10.RelationshipList; public class RelationshipRequest extends AAIRequest { // tenant (1602) public static final String RELATIONSHIP_LIST_PATH = "org.openecomp.sdnc.sli.aai.path.relationship.list"; public static final String RELATIONSHIP_LIST_QUERY_PATH = "org.openecomp.sdnc.sli.aai.path.relationship.list.query"; - + private final String relationship_path; private final String relationship_query_path; - + public static final String RELATED_TO = "related-to"; public static final String RELATIONSHIP_KEY = "relationship-key"; @@ -49,23 +49,23 @@ public class RelationshipRequest extends AAIRequest { relationship_query_path = configProperties.getProperty(RELATIONSHIP_LIST_QUERY_PATH); } - + @Override public URL getRequestUrl(String method, String resourceVersion) throws UnsupportedEncodingException, MalformedURLException { AAIRequest masterRequest = (AAIRequest)requestProperties.get(MASTER_REQUEST); URL masterURL = masterRequest.getRequestUrl(method, null); - + String request_url = masterURL.toString(); request_url = request_url + relationship_path; - + if(request_url.contains("//")) { request_url = request_url.replaceAll("//", "/"); } if(requestProperties.containsKey(RELATED_TO)) { String encoded_vnf = encodeQuery(requestProperties.getProperty(RELATED_TO)); - request_url = request_url.replace("{related-to}", encoded_vnf) ; + request_url = request_url.replace("{related-to}", encoded_vnf) ; } // if(resourceVersion != null) { @@ -75,10 +75,10 @@ public class RelationshipRequest extends AAIRequest { aaiService.LOGwriteFirstTrace(method, http_req_url.toString()); aaiService.LOGwriteDateTrace("related-to", requestProperties.getProperty(RELATED_TO)); - + return http_req_url; } - + @Override public URL getRequestQueryUrl(String method) throws UnsupportedEncodingException, MalformedURLException { @@ -89,7 +89,7 @@ public class RelationshipRequest extends AAIRequest { aaiService.LOGwriteFirstTrace(method, http_req_url.toString()); aaiService.LOGwriteDateTrace("tenant_name", requestProperties.getProperty(RELATIONSHIP_KEY)); - + return http_req_url; } @@ -120,7 +120,7 @@ public class RelationshipRequest extends AAIRequest { public Class<? extends AAIDatum> getModelClass() { return RelationshipList.class; } - + public boolean isDeleteDataRequired() { return true; } |