diff options
author | hekeguang <hekeguang@chinamobile.com> | 2020-09-04 11:18:59 +0800 |
---|---|---|
committer | hekeguang <hekeguang@chinamobile.com> | 2020-09-04 11:19:09 +0800 |
commit | 9aa9f7fe73be81e67e582ccc36ab59c537f4bc9c (patch) | |
tree | c9758841603b0f473d42cfc2e01e101094e985bf | |
parent | 1315d0b891fb9d46b8ce789ef5d7b0f0c724923d (diff) |
Add code related to Slicing
Issue-ID: USECASEUI-444
Change-Id: Icf9619ce99b87225bdc029e1e51b50218fa644d9
Signed-off-by: hekeguang <hekeguang@chinamobile.com>
8 files changed, 322 insertions, 194 deletions
diff --git a/server/src/main/java/org/onap/usecaseui/server/bean/nsmf/task/BusinessDemandInfo.java b/server/src/main/java/org/onap/usecaseui/server/bean/nsmf/task/BusinessDemandInfo.java index 9aa59f23..10729106 100644 --- a/server/src/main/java/org/onap/usecaseui/server/bean/nsmf/task/BusinessDemandInfo.java +++ b/server/src/main/java/org/onap/usecaseui/server/bean/nsmf/task/BusinessDemandInfo.java @@ -62,4 +62,41 @@ public class BusinessDemandInfo { @JsonProperty("max_number_of_ues") String maxNumberOfUEs; + + @JsonProperty("serviceProfile_Availability") + String serviceProfileAvailability; + + @JsonProperty("serviceProfile_PLMNIdList") + String serviceProfilePLMNIdList; + + @JsonProperty("serviceProfile_Reliability") + String serviceProfileReliability; + + @JsonProperty("serviceProfile_DLThptPerSlice") + String serviceProfileDLThptPerSlice; + + @JsonProperty("serviceProfile_DLThptPerUE") + String serviceProfileDLThptPerUE; + + @JsonProperty("serviceProfile_ULThptPerSlice") + String serviceProfileULThptPerSlice; + + @JsonProperty("serviceProfile_ULThptPerUE") + String serviceProfileULThptPerUE; + + @JsonProperty("serviceProfile_MaxPktSize") + String serviceProfileMaxPktSize; + + @JsonProperty("serviceProfile_MaxNumberofConns") + String serviceProfileMaxNumberofConns; + + @JsonProperty("serviceProfile_TermDensity") + String serviceProfileTermDensity; + + @JsonProperty("serviceProfile_Jitter") + String serviceProfileJitter; + + @JsonProperty("serviceProfile_SurvivalTime") + String serviceProfileSurvivalTime; + } diff --git a/server/src/main/java/org/onap/usecaseui/server/bean/nsmf/task/NsiAndSubNssiInfo.java b/server/src/main/java/org/onap/usecaseui/server/bean/nsmf/task/NsiAndSubNssiInfo.java index 5de7709b..f77772a8 100644 --- a/server/src/main/java/org/onap/usecaseui/server/bean/nsmf/task/NsiAndSubNssiInfo.java +++ b/server/src/main/java/org/onap/usecaseui/server/bean/nsmf/task/NsiAndSubNssiInfo.java @@ -48,6 +48,75 @@ public class NsiAndSubNssiInfo { @JsonProperty("an_script_name") String anScriptName; + @JsonProperty("an_enableNSSISelection") + String anEnableNSSISelection; + + @JsonProperty("sliceProfile_AN_sNSSAI") + String sliceProfile_AN_sNSSAI; + + @JsonProperty("sliceProfile_AN_pLMNIdList") + String sliceProfile_AN_pLMNIdList; + + @JsonProperty("sliceProfile_AN_maxNumberofUEs") + String sliceProfile_AN_maxNumberofUEs; + + @JsonProperty("sliceProfile_AN_maxNumberofPDUSession") + String sliceProfile_AN_maxNumberofPDUSession; + + @JsonProperty("sliceProfile_AN_expDataRateDL") + String sliceProfile_AN_expDataRateDL; + + @JsonProperty("sliceProfile_AN_expDataRateUL") + String sliceProfile_AN_expDataRateUL; + + @JsonProperty("sliceProfile_AN_areaTrafficCapDL") + String sliceProfile_AN_areaTrafficCapDL; + + @JsonProperty("sliceProfile_AN_areaTrafficCapUL") + String sliceProfile_AN_areaTrafficCapUL; + + @JsonProperty("sliceProfile_AN_overallUserDensity") + String sliceProfile_AN_overallUserDensity; + + @JsonProperty("sliceProfile_AN_activityFactor") + String sliceProfile_AN_activityFactor; + + @JsonProperty("sliceProfile_AN_uEMobilityLevel") + String sliceProfile_AN_uEMobilityLevel; + + @JsonProperty("sliceProfile_AN_resourceSharingLevel") + String sliceProfile_AN_resourceSharingLevel; + + @JsonProperty("sliceProfile_AN_sST") + String sliceProfile_AN_sST; + + @JsonProperty("sliceProfile_AN_cSAvailabilityTarget") + String sliceProfile_AN_cSAvailabilityTarget; + + @JsonProperty("sliceProfile_AN_cSReliabilityMeanTime") + String sliceProfile_AN_cSReliabilityMeanTime; + + @JsonProperty("sliceProfile_AN_expDataRate") + String sliceProfile_AN_expDataRate; + + @JsonProperty("sliceProfile_AN_msgSizeByte") + String sliceProfile_AN_msgSizeByte; + + @JsonProperty("sliceProfile_AN_transferIntervalTarget") + String sliceProfile_AN_transferIntervalTarget; + + @JsonProperty("sliceProfile_AN_survivalTime") + String sliceProfile_AN_survivalTime; + + @JsonProperty("sliceProfile_AN_ipAddress") + String sliceProfile_AN_ipAddress; + + @JsonProperty("sliceProfile_AN_logicInterfaceId") + String sliceProfile_AN_logicInterfaceId; + + @JsonProperty("sliceProfile_AN_nextHopInfo") + String sliceProfile_AN_nextHopInfo; + @JsonProperty("tn_suggest_nssi_id") String tnSuggestNssiId; @@ -63,6 +132,21 @@ public class NsiAndSubNssiInfo { @JsonProperty("tn_script_name") String tnScriptName; + @JsonProperty("sliceProfile_TN_jitte") + String sliceProfile_TN_jitte; + + @JsonProperty("sliceProfile_TN_pLMNIdList") + String sliceProfile_TN_pLMNIdList; + + @JsonProperty("sliceProfile_TN_sNSSAI") + String sliceProfile_TN_sNSSAI; + + @JsonProperty("sliceProfile_TN_sST") + String sliceProfile_TN_sST; + + @JsonProperty("tn_enableNSSISelection") + String tnEnableNSSISelection; + @JsonProperty("cn_suggest_nssi_id") String cnSuggestNssiId; @@ -101,4 +185,50 @@ public class NsiAndSubNssiInfo { @JsonProperty("cn_script_name") String cnScriptName; + + @JsonProperty("cn_enableNSSISelection") + String cnEnableNSSISelection; + + @JsonProperty("sliceProfile_CN_pLMNIdList") + String sliceProfile_CN_pLMNIdList; + + @JsonProperty("sliceProfile_CN_maxNumberofPDUSession") + String sliceProfile_CN_maxNumberofPDUSession; + + @JsonProperty("sliceProfile_CN_overallUserDensity") + String sliceProfile_CN_overallUserDensity; + + @JsonProperty("sliceProfile_CN_coverageAreaTAList") + String sliceProfile_CN_coverageAreaTAList; + + @JsonProperty("sliceProfile_CN_sST") + String sliceProfile_CN_sST; + + @JsonProperty("sliceProfile_CN_cSAvailabilityTarget") + String sliceProfile_CN_cSAvailabilityTarget; + + @JsonProperty("sliceProfile_CN_cSReliabilityMeanTime") + String sliceProfile_CN_cSReliabilityMeanTime; + + @JsonProperty("sliceProfile_CN_expDataRate") + String sliceProfile_CN_expDataRate; + + @JsonProperty("sliceProfile_CN_msgSizeByte") + String sliceProfile_CN_msgSizeByte; + + @JsonProperty("sliceProfile_CN_logicInterfaceId") + String sliceProfile_CN_logicInterfaceId; + + @JsonProperty("sliceProfile_CN_transferIntervalTarget") + String sliceProfile_CN_transferIntervalTarget; + + @JsonProperty("sliceProfile_CN_survivalTime") + String sliceProfile_CN_survivalTime; + + @JsonProperty("sliceProfile_CN_ipAddress") + String sliceProfile_CN_ipAddress; + + @JsonProperty("sliceProfile_CN_nextHopInfo") + String sliceProfile_CN_nextHopInfo; + } diff --git a/server/src/main/java/org/onap/usecaseui/server/bean/nsmf/task/SlicingTaskCreationProgress.java b/server/src/main/java/org/onap/usecaseui/server/bean/nsmf/task/SlicingTaskCreationProgress.java index c704a085..694a02ac 100644 --- a/server/src/main/java/org/onap/usecaseui/server/bean/nsmf/task/SlicingTaskCreationProgress.java +++ b/server/src/main/java/org/onap/usecaseui/server/bean/nsmf/task/SlicingTaskCreationProgress.java @@ -28,16 +28,25 @@ public class SlicingTaskCreationProgress { @JsonProperty("an_status") private String anStatus; + @JsonProperty("an_statusDescription") + private String anStatusDescription; + @JsonProperty("tn_progress") private String tnProgress; @JsonProperty("tn_status") private String tnStatus; + @JsonProperty("tn_statusDescription") + private String tnStatusDescription; + @JsonProperty("cn_progress") private String cnProgress; @JsonProperty("cn_status") private String cnStatus; + @JsonProperty("cn_statusDescription") + private String cnStatusDescription; + } diff --git a/server/src/main/java/org/onap/usecaseui/server/service/nsmf/impl/ResourceMgtServiceConvert.java b/server/src/main/java/org/onap/usecaseui/server/service/nsmf/impl/ResourceMgtServiceConvert.java index 445445c1..9a8f391a 100644 --- a/server/src/main/java/org/onap/usecaseui/server/service/nsmf/impl/ResourceMgtServiceConvert.java +++ b/server/src/main/java/org/onap/usecaseui/server/service/nsmf/impl/ResourceMgtServiceConvert.java @@ -263,12 +263,25 @@ public class ResourceMgtServiceConvert { String useInterval = generalConvert.getUseInterval(businessId); businessDemandInfo.setUseInterval(useInterval); - BeanUtils.copyProperties(businessDemandInfo, aaiServiceProfiles); + convertServiceProfilesToBusinessDemandInfo(businessDemandInfo, aaiServiceProfiles); List<String> areaInfoList = generalConvert.getAreaTaList(aaiServiceProfiles.getCoverageAreaTAList()); businessDemandInfo.setCoverageAreaTaList(areaInfoList); slicingBusinessDetails.setBusinessDemandInfo(businessDemandInfo); } + void convertServiceProfilesToBusinessDemandInfo(BusinessDemandInfo businessDemandInfo, AAIServiceProfiles aaiServiceProfiles) + throws InvocationTargetException, IllegalAccessException { + BeanUtils.copyProperties(businessDemandInfo, aaiServiceProfiles); + businessDemandInfo.setServiceProfileAvailability(String.valueOf(aaiServiceProfiles.getAvailability())); + businessDemandInfo.setServiceProfileDLThptPerSlice(String.valueOf(aaiServiceProfiles.getDLThptPerSlice())); + businessDemandInfo.setServiceProfileDLThptPerUE(String.valueOf(aaiServiceProfiles.getDLThptPerUE())); + businessDemandInfo.setServiceProfileULThptPerSlice(String.valueOf(aaiServiceProfiles.getULThptPerSlice())); + businessDemandInfo.setServiceProfileULThptPerUE(String.valueOf(aaiServiceProfiles.getULThptPerUE())); + businessDemandInfo.setServiceProfileMaxPktSize(String.valueOf(aaiServiceProfiles.getMaxPktSize())); + businessDemandInfo.setServiceProfileMaxNumberofConns(String.valueOf(aaiServiceProfiles.getMaxNumberofConns())); + businessDemandInfo.setServiceProfileTermDensity(String.valueOf(aaiServiceProfiles.getTermDensity())); + } + void convertHostedNsiList(NsiServiceInstanceList nsiServiceInstanceList, AAIServiceRsp aAIServiceRsp, int pageNo, int pageSize) throws InvocationTargetException, IllegalAccessException { diff --git a/server/src/main/java/org/onap/usecaseui/server/service/nsmf/impl/TaskMgtServiceConvert.java b/server/src/main/java/org/onap/usecaseui/server/service/nsmf/impl/TaskMgtServiceConvert.java index 95189c0b..86bc3524 100644 --- a/server/src/main/java/org/onap/usecaseui/server/service/nsmf/impl/TaskMgtServiceConvert.java +++ b/server/src/main/java/org/onap/usecaseui/server/service/nsmf/impl/TaskMgtServiceConvert.java @@ -118,7 +118,6 @@ public class TaskMgtServiceConvert { targetBusinessDemandInfo.setExpDataRateUL(paramsObject.getString("ServiceProfile.expDataRateUL")); targetBusinessDemandInfo.setUeMobilityLevel(paramsObject.getString("ServiceProfile.uEMobilityLevel")); targetBusinessDemandInfo.setLatency(paramsObject.getString("ServiceProfile.latency")); - String useInterval = generalConvert.getUseInterval(paramsObject.getString("ServiceId")); targetBusinessDemandInfo.setUseInterval(useInterval); @@ -129,6 +128,18 @@ public class TaskMgtServiceConvert { targetBusinessDemandInfo.setAreaTrafficCapDL(paramsObject.getString("ServiceProfile.areaTrafficCapDL")); targetBusinessDemandInfo.setAreaTrafficCapUL(paramsObject.getString("ServiceProfile.areaTrafficCapUL")); targetBusinessDemandInfo.setMaxNumberOfUEs(paramsObject.getString("ServiceProfile.maxNumberofUEs")); + targetBusinessDemandInfo.setServiceProfileAvailability(paramsObject.getString("ServiceProfile.availability")); + targetBusinessDemandInfo.setServiceProfilePLMNIdList(paramsObject.getString("ServiceProfile.pLMNIdList")); + targetBusinessDemandInfo.setServiceProfileReliability(paramsObject.getString("ServiceProfile.reliability")); + targetBusinessDemandInfo.setServiceProfileDLThptPerSlice(paramsObject.getString("ServiceProfile.dLThptPerSlice")); + targetBusinessDemandInfo.setServiceProfileDLThptPerUE(paramsObject.getString("ServiceProfile.dLThptPerUE")); + targetBusinessDemandInfo.setServiceProfileULThptPerSlice(paramsObject.getString("ServiceProfile.uLThptPerSlice")); + targetBusinessDemandInfo.setServiceProfileULThptPerUE(paramsObject.getString("ServiceProfile.uLThptPerUE")); + targetBusinessDemandInfo.setServiceProfileMaxPktSize(paramsObject.getString("ServiceProfile.maxPktSize")); + targetBusinessDemandInfo.setServiceProfileMaxNumberofConns(paramsObject.getString("ServiceProfile.maxNumberofConns")); + targetBusinessDemandInfo.setServiceProfileTermDensity(paramsObject.getString("ServiceProfile.termDensity")); + targetBusinessDemandInfo.setServiceProfileJitter(paramsObject.getString("ServiceProfile.jitter")); + targetBusinessDemandInfo.setServiceProfileSurvivalTime(paramsObject.getString("ServiceProfile.survivalTime")); } void convertNstInfo(NstInfo nstInfo, JSONObject paramsObject) { @@ -147,12 +158,39 @@ public class TaskMgtServiceConvert { nsiAndSubNssiInfo.setAnCoverageAreaTaList(generalConvert.getAreaTaList(anCoverageAreaTA)); nsiAndSubNssiInfo.setAnLatency(paramsObject.getString("SliceProfile.AN.latency")); nsiAndSubNssiInfo.setAnScriptName(paramsObject.getString("AN.ScriptName")); + nsiAndSubNssiInfo.setAnEnableNSSISelection(paramsObject.getString("AN.enableNSSISelection")); + nsiAndSubNssiInfo.setSliceProfile_AN_sNSSAI(paramsObject.getString("SliceProfile.AN.sNSSAI")); + nsiAndSubNssiInfo.setSliceProfile_AN_maxNumberofUEs(paramsObject.getString("SliceProfile.AN.maxNumberofUEs")); + nsiAndSubNssiInfo.setSliceProfile_AN_maxNumberofPDUSession(paramsObject.getString("SliceProfile.AN.maxNumberofPDUSession")); + nsiAndSubNssiInfo.setSliceProfile_AN_expDataRateDL(paramsObject.getString("SliceProfile.AN.expDataRateDL")); + nsiAndSubNssiInfo.setSliceProfile_AN_expDataRateUL(paramsObject.getString("SliceProfile.AN.expDataRateUL")); + nsiAndSubNssiInfo.setSliceProfile_AN_areaTrafficCapDL(paramsObject.getString("SliceProfile.AN.areaTrafficCapDL")); + nsiAndSubNssiInfo.setSliceProfile_AN_areaTrafficCapUL(paramsObject.getString("SliceProfile.AN.areaTrafficCapUL")); + nsiAndSubNssiInfo.setSliceProfile_AN_overallUserDensity(paramsObject.getString("SliceProfile.AN.overallUserDensity")); + nsiAndSubNssiInfo.setSliceProfile_AN_activityFactor(paramsObject.getString("SliceProfile.AN.activityFactor")); + nsiAndSubNssiInfo.setSliceProfile_AN_uEMobilityLevel(paramsObject.getString("SliceProfile.AN.uEMobilityLevel")); + nsiAndSubNssiInfo.setSliceProfile_AN_resourceSharingLevel(paramsObject.getString("SliceProfile.AN.resourceSharingLevel")); + nsiAndSubNssiInfo.setSliceProfile_AN_sST(paramsObject.getString("SliceProfile.AN.sST")); + nsiAndSubNssiInfo.setSliceProfile_AN_cSAvailabilityTarget(paramsObject.getString("SliceProfile.AN.cSAvailabilityTarget")); + nsiAndSubNssiInfo.setSliceProfile_AN_cSReliabilityMeanTime(paramsObject.getString("SliceProfile.AN.cSReliabilityMeanTime")); + nsiAndSubNssiInfo.setSliceProfile_AN_expDataRate(paramsObject.getString("SliceProfile.AN.expDataRate")); + nsiAndSubNssiInfo.setSliceProfile_AN_msgSizeByte(paramsObject.getString("SliceProfile.AN.msgSizeByte")); + nsiAndSubNssiInfo.setSliceProfile_AN_transferIntervalTarget(paramsObject.getString("SliceProfile.AN.transferIntervalTarget")); + nsiAndSubNssiInfo.setSliceProfile_AN_survivalTime(paramsObject.getString("SliceProfile.AN.survivalTime")); + nsiAndSubNssiInfo.setSliceProfile_AN_ipAddress(paramsObject.getString("SliceProfile.AN.ipAddress")); + nsiAndSubNssiInfo.setSliceProfile_AN_logicInterfaceId(paramsObject.getString("SliceProfile.AN.logicInterfaceId")); + nsiAndSubNssiInfo.setSliceProfile_AN_nextHopInfo(paramsObject.getString("SliceProfile.AN.nextHopInfo")); nsiAndSubNssiInfo.setTnSuggestNssiId(paramsObject.getString("TN.suggestNSSIId")); nsiAndSubNssiInfo.setTnSuggestNssiName(paramsObject.getString("TN.suggestNSSIName")); nsiAndSubNssiInfo.setTnLatency(paramsObject.getString("SliceProfile.TN.latency")); - nsiAndSubNssiInfo.setTnBandwidth(paramsObject.getString("SliceProfile.TN.bandwidth")); + nsiAndSubNssiInfo.setTnBandwidth(paramsObject.getString("SliceProfile.TN.maxBandwidth")); nsiAndSubNssiInfo.setTnScriptName(paramsObject.getString("TN.ScriptName")); + nsiAndSubNssiInfo.setTnEnableNSSISelection(paramsObject.getString("TN.enableNSSISelection")); + nsiAndSubNssiInfo.setSliceProfile_TN_jitte(paramsObject.getString("SliceProfile.TN.jitte")); + nsiAndSubNssiInfo.setSliceProfile_TN_pLMNIdList(paramsObject.getString("SliceProfile.TN.pLMNIdList")); + nsiAndSubNssiInfo.setSliceProfile_TN_sNSSAI(paramsObject.getString("SliceProfile.TN.sNSSAI")); + nsiAndSubNssiInfo.setSliceProfile_TN_sST(paramsObject.getString("SliceProfile.TN.sST")); nsiAndSubNssiInfo.setCnSuggestNssiId(paramsObject.getString("CN.suggestNSSIId")); nsiAndSubNssiInfo.setCnSuggestNssiName(paramsObject.getString("CN.suggestNSSIName")); @@ -167,6 +205,21 @@ public class TaskMgtServiceConvert { nsiAndSubNssiInfo.setCnAreaTrafficCapDl(paramsObject.getString("SliceProfile.CN.areaTrafficCapDL")); nsiAndSubNssiInfo.setCnAreaTrafficCapUl(paramsObject.getString("SliceProfile.CN.areaTrafficCapUL")); nsiAndSubNssiInfo.setCnScriptName(paramsObject.getString("CN.ScriptName")); + nsiAndSubNssiInfo.setCnEnableNSSISelection(paramsObject.getString("CN.enableNSSISelection")); + nsiAndSubNssiInfo.setSliceProfile_CN_maxNumberofPDUSession(paramsObject.getString("SliceProfile.CN.maxNumberofPDUSession")); + nsiAndSubNssiInfo.setSliceProfile_CN_overallUserDensity(paramsObject.getString("SliceProfile.CN.overallUserDensity")); + nsiAndSubNssiInfo.setSliceProfile_CN_coverageAreaTAList(paramsObject.getString("SliceProfile.CN.coverageAreaTAList")); + nsiAndSubNssiInfo.setSliceProfile_CN_sST(paramsObject.getString("SliceProfile.CN.sST")); + nsiAndSubNssiInfo.setSliceProfile_CN_cSAvailabilityTarget(paramsObject.getString("SliceProfile.CN.cSAvailabilityTarget")); + nsiAndSubNssiInfo.setSliceProfile_CN_cSReliabilityMeanTime(paramsObject.getString("SliceProfile.CN.cSReliabilityMeanTime")); + nsiAndSubNssiInfo.setSliceProfile_CN_expDataRate(paramsObject.getString("SliceProfile.CN.expDataRate")); + nsiAndSubNssiInfo.setSliceProfile_CN_msgSizeByte(paramsObject.getString("SliceProfile.CN.msgSizeByte")); + nsiAndSubNssiInfo.setSliceProfile_CN_transferIntervalTarget(paramsObject.getString("SliceProfile.CN.transferIntervalTarget")); + nsiAndSubNssiInfo.setSliceProfile_CN_survivalTime(paramsObject.getString("SliceProfile.CN.survivalTime")); + nsiAndSubNssiInfo.setSliceProfile_CN_ipAddress(paramsObject.getString("SliceProfile.CN.ipAddress")); + nsiAndSubNssiInfo.setSliceProfile_CN_logicInterfaceId(paramsObject.getString("SliceProfile.CN.logicInterfaceId")); + nsiAndSubNssiInfo.setSliceProfile_CN_nextHopInfo(paramsObject.getString("SliceProfile.CN.nextHopInfo")); + } void convertTaskAuditToSoTask(SOTask targetSoTaskInfo, SlicingTaskAuditInfo sourceSlicingTaskAuditInfo) { @@ -187,12 +240,39 @@ public class TaskMgtServiceConvert { (sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getAnCoverageAreaTaList(), '|'); jsonObject.put("SliceProfile.AN.coverageAreaTAList", aNCoverageAreaTAList); jsonObject.put("AN.ScriptName", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getAnScriptName()); + jsonObject.put("AN.enableNSSISelection", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getAnEnableNSSISelection()); + jsonObject.put("SliceProfile.AN.sNSSAI", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_sNSSAI()); + jsonObject.put("SliceProfile.AN.maxNumberofUEs", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_maxNumberofUEs()); + jsonObject.put("SliceProfile.AN.maxNumberofPDUSession", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_maxNumberofPDUSession()); + jsonObject.put("SliceProfile.AN.expDataRateDL", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_expDataRateDL()); + jsonObject.put("SliceProfile.AN.expDataRateUL", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_expDataRateUL()); + jsonObject.put("SliceProfile.AN.areaTrafficCapDL", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_areaTrafficCapDL()); + jsonObject.put("SliceProfile.AN.areaTrafficCapUL", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_areaTrafficCapUL()); + jsonObject.put("SliceProfile.AN.overallUserDensity", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_overallUserDensity()); + jsonObject.put("SliceProfile.AN.activityFactor", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_activityFactor()); + jsonObject.put("SliceProfile.AN.uEMobilityLevel", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_uEMobilityLevel()); + jsonObject.put("SliceProfile.AN.resourceSharingLevel", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_resourceSharingLevel()); + jsonObject.put("SliceProfile.AN.sST", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_sST()); + jsonObject.put("SliceProfile.AN.cSAvailabilityTarget", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_cSAvailabilityTarget()); + jsonObject.put("SliceProfile.AN.cSReliabilityMeanTime", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_cSReliabilityMeanTime()); + jsonObject.put("SliceProfile.AN.expDataRate", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_expDataRate()); + jsonObject.put("SliceProfile.AN.msgSizeByte", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_msgSizeByte()); + jsonObject.put("SliceProfile.AN.transferIntervalTarget", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_transferIntervalTarget()); + jsonObject.put("SliceProfile.AN.survivalTime", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_survivalTime()); + jsonObject.put("SliceProfile.AN.ipAddress", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_ipAddress()); + jsonObject.put("SliceProfile.AN.logicInterfaceId", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_logicInterfaceId()); + jsonObject.put("SliceProfile.AN.nextHopInfo", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_AN_nextHopInfo()); jsonObject.put("TN.suggestNSSIId", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getTnSuggestNssiId()); jsonObject.put("TN.suggestNSSIName", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getTnSuggestNssiName()); - jsonObject.put("SliceProfile.TN.bandwidth", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getTnBandwidth()); + jsonObject.put("SliceProfile.TN.maxBandwidth", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getTnBandwidth()); jsonObject.put("SliceProfile.TN.latency", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getTnLatency()); jsonObject.put("TN.ScriptName", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getTnScriptName()); + jsonObject.put("TN.enableNSSISelection", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getTnEnableNSSISelection()); + jsonObject.put("SliceProfile.TN.jitte", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_TN_jitte()); + jsonObject.put("SliceProfile.TN.pLMNIdList", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_TN_pLMNIdList()); + jsonObject.put("SliceProfile.TN.sNSSAI", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_TN_sNSSAI()); + jsonObject.put("SliceProfile.TN.sST", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_TN_sST()); jsonObject.put("CN.suggestNSSIId", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getCnSuggestNssiId()); jsonObject.put("CN.suggestNSSIName", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getCnSuggestNssiName()); @@ -216,6 +296,21 @@ public class TaskMgtServiceConvert { jsonObject.put("SliceProfile.CN.areaTrafficCapUL", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getCnAreaTrafficCapUl()); jsonObject.put("CN.ScriptName", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getCnScriptName()); + jsonObject.put("CN.enableNSSISelection", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getCnEnableNSSISelection()); + jsonObject.put("SliceProfile.CN.maxNumberofPDUSession", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_CN_maxNumberofPDUSession()); + jsonObject.put("SliceProfile.CN.overallUserDensity", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_CN_overallUserDensity()); + jsonObject.put("SliceProfile.CN.coverageAreaTAList", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_CN_coverageAreaTAList()); + jsonObject.put("SliceProfile.CN.sST", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_CN_sST()); + jsonObject.put("SliceProfile.CN.cSAvailabilityTarget", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_CN_cSAvailabilityTarget()); + jsonObject.put("SliceProfile.CN.cSReliabilityMeanTime", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_CN_cSReliabilityMeanTime()); + jsonObject.put("SliceProfile.CN.expDataRate", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_CN_expDataRate()); + jsonObject.put("SliceProfile.CN.msgSizeByte", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_CN_msgSizeByte()); + jsonObject.put("SliceProfile.CN.transferIntervalTarget", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_CN_transferIntervalTarget()); + jsonObject.put("SliceProfile.CN.survivalTime", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_CN_survivalTime()); + jsonObject.put("SliceProfile.CN.ipAddress", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_CN_ipAddress()); + jsonObject.put("SliceProfile.CN.logicInterfaceId", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_CN_logicInterfaceId()); + jsonObject.put("SliceProfile.CN.nextHopInfo", sourceSlicingTaskAuditInfo.getNsiAndSubNssiInfo().getSliceProfile_CN_nextHopInfo()); + String param = jsonObject.toJSONString(); targetSoTaskInfo.setParams(param); } @@ -241,7 +336,7 @@ public class TaskMgtServiceConvert { } BusinessDemandInfo businessDemandInfo = new BusinessDemandInfo(); - convertCreationBusinessDemandInfo(businessDemandInfo, paramsObject); + convertBusinessDemandInfo(businessDemandInfo, paramsObject); slicingTaskCreationInfo.setBusinessDemandInfo(businessDemandInfo); NstInfo nstInfo = new NstInfo(); @@ -293,5 +388,14 @@ public class TaskMgtServiceConvert { String cnStatus = paramsObject.getString("CN.status"); slicingTaskCreationProgress.setCnStatus(cnStatus); + + String anStatusDescription = paramsObject.getString("AN.statusDescription"); + slicingTaskCreationProgress.setAnStatusDescription(anStatusDescription); + + String tnStatusDescription = paramsObject.getString("TN.statusDescription"); + slicingTaskCreationProgress.setTnStatusDescription(tnStatusDescription); + + String cnStatusDescription = paramsObject.getString("CN.statusDescription"); + slicingTaskCreationProgress.setCnStatusDescription(cnStatusDescription); } } diff --git a/server/src/main/java/org/onap/usecaseui/server/service/slicingdomain/aai/AAISliceService.java b/server/src/main/java/org/onap/usecaseui/server/service/slicingdomain/aai/AAISliceService.java index f150cac6..6efcfdc9 100644 --- a/server/src/main/java/org/onap/usecaseui/server/service/slicingdomain/aai/AAISliceService.java +++ b/server/src/main/java/org/onap/usecaseui/server/service/slicingdomain/aai/AAISliceService.java @@ -33,7 +33,7 @@ public interface AAISliceService { "Authorization: Basic QUFJOkFBSQ==", "Accept: application/json" }) - @GET("/api/aai-business/v13/customers/customer/{global-customer-id}/service-subscriptions/service-subscription/{service-type}/service-instances?service-role=e2eslice-service") + @GET("/api/aai-business/v13/customers/customer/{global-customer-id}/service-subscriptions/service-subscription/{service-type}/service-instances?service-role=service-profile") Call<JSONObject> listService(@Path("global-customer-id") String globalCustomerId,@Path("service-type") String serviceType); @Headers({ @@ -42,7 +42,7 @@ public interface AAISliceService { "Authorization: Basic QUFJOkFBSQ==", "Accept: application/json" }) - @GET("/api/aai-business/v13/customers/customer/{global-customer-id}/service-subscriptions/service-subscription/{service-type}/service-instances?service-role=e2eslice-service") + @GET("/api/aai-business/v13/customers/customer/{global-customer-id}/service-subscriptions/service-subscription/{service-type}/service-instances?service-role=service-profile") Call<JSONObject> listServiceByStatus(@Path("global-customer-id") String globalCustomerId,@Path("service-type") String serviceType,@Query("orchestration-status") String orchestrationStatus); @Headers({ diff --git a/server/src/main/java/org/onap/usecaseui/server/service/slicingdomain/aai/bean/AAIServiceProfiles.java b/server/src/main/java/org/onap/usecaseui/server/service/slicingdomain/aai/bean/AAIServiceProfiles.java index 5702c141..4a04fdc2 100644 --- a/server/src/main/java/org/onap/usecaseui/server/service/slicingdomain/aai/bean/AAIServiceProfiles.java +++ b/server/src/main/java/org/onap/usecaseui/server/service/slicingdomain/aai/bean/AAIServiceProfiles.java @@ -14,7 +14,11 @@ package org.onap.usecaseui.server.service.slicingdomain.aai.bean; import com.fasterxml.jackson.annotation.JsonIgnoreProperties; import com.fasterxml.jackson.annotation.JsonProperty; +import lombok.Getter; +import lombok.Setter; +@Getter +@Setter @JsonIgnoreProperties(ignoreUnknown = true) public class AAIServiceProfiles { @@ -36,18 +40,6 @@ public class AAIServiceProfiles { @JsonProperty("resource-sharing-level") private String resourceSharingLevel; - @JsonProperty("exp-data-rate-UL") - private int expDataRateUL; - - @JsonProperty("exp-data-rate-DL") - private int expDataRateDL; - - @JsonProperty("area-traffic-cap-UL") - private int areaTrafficCapUL; - - @JsonProperty("area-traffic-cap-DL") - private int areaTrafficCapDL; - @JsonProperty("activity-factor") private int activityFactor; @@ -57,175 +49,35 @@ public class AAIServiceProfiles { @JsonProperty("survival-time") private int survivalTime; - @JsonProperty("cs-availability") - private int csAvailability; - @JsonProperty("reliability") private int reliability; - @JsonProperty("exp-data-rate") - private int expDataRate; - - @JsonProperty("traffic-density") - private int trafficDensity; - - @JsonProperty("conn-density") - private int connDensity; - - @JsonProperty("resource-version") - private String resourceVersion; - - public String getProfileId() { - return profileId; - } - - public void setProfileId(String profileId) { - this.profileId = profileId; - } - - public int getLatency() { - return latency; - } - - public void setLatency(int latency) { - this.latency = latency; - } - - public int getMaxNumberOfUEs() { - return maxNumberOfUEs; - } - - public void setMaxNumberOfUEs(int maxNumberOfUEs) { - this.maxNumberOfUEs = maxNumberOfUEs; - } - - public String getCoverageAreaTAList() { - return coverageAreaTAList; - } - - public void setCoverageAreaTAList(String coverageAreaTAList) { - this.coverageAreaTAList = coverageAreaTAList; - } - - public String getUeMobilityLevel() { - return ueMobilityLevel; - } - - public void setUeMobilityLevel(String ueMobilityLevel) { - this.ueMobilityLevel = ueMobilityLevel; - } - - public String getResourceSharingLevel() { - return resourceSharingLevel; - } + @JsonProperty("availability") + private float availability; - public void setResourceSharingLevel(String resourceSharingLevel) { - this.resourceSharingLevel = resourceSharingLevel; - } + @JsonProperty("dLThptPerSlice") + private int dLThptPerSlice; - public int getExpDataRateUL() { - return expDataRateUL; - } + @JsonProperty("dLThptPerUE") + private int dLThptPerUE; - public void setExpDataRateUL(int expDataRateUL) { - this.expDataRateUL = expDataRateUL; - } + @JsonProperty("uLThptPerSlice") + private int uLThptPerSlice; - public int getExpDataRateDL() { - return expDataRateDL; - } + @JsonProperty("uLThptPerUE") + private int uLThptPerUE; - public void setExpDataRateDL(int expDataRateDL) { - this.expDataRateDL = expDataRateDL; - } + @JsonProperty("maxPktSize") + private int maxPktSize; - public int getAreaTrafficCapUL() { - return areaTrafficCapUL; - } + @JsonProperty("maxNumberofConns") + private int maxNumberofConns; - public void setAreaTrafficCapUL(int areaTrafficCapUL) { - this.areaTrafficCapUL = areaTrafficCapUL; - } + @JsonProperty("termDensity") + private int termDensity; - public int getAreaTrafficCapDL() { - return areaTrafficCapDL; - } - - public void setAreaTrafficCapDL(int areaTrafficCapDL) { - this.areaTrafficCapDL = areaTrafficCapDL; - } - - public int getActivityFactor() { - return activityFactor; - } - - public void setActivityFactor(int activityFactor) { - this.activityFactor = activityFactor; - } - - public int getJitter() { - return jitter; - } - - public void setJitter(int jitter) { - this.jitter = jitter; - } - - public int getSurvivalTime() { - return survivalTime; - } - - public void setSurvivalTime(int survivalTime) { - this.survivalTime = survivalTime; - } - - public int getCsAvailability() { - return csAvailability; - } - - public void setCsAvailability(int csAvailability) { - this.csAvailability = csAvailability; - } - - public int getReliability() { - return reliability; - } - - public void setReliability(int reliability) { - this.reliability = reliability; - } - - public int getExpDataRate() { - return expDataRate; - } - - public void setExpDataRate(int expDataRate) { - this.expDataRate = expDataRate; - } - - public int getTrafficDensity() { - return trafficDensity; - } - - public void setTrafficDensity(int trafficDensity) { - this.trafficDensity = trafficDensity; - } - - public int getConnDensity() { - return connDensity; - } - - public void setConnDensity(int connDensity) { - this.connDensity = connDensity; - } - - public String getResourceVersion() { - return resourceVersion; - } - - public void setResourceVersion(String resourceVersion) { - this.resourceVersion = resourceVersion; - } + @JsonProperty("resource-version") + private String resourceVersion; } diff --git a/server/src/test/java/org/onap/usecaseui/server/service/slicingdomain/aai/bean/AAIServiceProfilesTest.java b/server/src/test/java/org/onap/usecaseui/server/service/slicingdomain/aai/bean/AAIServiceProfilesTest.java index 79917ee3..f407c828 100644 --- a/server/src/test/java/org/onap/usecaseui/server/service/slicingdomain/aai/bean/AAIServiceProfilesTest.java +++ b/server/src/test/java/org/onap/usecaseui/server/service/slicingdomain/aai/bean/AAIServiceProfilesTest.java @@ -33,14 +33,7 @@ public class AAIServiceProfilesTest { public void testSetAndGetAAIServiceProfiles() throws Exception { AAIServiceProfiles aaiServiceProfiles = new AAIServiceProfiles(); aaiServiceProfiles.setActivityFactor(100); - aaiServiceProfiles.setAreaTrafficCapDL(200); - aaiServiceProfiles.setAreaTrafficCapUL(200); - aaiServiceProfiles.setConnDensity(100); aaiServiceProfiles.setCoverageAreaTAList("test"); - aaiServiceProfiles.setCsAvailability(200); - aaiServiceProfiles.setExpDataRate(100); - aaiServiceProfiles.setExpDataRateDL(200); - aaiServiceProfiles.setExpDataRateUL(100); aaiServiceProfiles.setJitter(20); aaiServiceProfiles.setLatency(20); aaiServiceProfiles.setMaxNumberOfUEs(20); @@ -49,18 +42,9 @@ public class AAIServiceProfilesTest { aaiServiceProfiles.setResourceSharingLevel("share"); aaiServiceProfiles.setResourceVersion("ver123"); aaiServiceProfiles.setSurvivalTime(200); - aaiServiceProfiles.setTrafficDensity(200); aaiServiceProfiles.setUeMobilityLevel("mobile"); - aaiServiceProfiles.getActivityFactor(); - aaiServiceProfiles.getAreaTrafficCapDL(); - aaiServiceProfiles.getAreaTrafficCapUL(); - aaiServiceProfiles.getConnDensity(); aaiServiceProfiles.getCoverageAreaTAList(); - aaiServiceProfiles.getCsAvailability(); - aaiServiceProfiles.getExpDataRate(); - aaiServiceProfiles.getExpDataRateUL(); - aaiServiceProfiles.getExpDataRateDL(); aaiServiceProfiles.getJitter(); aaiServiceProfiles.getLatency(); aaiServiceProfiles.getMaxNumberOfUEs(); @@ -69,7 +53,6 @@ public class AAIServiceProfilesTest { aaiServiceProfiles.getResourceSharingLevel(); aaiServiceProfiles.getResourceVersion(); aaiServiceProfiles.getSurvivalTime(); - aaiServiceProfiles.getTrafficDensity(); aaiServiceProfiles.getUeMobilityLevel(); } } |