diff options
author | Chuanyu Chen <chenchuanyu@huawei.com> | 2020-09-18 09:38:48 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2020-09-18 09:38:48 +0000 |
commit | 150548c32b0d38d5465f81b8b45923d20bb18f1b (patch) | |
tree | 0dad1e5ec8fa49be0ad52241bd4cfbcc77a4d6f9 /common | |
parent | a65d2595848132a3241889ca3843b2308f9d0862 (diff) | |
parent | 177987a9c3bc89a61e211f0fa31781f7abdc3ce8 (diff) |
Merge "Update NSMF workflow to for the E2E Network Slicing requirements"
Diffstat (limited to 'common')
14 files changed, 216 insertions, 213 deletions
diff --git a/common/src/main/java/org/onap/so/beans/nsmf/AllocateAnNssi.java b/common/src/main/java/org/onap/so/beans/nsmf/AllocateAnNssi.java index 156f999773..27c5cf8e26 100644 --- a/common/src/main/java/org/onap/so/beans/nsmf/AllocateAnNssi.java +++ b/common/src/main/java/org/onap/so/beans/nsmf/AllocateAnNssi.java @@ -21,8 +21,11 @@ package org.onap.so.beans.nsmf; import com.fasterxml.jackson.annotation.JsonInclude; +import lombok.Data; +import java.util.Map; @JsonInclude(JsonInclude.Include.NON_NULL) +@Data public class AllocateAnNssi { @Deprecated @@ -42,59 +45,5 @@ public class AllocateAnNssi { private NsiInfo nsiInfo; - public String getNsstId() { - return nsstId; - } - - public void setNsstId(String nsstId) { - this.nsstId = nsstId; - } - - public String getNssiId() { - return nssiId; - } - - public void setNssiId(String nssiId) { - this.nssiId = nssiId; - } - - public String getNssiName() { - return nssiName; - } - - public void setNssiName(String nssiName) { - this.nssiName = nssiName; - } - - public AnSliceProfile getSliceProfile() { - return sliceProfile; - } - - public void setSliceProfile(AnSliceProfile sliceProfile) { - this.sliceProfile = sliceProfile; - } - - public String getScriptName() { - return scriptName; - } - - public void setScriptName(String scriptName) { - this.scriptName = scriptName; - } - - public Object getExtension() { - return extension; - } - - public void setExtension(Object extension) { - this.extension = extension; - } - - public NsiInfo getNsiInfo() { - return nsiInfo; - } - - public void setNsiInfo(NsiInfo nsiInfo) { - this.nsiInfo = nsiInfo; - } + private Map<String, Object> endPoint; } diff --git a/common/src/main/java/org/onap/so/beans/nsmf/AllocateCnNssi.java b/common/src/main/java/org/onap/so/beans/nsmf/AllocateCnNssi.java index bdc2c608e2..f5b926f627 100644 --- a/common/src/main/java/org/onap/so/beans/nsmf/AllocateCnNssi.java +++ b/common/src/main/java/org/onap/so/beans/nsmf/AllocateCnNssi.java @@ -21,9 +21,12 @@ package org.onap.so.beans.nsmf; import com.fasterxml.jackson.annotation.JsonInclude; +import lombok.Data; import java.io.Serializable; +import java.util.Map; @JsonInclude(JsonInclude.Include.NON_NULL) +@Data public class AllocateCnNssi implements Serializable { @Deprecated @@ -46,67 +49,5 @@ public class AllocateCnNssi implements Serializable { private NsiInfo nsiInfo; - public NsiInfo getNsiInfo() { - return nsiInfo; - } - - public void setNsiInfo(NsiInfo nsiInfo) { - this.nsiInfo = nsiInfo; - } - - public String getNsstId() { - return nsstId; - } - - public void setNsstId(String nsstId) { - this.nsstId = nsstId; - } - - public String getScriptName() { - return scriptName; - } - - public void setScriptName(String scriptName) { - this.scriptName = scriptName; - } - - public CnSliceProfile getSliceProfile() { - return sliceProfile; - } - - public void setSliceProfile(CnSliceProfile sliceProfile) { - this.sliceProfile = sliceProfile; - } - - public String getFlavorId() { - return flavorId; - } - - public void setFlavorId(String flavorId) { - this.flavorId = flavorId; - } - - public String getNssiId() { - return nssiId; - } - - public void setNssiId(String nssiId) { - this.nssiId = nssiId; - } - - public String getNssiName() { - return nssiName; - } - - public void setNssiName(String nssiName) { - this.nssiName = nssiName; - } - - public void setExtension(Object extension) { - this.extension = extension; - } - - public Object getExtension() { - return extension; - } + private Map<String, Object> endPoint; } diff --git a/common/src/main/java/org/onap/so/beans/nsmf/ResponseDescriptor.java b/common/src/main/java/org/onap/so/beans/nsmf/ResponseDescriptor.java index 469d212ef9..146032c6fd 100644 --- a/common/src/main/java/org/onap/so/beans/nsmf/ResponseDescriptor.java +++ b/common/src/main/java/org/onap/so/beans/nsmf/ResponseDescriptor.java @@ -21,9 +21,11 @@ package org.onap.so.beans.nsmf; import com.fasterxml.jackson.annotation.JsonInclude; +import lombok.Data; import java.util.List; @JsonInclude(JsonInclude.Include.NON_NULL) +@Data public class ResponseDescriptor { @JsonInclude(JsonInclude.Include.NON_DEFAULT) @@ -43,43 +45,7 @@ public class ResponseDescriptor { private List<ResponseHistory> responseHistoryList; - public int getProgress() { - return progress; - } + private String nssiId; - public void setProgress(int progress) { - this.progress = progress; - } - - public String getStatus() { - return status; - } - - public void setStatus(String status) { - this.status = status; - } - - public String getStatusDescription() { - return statusDescription; - } - - public void setStatusDescription(String statusDescription) { - this.statusDescription = statusDescription; - } - - public String getResponseId() { - return responseId; - } - - public void setResponseId(String responseId) { - this.responseId = responseId; - } - - public List<ResponseHistory> getResponseHistoryList() { - return responseHistoryList; - } - - public void setResponseHistoryList(List<ResponseHistory> responseHistoryList) { - this.responseHistoryList = responseHistoryList; - } + private String endPointId; } diff --git a/common/src/main/java/org/onap/so/beans/nsmf/ServiceInfo.java b/common/src/main/java/org/onap/so/beans/nsmf/ServiceInfo.java index 7a52cc85cb..19e8b46314 100644 --- a/common/src/main/java/org/onap/so/beans/nsmf/ServiceInfo.java +++ b/common/src/main/java/org/onap/so/beans/nsmf/ServiceInfo.java @@ -47,4 +47,6 @@ public class ServiceInfo implements Serializable { private String nssiName; private String pLMNIdList; + + private String actionType; } diff --git a/common/src/main/java/org/onap/so/beans/nsmf/SliceTaskInfo.java b/common/src/main/java/org/onap/so/beans/nsmf/SliceTaskInfo.java index dd1292e7e5..71c50c1684 100644 --- a/common/src/main/java/org/onap/so/beans/nsmf/SliceTaskInfo.java +++ b/common/src/main/java/org/onap/so/beans/nsmf/SliceTaskInfo.java @@ -1,6 +1,26 @@ +/*- + * ============LICENSE_START======================================================= + * ONAP - SO + * ================================================================================ + # Copyright (c) 2020, CMCC Technologies Co., Ltd. + # + # Licensed under the Apache License, Version 2.0 (the "License") + # you may not use this file except in compliance with the License. + # You may obtain a copy of the License at + # + # http://www.apache.org/licenses/LICENSE-2.0 + # + # Unless required by applicable law or agreed to in writing, software + # distributed under the License is distributed on an "AS IS" BASIS, + # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + # See the License for the specific language governing permissions and + # limitations under the License. + * ============LICENSE_END========================================================= + */ package org.onap.so.beans.nsmf; import lombok.Data; +import org.onap.so.beans.nsmf.oof.SubnetType; import org.onap.so.beans.nsmf.oof.TemplateInfo; import java.io.Serializable; @@ -22,7 +42,7 @@ public class SliceTaskInfo<T> implements Serializable { private TemplateInfo NSSTInfo; - private String serviceInstanceId; + private String sliceInstanceId; private String scriptName; @@ -30,4 +50,6 @@ public class SliceTaskInfo<T> implements Serializable { private NetworkType networkType; + private SubnetType subnetType; + } diff --git a/common/src/main/java/org/onap/so/beans/nsmf/SliceTaskParamsAdapter.java b/common/src/main/java/org/onap/so/beans/nsmf/SliceTaskParamsAdapter.java index cab209ebd1..87de04a6ee 100644 --- a/common/src/main/java/org/onap/so/beans/nsmf/SliceTaskParamsAdapter.java +++ b/common/src/main/java/org/onap/so/beans/nsmf/SliceTaskParamsAdapter.java @@ -1,7 +1,27 @@ +/*- + * ============LICENSE_START======================================================= + * ONAP - SO + * ================================================================================ + # Copyright (c) 2020, CMCC Technologies Co., Ltd. + # + # Licensed under the Apache License, Version 2.0 (the "License") + # you may not use this file except in compliance with the License. + # You may obtain a copy of the License at + # + # http://www.apache.org/licenses/LICENSE-2.0 + # + # Unless required by applicable law or agreed to in writing, software + # distributed under the License is distributed on an "AS IS" BASIS, + # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + # See the License for the specific language governing permissions and + # limitations under the License. + * ============LICENSE_END========================================================= + */ package org.onap.so.beans.nsmf; import lombok.Data; import org.onap.so.beans.nsmf.oof.TemplateInfo; +import java.util.Map; @Data @@ -16,7 +36,7 @@ public class SliceTaskParamsAdapter { private String nstName; - private ServiceProfile serviceProfile; + private Map<String, Object> serviceProfile; private String suggestNsiId; diff --git a/common/src/main/java/org/onap/so/beans/nsmf/TnSliceProfile.java b/common/src/main/java/org/onap/so/beans/nsmf/TnSliceProfile.java index be530bfb9c..ccd6001957 100644 --- a/common/src/main/java/org/onap/so/beans/nsmf/TnSliceProfile.java +++ b/common/src/main/java/org/onap/so/beans/nsmf/TnSliceProfile.java @@ -21,8 +21,10 @@ package org.onap.so.beans.nsmf; import com.fasterxml.jackson.annotation.JsonInclude; +import lombok.Data; @JsonInclude(JsonInclude.Include.NON_NULL) +@Data public class TnSliceProfile { private String sliceProfileId; @@ -31,28 +33,4 @@ public class TnSliceProfile { @JsonInclude(JsonInclude.Include.NON_DEFAULT) private int latency; - - public String getSliceProfileId() { - return sliceProfileId; - } - - public void setSliceProfileId(String sliceProfileId) { - this.sliceProfileId = sliceProfileId; - } - - public String getBandwidth() { - return bandwidth; - } - - public void setBandwidth(String bandwidth) { - this.bandwidth = bandwidth; - } - - public int getLatency() { - return latency; - } - - public void setLatency(int latency) { - this.latency = latency; - } } diff --git a/common/src/main/java/org/onap/so/beans/nsmf/oof/DomainType.java b/common/src/main/java/org/onap/so/beans/nsmf/oof/DomainType.java deleted file mode 100644 index 4af60cf492..0000000000 --- a/common/src/main/java/org/onap/so/beans/nsmf/oof/DomainType.java +++ /dev/null @@ -1,27 +0,0 @@ -package org.onap.so.beans.nsmf.oof; - -import lombok.Getter; -import org.onap.so.beans.nsmf.NetworkType; - -@Getter -public enum DomainType { - - AN_NF("AN-NF", NetworkType.ACCESS), - - CN("CN", NetworkType.CORE), - - TN_FH("TN-FH", NetworkType.TRANSPORT), - - TN_MH("TN-MH", NetworkType.TRANSPORT), - - TN_BH("TN-BH", NetworkType.TRANSPORT),; - - private NetworkType networkType; - - private String domainType; - - DomainType(String domainType, NetworkType networkType) { - this.domainType = domainType; - this.networkType = networkType; - } -} diff --git a/common/src/main/java/org/onap/so/beans/nsmf/oof/NsiReqBody.java b/common/src/main/java/org/onap/so/beans/nsmf/oof/NsiReqBody.java index e1829eb2c3..d228d37976 100644 --- a/common/src/main/java/org/onap/so/beans/nsmf/oof/NsiReqBody.java +++ b/common/src/main/java/org/onap/so/beans/nsmf/oof/NsiReqBody.java @@ -1,15 +1,35 @@ +/*- + * ============LICENSE_START======================================================= + * ONAP - SO + * ================================================================================ + # Copyright (c) 2020, CMCC Technologies Co., Ltd. + # + # Licensed under the Apache License, Version 2.0 (the "License") + # you may not use this file except in compliance with the License. + # You may obtain a copy of the License at + # + # http://www.apache.org/licenses/LICENSE-2.0 + # + # Unless required by applicable law or agreed to in writing, software + # distributed under the License is distributed on an "AS IS" BASIS, + # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + # See the License for the specific language governing permissions and + # limitations under the License. + * ============LICENSE_END========================================================= + */ package org.onap.so.beans.nsmf.oof; import lombok.Data; import org.onap.so.beans.nsmf.ServiceProfile; import java.io.Serializable; import java.util.List; +import java.util.Map; @Data public class NsiReqBody implements Serializable { private static final long serialVersionUID = -1383112063216226985L; - private ServiceProfile serviceProfile; + private Map<String, Object> serviceProfile; private RequestInfo requestInfo; diff --git a/common/src/main/java/org/onap/so/beans/nsmf/oof/NssiReqBody.java b/common/src/main/java/org/onap/so/beans/nsmf/oof/NssiReqBody.java index 0632ab78e9..7cfb60c113 100644 --- a/common/src/main/java/org/onap/so/beans/nsmf/oof/NssiReqBody.java +++ b/common/src/main/java/org/onap/so/beans/nsmf/oof/NssiReqBody.java @@ -1,15 +1,35 @@ +/*- + * ============LICENSE_START======================================================= + * ONAP - SO + * ================================================================================ + # Copyright (c) 2020, CMCC Technologies Co., Ltd. + # + # Licensed under the Apache License, Version 2.0 (the "License") + # you may not use this file except in compliance with the License. + # You may obtain a copy of the License at + # + # http://www.apache.org/licenses/LICENSE-2.0 + # + # Unless required by applicable law or agreed to in writing, software + # distributed under the License is distributed on an "AS IS" BASIS, + # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + # See the License for the specific language governing permissions and + # limitations under the License. + * ============LICENSE_END========================================================= + */ package org.onap.so.beans.nsmf.oof; import lombok.Data; import org.onap.so.beans.nsmf.ServiceProfile; import java.io.Serializable; +import java.util.Map; @Data public class NssiReqBody implements Serializable { private static final long serialVersionUID = -76327522074333341L; - private ServiceProfile serviceProfile; + private Map<String, Object> serviceProfile; private RequestInfo requestInfo; diff --git a/common/src/main/java/org/onap/so/beans/nsmf/oof/RequestInfo.java b/common/src/main/java/org/onap/so/beans/nsmf/oof/RequestInfo.java index f900c3599d..292a0d5ae4 100644 --- a/common/src/main/java/org/onap/so/beans/nsmf/oof/RequestInfo.java +++ b/common/src/main/java/org/onap/so/beans/nsmf/oof/RequestInfo.java @@ -1,3 +1,22 @@ +/*- + * ============LICENSE_START======================================================= + * ONAP - SO + * ================================================================================ + # Copyright (c) 2020, CMCC Technologies Co., Ltd. + # + # Licensed under the Apache License, Version 2.0 (the "License") + # you may not use this file except in compliance with the License. + # You may obtain a copy of the License at + # + # http://www.apache.org/licenses/LICENSE-2.0 + # + # Unless required by applicable law or agreed to in writing, software + # distributed under the License is distributed on an "AS IS" BASIS, + # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + # See the License for the specific language governing permissions and + # limitations under the License. + * ============LICENSE_END========================================================= + */ package org.onap.so.beans.nsmf.oof; import lombok.Data; diff --git a/common/src/main/java/org/onap/so/beans/nsmf/oof/SubnetCapability.java b/common/src/main/java/org/onap/so/beans/nsmf/oof/SubnetCapability.java index f21c1c379e..bc52d4e0d4 100644 --- a/common/src/main/java/org/onap/so/beans/nsmf/oof/SubnetCapability.java +++ b/common/src/main/java/org/onap/so/beans/nsmf/oof/SubnetCapability.java @@ -1,8 +1,26 @@ +/*- + * ============LICENSE_START======================================================= + * ONAP - SO + * ================================================================================ + # Copyright (c) 2020, CMCC Technologies Co., Ltd. + # + # Licensed under the Apache License, Version 2.0 (the "License") + # you may not use this file except in compliance with the License. + # You may obtain a copy of the License at + # + # http://www.apache.org/licenses/LICENSE-2.0 + # + # Unless required by applicable law or agreed to in writing, software + # distributed under the License is distributed on an "AS IS" BASIS, + # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + # See the License for the specific language governing permissions and + # limitations under the License. + * ============LICENSE_END========================================================= + */ package org.onap.so.beans.nsmf.oof; import lombok.Data; import java.io.Serializable; -import java.util.Map; @Data public class SubnetCapability implements Serializable { @@ -11,5 +29,5 @@ public class SubnetCapability implements Serializable { private String domainType; - private Map<?, ?> capabilityDetails; + private Object capabilityDetails; } diff --git a/common/src/main/java/org/onap/so/beans/nsmf/oof/SubnetType.java b/common/src/main/java/org/onap/so/beans/nsmf/oof/SubnetType.java new file mode 100644 index 0000000000..4b0136a798 --- /dev/null +++ b/common/src/main/java/org/onap/so/beans/nsmf/oof/SubnetType.java @@ -0,0 +1,56 @@ +/*- + * ============LICENSE_START======================================================= + * ONAP - SO + * ================================================================================ + # Copyright (c) 2020, CMCC Technologies Co., Ltd. + # + # Licensed under the Apache License, Version 2.0 (the "License") + # you may not use this file except in compliance with the License. + # You may obtain a copy of the License at + # + # http://www.apache.org/licenses/LICENSE-2.0 + # + # Unless required by applicable law or agreed to in writing, software + # distributed under the License is distributed on an "AS IS" BASIS, + # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + # See the License for the specific language governing permissions and + # limitations under the License. + * ============LICENSE_END========================================================= + */ +package org.onap.so.beans.nsmf.oof; + +import lombok.Getter; +import org.onap.so.beans.nsmf.NetworkType; + +@Getter +public enum SubnetType { + AN("AN", NetworkType.ACCESS), + + AN_NF("AN-NF", NetworkType.ACCESS), + + CN("CN", NetworkType.CORE), + + TN_FH("TN-FH", NetworkType.TRANSPORT), + + TN_MH("TN-MH", NetworkType.TRANSPORT), + + TN_BH("TN-BH", NetworkType.TRANSPORT),; + + private NetworkType networkType; + + private String subnetType; + + SubnetType(String subnetType, NetworkType networkType) { + this.subnetType = subnetType; + this.networkType = networkType; + } + + public static NetworkType getNetworkType(String subnetType) { + for (SubnetType type : SubnetType.values()) { + if (type.subnetType.equalsIgnoreCase(subnetType)) { + return type.networkType; + } + } + return null; + } +} diff --git a/common/src/main/java/org/onap/so/beans/nsmf/oof/TemplateInfo.java b/common/src/main/java/org/onap/so/beans/nsmf/oof/TemplateInfo.java index 3713bc7186..3d1ec9ce80 100644 --- a/common/src/main/java/org/onap/so/beans/nsmf/oof/TemplateInfo.java +++ b/common/src/main/java/org/onap/so/beans/nsmf/oof/TemplateInfo.java @@ -1,3 +1,22 @@ +/*- + * ============LICENSE_START======================================================= + * ONAP - SO + * ================================================================================ + # Copyright (c) 2020, CMCC Technologies Co., Ltd. + # + # Licensed under the Apache License, Version 2.0 (the "License") + # you may not use this file except in compliance with the License. + # You may obtain a copy of the License at + # + # http://www.apache.org/licenses/LICENSE-2.0 + # + # Unless required by applicable law or agreed to in writing, software + # distributed under the License is distributed on an "AS IS" BASIS, + # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + # See the License for the specific language governing permissions and + # limitations under the License. + * ============LICENSE_END========================================================= + */ package org.onap.so.beans.nsmf.oof; import lombok.Data; |