Add SO APIs to Nokia VNFM adapter
[vfc/nfvo/driver/vnfm/svnfm.git] / nokiav2 / driver / src / main / java / org / onap / vfc / nfvo / driver / vnfm / svnfm / nokia / onap / so / ISoV2LifecycleManager.java
1 /*
2  * Copyright 2016-2017, Nokia Corporation
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *     http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 package org.onap.vfc.nfvo.driver.vnfm.svnfm.nokia.onap.so;
17
18 import javax.servlet.http.HttpServletResponse;
19 import org.onap.vnfmadapter.so.v2.model.*;
20
21 public interface ISoV2LifecycleManager {
22
23     /**
24      * Create the VNF in VNFM
25      *
26      * @param vnfIdInAai the identifier of the VNF in A&AI
27      * @param request the SO VNF creation request
28      * @param httpResponse the HTTP response
29      */
30     void createVnf(String vnfIdInAai, SoV2VnfCreateRequest request, HttpServletResponse httpResponse);
31
32     /**
33      * Query VNF
34      *
35      * @param vnfIdInAai the identifier of the VNF in A&AI
36      * @param request the VF module update request
37      * @param httpResponse the HTTP response
38      * @return the VNF query
39      */
40     SoV2VnfQueryResponse queryVnf(String vnfIdInAai, SoV2VnfQueryRequest request, HttpServletResponse httpResponse);
41
42     /**
43      * Delete the VNF in VNFM
44      *
45      * @param vnfIdInAai the identifier of the VNF in A&AI
46      * @param request the VNF deletion request
47      * @param httpServletResponse the HTTP response
48      */
49     void delete(String vnfIdInAai, SoV2VnfDeleteRequest request, HttpServletResponse httpServletResponse);
50
51     /**
52      * Update the VNF in VNFM
53      *
54      * - only the VNF modifiable attributes are updated
55      *
56      * @param vnfIdInAai the identifier of the VNF in A&AI
57      * @param request the SO VNF update request
58      * @param httpResponse the HTTP response
59      * @return the response the HTTP response
60      */
61     SoV2VnfUpdateResponse updateVnf(String vnfIdInAai, SoV2VnfUpdateRequest request, HttpServletResponse httpResponse);
62
63
64     /**
65      * Rollback the operation on the VNFM
66      * @param vnfIdInAai the identifier of the VNF in A&AI
67      * @param rollback the rollback parameters
68      */
69     void rollback(String vnfIdInAai, SoV2RollbackVnfUpdate rollback, HttpServletResponse httpServletResponse);
70
71     /**
72      * Create VF module in VNFM
73      *
74      * @param vnfIdInAai the identifier of the VNF in A&AI
75      * @param vfModuleId the identifier of the VF module in A&AI
76      * @param request the creation request
77      * @param httpResponse the HTTP response
78      */
79     void createVfModule(String vnfIdInAai, String vfModuleId, SoV2VfModuleCreateRequest request, HttpServletResponse httpResponse);
80
81     /**
82      * Delete VF module in VNFM
83      *
84      * @param vnfIdInAai the identifier of the VNF in A&AI
85      * @param vfModuleId the identifier of the VF module in A&AI
86      * @param request the deletion request
87      * @param httpResponse the HTTP response
88      */
89     void deleteVfModule(String vnfIdInAai, String vfModuleId, SoV2VnfDeleteRequest request, HttpServletResponse httpResponse);
90
91     /**
92      * Update VF module
93      *
94      * @param vnfIdInAai the identifier of the VNF in A&AI
95      * @param vfModuleId the identifier of the VF module in A&AI
96      * @param request the VF module update request
97      * @param httpResponse the HTTP response
98      * @return the response
99      */
100     SoV2VnfUpdateResponse updateVfModule(String vnfIdInAai, String vfModuleId, SoV2VnfUpdateRequest request, HttpServletResponse httpResponse);
101
102 }