diff options
Diffstat (limited to 'models-interactions/model-impl/aai/src')
-rw-r--r-- | models-interactions/model-impl/aai/src/main/java/org/onap/policy/aai/AaiManager.java | 8 | ||||
-rw-r--r-- | models-interactions/model-impl/aai/src/test/java/org/onap/policy/aai/AaiManagerTest.java | 8 |
2 files changed, 5 insertions, 11 deletions
diff --git a/models-interactions/model-impl/aai/src/main/java/org/onap/policy/aai/AaiManager.java b/models-interactions/model-impl/aai/src/main/java/org/onap/policy/aai/AaiManager.java index 76817dfc6..16ee887af 100644 --- a/models-interactions/model-impl/aai/src/main/java/org/onap/policy/aai/AaiManager.java +++ b/models-interactions/model-impl/aai/src/main/java/org/onap/policy/aai/AaiManager.java @@ -2,7 +2,7 @@ * ============LICENSE_START======================================================= * aai * ================================================================================ - * Copyright (C) 2017-2020 AT&T Intellectual Property. All rights reserved. + * Copyright (C) 2017-2021 AT&T Intellectual Property. All rights reserved. * Modifications Copyright (C) 2019-2020 Nordix Foundation. * Modifications Copyright (C) 2019 Samsung Electronics Co., Ltd. * ================================================================================ @@ -59,10 +59,10 @@ public final class AaiManager { private final RestManager restManager; /** custom query and other AAI resource URLs. */ - private static final String CQ_URL = "/aai/v16/query?format=resource"; - private static final String TENANT_URL = "/aai/v16/search/nodes-query?" + private static final String CQ_URL = "/aai/v21/query?format=resource"; + private static final String TENANT_URL = "/aai/v21/search/nodes-query?" + "search-node-type=vserver&filter=vserver-name:EQUALS:"; - private static final String PREFIX = "/aai/v16"; + private static final String PREFIX = "/aai/v21"; private static final String PNF_URL = PREFIX + "/network/pnfs/pnf/"; private static final String AAI_DEPTH_SUFFIX = "?depth=0"; diff --git a/models-interactions/model-impl/aai/src/test/java/org/onap/policy/aai/AaiManagerTest.java b/models-interactions/model-impl/aai/src/test/java/org/onap/policy/aai/AaiManagerTest.java index 33934d937..9b20fe92a 100644 --- a/models-interactions/model-impl/aai/src/test/java/org/onap/policy/aai/AaiManagerTest.java +++ b/models-interactions/model-impl/aai/src/test/java/org/onap/policy/aai/AaiManagerTest.java @@ -2,7 +2,7 @@ * ============LICENSE_START======================================================= * aai * ================================================================================ - * Copyright (C) 2017-2019 AT&T Intellectual Property. All rights reserved. + * Copyright (C) 2017-2021 AT&T Intellectual Property. All rights reserved. * Modifications Copyright (C) 2019-2020 Nordix Foundation. * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); @@ -94,9 +94,6 @@ public class AaiManagerTest { when(restManagerMock.put(eq(""), eq("Foo"), eq("Bar"), anyMap(), anyString(), anyString())) .thenReturn(httpResponseErr0); - when(restManagerMock.get(eq("/aai/v11/query?format=resource"), eq("Foo"), eq("Bar"), anyMap())) - .thenReturn(httpResponseErr0); - AaiCqResponse aaiCqResponseNull = aaiManager.getCustomQueryResponse("", "Foo", "Bar", vserverNameRequestId, "Foo"); assertNull(aaiCqResponseNull); @@ -105,9 +102,6 @@ public class AaiManagerTest { when(restManagerMock.put(eq("Error"), eq("Foo"), eq("Bar"), anyMap(), anyString(), anyString())) .thenReturn(httpResponseErr1); - when(restManagerMock.get(eq("Error/aai/v11/query?format=resource"), eq("Foo"), eq("Bar"), anyMap())) - .thenReturn(httpResponseErr1); - AaiCqResponse aaiCqResponseErr = aaiManager.getCustomQueryResponse("Error", "Foo", "Bar", vserverNameRequestId, "Foo"); assertNull(aaiCqResponseErr); |