summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
author’zhaoyh6‘ <zhaoyh6@asiainfo.com>2022-05-09 10:18:30 +0800
committer’zhaoyh6‘ <zhaoyh6@asiainfo.com>2022-05-09 10:18:38 +0800
commit7940b4339923ebadda7d2681ff0c6a3d2a1bdb5a (patch)
tree1595c21cc5796d38ff959551a36f406c0a9a0e28
parent9fef9ce8ab86b8c83b249330836793d5f4b1f1b3 (diff)
feat:Adjust ccvpn performance monitoring time and display unit.
Issue-ID: REQ-1075 Signed-off-by: ’zhaoyh6‘ <zhaoyh6@asiainfo.com> Change-Id: Id4498477450059f3f029bf3057a5294314a655d7
-rw-r--r--server/src/main/java/org/onap/usecaseui/server/conf/intent/IntentScheduleTask.java2
-rw-r--r--server/src/main/java/org/onap/usecaseui/server/service/intent/IntentApiService.java4
-rw-r--r--server/src/main/java/org/onap/usecaseui/server/service/intent/impl/IntentInstanceServiceImpl.java4
3 files changed, 5 insertions, 5 deletions
diff --git a/server/src/main/java/org/onap/usecaseui/server/conf/intent/IntentScheduleTask.java b/server/src/main/java/org/onap/usecaseui/server/conf/intent/IntentScheduleTask.java
index f84ad497..31296fd5 100644
--- a/server/src/main/java/org/onap/usecaseui/server/conf/intent/IntentScheduleTask.java
+++ b/server/src/main/java/org/onap/usecaseui/server/conf/intent/IntentScheduleTask.java
@@ -35,7 +35,7 @@ public class IntentScheduleTask {
public void getIntentInstanceCompleteness() {
intentInstanceService.getIntentInstanceProgress();
}
- @Scheduled(cron = "0/20 * * * * ?")
+ @Scheduled(cron = "0/5 * * * * ?")
public void getIntentInstanceBandwidth() throws IOException {
intentInstanceService.getIntentInstanceBandwidth();
}
diff --git a/server/src/main/java/org/onap/usecaseui/server/service/intent/IntentApiService.java b/server/src/main/java/org/onap/usecaseui/server/service/intent/IntentApiService.java
index dba140a3..8202c987 100644
--- a/server/src/main/java/org/onap/usecaseui/server/service/intent/IntentApiService.java
+++ b/server/src/main/java/org/onap/usecaseui/server/service/intent/IntentApiService.java
@@ -136,8 +136,8 @@ public interface IntentApiService {
"Authorization: Basic QUFJOkFBSQ==",
"Accept: application/json"
})
- @DELETE("/aai/v24/business/customers/customer/{globalCustomerId}/service-subscriptions/service-subscription/{serviceType}/service-instances/service-instance/{serviceInstanceId}?resource-version={resourceVersion}")
- Call<Void> deleteServiceInstance(@Path("globalCustomerId") String globalCustomerId, @Path("serviceType") String serviceType, @Path("serviceInstanceId") String serviceInstanceId, @Path("resourceVersion") String resourceVersion);
+ @DELETE("/aai/v24/business/customers/customer/{globalCustomerId}/service-subscriptions/service-subscription/{serviceType}/service-instances/service-instance/{serviceInstanceId}")
+ Call<Void> deleteServiceInstance(@Path("globalCustomerId") String globalCustomerId, @Path("serviceType") String serviceType, @Path("serviceInstanceId") String serviceInstanceId, @Query("resource-version") String resourceVersion);
@Headers({
"Authorization: Basic SW5mcmFQb3J0YWxDbGllbnQ6cGFzc3dvcmQxJA==",
diff --git a/server/src/main/java/org/onap/usecaseui/server/service/intent/impl/IntentInstanceServiceImpl.java b/server/src/main/java/org/onap/usecaseui/server/service/intent/impl/IntentInstanceServiceImpl.java
index 0a5623cb..ffe8b49b 100644
--- a/server/src/main/java/org/onap/usecaseui/server/service/intent/impl/IntentInstanceServiceImpl.java
+++ b/server/src/main/java/org/onap/usecaseui/server/service/intent/impl/IntentInstanceServiceImpl.java
@@ -205,7 +205,7 @@ public class IntentInstanceServiceImpl implements IntentInstanceService {
params.put("subscriptionServiceType", "IBN");
params.put("serviceType", "CLL");
Map<String, Object> additionalProperties = new HashMap<>();
- additionalProperties.put("enableSdnc", "false");
+ additionalProperties.put("enableSdnc", "true");
additionalProperties.put("serviceInstanceID", "cll-" + instance.getInstanceId());
List<Map<String, Object>> transportNetworks = new ArrayList<>();
Map<String, Object> transportNetwork = new HashMap<>();
@@ -404,7 +404,7 @@ public class IntentInstanceServiceImpl implements IntentInstanceService {
continue;
}
JSONObject networkPolicyInfo = networkPolicyInfoResponse.body();
- int maxBandwidth = networkPolicyInfo.getIntValue("max-bandwidth");
+ int maxBandwidth = networkPolicyInfo.getIntValue("max-bandwidth") * 1000;
InstancePerformance instancePerformance = new InstancePerformance();
instancePerformance.setMaxBandwidth(maxBandwidth);
instancePerformance.setResourceInstanceId(instance.getResourceInstanceId());