Updating APPC Titles
[appc.git] / docs / APPC LCM API Guide / APPC LCM API Guide.rst
1 .. ============LICENSE_START==========================================
2 .. ===================================================================
3 .. Copyright © 2017 AT&T Intellectual Property. All rights reserved.
4 .. ===================================================================
5 .. Licensed under the Creative Commons License, Attribution 4.0 Intl.  (the "License");
6 .. you may not use this documentation except in compliance with the License.
7 .. You may obtain a copy of the License at
8 .. 
9 ..  https://creativecommons.org/licenses/by/4.0/
10 .. 
11 .. Unless required by applicable law or agreed to in writing, software
12 .. distributed under the License is distributed on an "AS IS" BASIS,
13 .. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 .. See the License for the specific language governing permissions and
15 .. limitations under the License.
16 .. ============LICENSE_END============================================
17 .. ECOMP is a trademark and service mark of AT&T Intellectual Property.
18
19 .. _appc_api_guide:
20
21 ==================
22 APPC LCM API Guide
23 ==================
24
25 Introduction
26 ============
27
28 This guide describes the APPC API that allows you to manage and control the life cycle of controlled virtual network functions (VNFs).
29
30
31 Target Audience
32 ---------------
33 This document is intended for an advanced technical audience, such as the engineers or architects who need to use this guide to develop an interfacing application. The guide assumes a knowledge of the Open Network Automation Platform (ONAP) components and features, and familiarity with JSON notation.
34
35
36 Life Cycle Management Commands
37 ==============================
38
39 APPC receives commands from external ONAP components, such as SO, Policy, DCAE, or the Portal, to manage the life cycle of virtual applications and their components.
40
41 A virtual application is composed of the following layers of network technology:
42
43 - Virtual Network Function (VNF)
44 - Virtual Network Function Component (VNFC)
45 - Virtual Machine (VM)
46
47 A Life Cycle Management (LCM) command may affect one or more of these layers.
48
49 An LCM command is sent as a request to the APPC using an HTTP POST request or in a message on a message bus (DMaaP or UEB).  A request may result in either a single synchronous response or multiple asynchronous responses:
50
51 - An **asynchronous** command, which is sent as an authorized and valid request, results in at least two discrete response events:
52     - an accept response, to indicate that the request is accepted for processing
53     - a final response to indicate the status and outcome of the request processing
54     - An unauthorized or invalid request results in a single ERROR response.
55
56 - A **synchronous** command, such as Lock or Unlock, results in a single response that is either SUCCESS or ERROR.
57
58 **NOTE:** For both asynchronous or synchronous commands, the first response is always returned using the same transport that the initial action used. For example, if the action request was via the message bus (such as when it originates from Policy), then the response is also via the message bus. However, if the request was via a direct HTTP call, the response is similarly a synchronous HTTP response.
59
60
61 Message Bus and the LCM API Client Library
62 ------------------------------------------
63
64 The recommended approach for sending/receiving requests to APPC is via the message bus.   To support this approach, an APPC client library is available and should be used.  The client library aims to provide consumers of APPC capabilities with a strongly-typed Java interface and to encapsulate the actual interaction with APPC component via the message bus.
65
66 For more details, see the APPC Client Library Guide at:
67
68   :ref:`appc_client_library`
69
70
71 The client library supports both synchronous and asynchronous flows as follows.
72
73 Asynchronous Flow
74 ^^^^^^^^^^^^^^^^^
75
76 - The APPC Client Library is called via an asynchronous API using a full command object, which is mapped to a JSON representation.
77 - The APPC client calls the UEB/DMaaP client and sends the JSON command to a configured topic.
78 - The APPC client pulls response messages from the configured topic.
79 - On receiving the response for the command, APPC client runs the relevant callback method of the consumer ResponseHandler.
80
81 Synchronous Flow
82 ^^^^^^^^^^^^^^^^
83
84 - The APPC Client Library is called via a synchronous API using a full command object, which is mapped to a JSON representation.
85 - The APPC client calls the UEB/DMaaP client and sends the JSON command to a configured topic.
86 - The APPC client pulls response messages from the configured topic.
87 - On receiving the final response for the command, the APPC client returns the response object with a final status.
88
89 The client library adds the following wrapper around request and responses to the LCM API (described below)::
90
91     {
92         "version" : "2.0",
93         "cambria.partition" : "<TOPIC>",
94         "correlation-id" :"<CORRELATION_ID>",
95         "rpc-name" : "<RPC_NME>",
96         "type" : <MESSAGE_TYPE>
97         "body" : <RPC_SPECIFIC_BODY>
98     }
99
100
101
102 Table 1 Request / Response Message Fields
103
104 +----------------------+----------------------------------------------------------------------------------------------------------------+---------------------+
105 | **Field**            | **Description**                                                                                                | **Required**        |
106 +======================+================================================================================================================+=====================+
107 | version              | Indicates the version of the message bus protocol with APPC. Version 2.0 should be used.                       |     Yes             |
108 +----------------------+----------------------------------------------------------------------------------------------------------------+---------------------+
109 | cambria. partition   | Indicates the specific topic partition that the message is intended for. For example:                          |     No              |
110 |                      |                                                                                                                |                     |
111 |                      | -  For incoming messages, this value should be APP-C.                                                          |                     |
112 |                      |                                                                                                                |                     |
113 +----------------------+----------------------------------------------------------------------------------------------------------------+---------------------+
114 | correlation- id      | Correlation ID used for associating responses in APPC Client Library. Built as: <request-id>-<sub-request-id>  |     Yes             |
115 +----------------------+----------------------------------------------------------------------------------------------------------------+---------------------+
116 | rpc-name             | The target Remote Processing Call (RPC) name which should match the LCM command name. For example: configure   |     Yes             |
117 +----------------------+----------------------------------------------------------------------------------------------------------------+---------------------+
118 | type                 | Message type: request, response or error                                                                       |     Yes             |
119 +----------------------+----------------------------------------------------------------------------------------------------------------+---------------------+
120 | body                 | Contains the input or output LCM command content, which is either the request or response                      |                     |
121 |                      | The body field format is identical to the equivalent HTTP Rest API command based on the specific RPC name      |     Yes             |
122 |                      |                                                                                                                |                     |
123 +----------------------+----------------------------------------------------------------------------------------------------------------+---------------------+
124
125
126 Generic Request Format
127 ----------------------
128
129 The LCM API general request format is applicable for both POST HTTP API and for the message body received via the EUB/DMaaP bus.
130
131 LCM Request
132 ^^^^^^^^^^^
133
134 The LCM request comprises a common header and a section containing the details of the LCM action.
135 The LCM request conforms to the following structure::
136
137     {
138     "input": {
139                 "common-header": {"timestamp": "<TIMESTAMP>",
140                                         "api-ver": "<API_VERSION>",
141                                         "originator-id": "<ECOMP_SYSTEM_ID>",
142                                         "request-id": "<ECOMP_REQUEST_ID>",
143                                         "sub-request-id": "<ECOMP_SUBREQUEST_ID>",
144                                         "flags": {
145                                                    "mode": "<EXCLUSIVE|NORMAL>",
146                                                    "force": "<TRUE|FALSE>",
147                                                    "ttl": "<TTL_VALUE>"
148                                                  }
149                                  },
150                 "action": "<COMMAND_ACTION>",
151                 "action-identifiers": {
152                                         "vnf-id": "<ECOMP_VNF_ID>",
153                                         "vnfc-name": "<ECOMP_VNFC_NAME>",
154                                         "vserver-id": "VSERVER_ID"
155                                       },
156                 ["payload": "<PAYLOAD>"]
157              }
158     }
159
160
161 Table 2 LCM Request Fields
162
163 +---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
164 |     **Field**             |     **Description**                                                                                                                                                                                                                                                                                                    |     **Required?**   |
165 +===========================+========================================================================================================================================================================================================================================================================================================================+=====================+
166 |     input                 |     The block that defines the details of the input to the command processing. Contains the common-header details.                                                                                                                                                                                                     |     Yes             |
167 +---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
168 |     common- header        |     The block that contains the generic details about a request.                                                                                                                                                                                                                                                       |     Yes             |
169 +---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
170 |     timestamp             |     The time of the request, in ISO 8601 format, ZULU offset. For example: 2016-08-03T08:50:18.97Z.                                                                                                                                                                                                                    |     Yes             |
171 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
172 |                           |     APPC will reject the request if timestamp is in the future (due to clock error), or timestamp is too old (compared to TTL flag)                                                                                                                                                                                    |                     |
173 +---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
174 |     api-ver               |     Identifies the API version, in X.YY format, where X denotes the major version increased with each APPC release, and YY is the minor release version. For example:                                                                                                                                                  |     Yes             |
175 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
176 |                           | -  5.00 for this version                                                                                                                                                                                                                                                                                               |                     |
177 +---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
178 |     originator-id         |     An identifier of the calling system limited to a length of 40 characters.                                                                                                                                                                                                                                          |     Yes             |
179 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
180 |                           |     It can be used for addressing purposes, such as to return an asynchronous response to the correct destination, in particular where there are multiple consumers of APPC APIs.                                                                                                                                      |                     |
181 +---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
182 |     request-id            |     The UUID for the request ID, limited to a length of 40 characters. The unique OSS/BSS identifier for the request ID that triggers the current LCM action. Multiple API calls can be made with the same request-id.                                                                                                 |     Yes             |
183 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
184 |                           |     The request-id is stored throughout the operations performed during a single request.                                                                                                                                                                                                                              |                     |
185 +---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
186 |     sub-request-id        |     Uniquely identifies a specific LCM or control action, limited to a length of 40 characters. Persists throughout the life cycle of a single request.                                                                                                                                                                |     No              |
187 +---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
188 |     flags                 |     Generic flags that apply to all LCM actions:                                                                                                                                                                                                                                                                       |     No              |
189 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
190 |                           | -  "MODE" :                                                                                                                                                                                                                                                                                                            |                     |
191 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
192 |                           |    -  "EXCLUSIVE" - accept no queued requests on this VNF while processing, or                                                                                                                                                                                                                                         |                     |
193 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
194 |                           |    -  "NORMAL" - queue other requests until complete                                                                                                                                                                                                                                                                   |                     |
195 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
196 |                           | -  "FORCE" : "TRUE"\|"FALSE" - run action even if target is in an unstable state (for example, if VNF is busy processing another LCM command or if a previous command failed and VNF was indicated as not STABLE), or not.                                                                                             |                     |
197 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
198 |                           |     The specific behavior of forced actions varies, but implies cancellation of the previous action and an override by the new action. The default value is FALSE.                                                                                                                                                     |                     |
199 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
200 |                           |     Force flag are used to bypass APPC’s working state management for the VNF(VNF working State Management) :                                                                                                                                                                                                          |                     |
201 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
202 |                           |     APPC maintains working state (in the VNF\_STATE\_MANAGEMENT table present in the APPC-DB) for the VNF depending on the last action performed on it:                                                                                                                                                                |                     |
203 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
204 |                           |     There are below 3 states appc have for VNF while performing non-read only operation (Read-Only operations are : Lock, Unlock, CheckLock, Sync, Audit etc. ) :                                                                                                                                                      |                     |
205 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
206 |                           |     1) Stable – If the last action performed on a VNF is Successful (returning Success).                                                                                                                                                                                                                               |                     |
207 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
208 |                           |     2) Unstable – This is the intermediate state for any VNF on which operation is being performed.                                                                                                                                                                                                                    |                     |
209 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
210 |                           |     3) Unknown – This is the status when the last action performed on a VNF is not successful.                                                                                                                                                                                                                         |                     |
211 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
212 |                           |     APPC have validation that it will not allow any operations on VNF which is in Unstable or Unknown state. To skip this check end-user can pass Force-flag=true in the request.                                                                                                                                      |                     |
213 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
214 |                           | -  "TTL": <0....N> - The timeout value for the action to run, between action received by APPC and action initiated.                                                                                                                                                                                                    |                     |
215 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
216 |                           |     If no TTL value provided, the default/configurable TTL value is to be used.                                                                                                                                                                                                                                        |                     |
217 +---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
218 |     action                |     The action to be taken by APPC, for example: Test, Start, Terminate.                                                                                                                                                                                                                                               |     Yes             |
219 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
220 |                           |     ***NOTE:** The specific value for the action parameter is provided for each* command.                                                                                                                                                                                                                              |                     |
221 +---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
222 |     action- identifiers   |     A block containing the action arguments. These are used to specify the object upon which APPC LCM command is to operate. At least one action-identifier must be specified (note that vnf-id is mandatory). For actions that are at the VM level, the action-identifiers provided would be vnf-id and vserver-id.   | Yes                 |
223 +---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
224 |     vnf-id                |     Identifies the VNF instance to which this action is to be applied. Required for actions.                                                                                                                                                                                                                           |     Yes             |
225 +---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
226 |     vnfc-name             |     Identifies the VNFC instance to which this action is to be applied. Required if the action applied to a specific VNFC.                                                                                                                                                                                             |     No              |
227 +---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
228 |     vserver-id            |     Identifies a specific VM instance to which this action is to be applied. Required if the action applied to a specific VM. (Populate the vserver-id field with the UUID of the VM)                                                                                                                                  |     No              |
229 +---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
230 |     vf-module-id          |     Identifies a specific VF module to which this action is to be applied. Required if the action applied to a specific VF module.                                                                                                                                                                                     |     No              |
231 +---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
232 |     payload               |     An action-specific open-format field.                                                                                                                                                                                                                                                                              |     No              |
233 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
234 |                           |     The payload can be any valid JSON string value. JSON escape characters need to be added when an inner JSON string is included within the payload, for example: "{\\" vnf -host- ip                                                                                                                                 |                     |
235 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
236 |                           |     -address\\": \\"<VNF-HOST-IP-ADDRESS>\\"}".                                                                                                                                                                                                                                                                        |                     |
237 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
238 |                           |     The payload is typically used to provide parametric data associated with the command, such as a list of configuration parameters.                                                                                                                                                                                  |                     |
239 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
240 |                           |     Note that not all LCM commands need have a payload.                                                                                                                                                                                                                                                                |                     |
241 |                           |                                                                                                                                                                                                                                                                                                                        |                     |
242 |                           |     ***NOTE:** See discussion below on the use of payloads for self-service actions.*                                                                                                                                                                                                                                  |                     |
243 +---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
244
245
246 Generic Response Format
247 -----------------------
248
249
250 This section describes the generic response format.
251
252 The response format is applicable for both POST HTTP API and for the message body received via the EUB/DMaaP bus.
253
254
255 LCM Response
256 ^^^^^^^^^^^^
257
258 The LCM response comprises a common header and a section containing the payload and action details.
259
260 The LCM response conforms to the following structure::
261
262     {
263         "output": {
264                     "common-header": {
265                                         "api-ver": "<API\_VERSION>",
266                                         "flags": {
267                                                    "ttl": <TTL\_VALUE>,
268                                                    "force": "<TRUE\|FALSE>",
269                                                    "mode": "<EXCLUSIVE\|NORMAL>"
270                                                  },
271                                         "originator-id": "<ECOMP\_SYSTEM\_ID>",
272                                         "request-id": "<ECOMP\_REQUEST\_ID>",
273                                         "sub-request-id": "<ECOMP\_SUBREQUEST\_ID>",
274                                         "timestamp": "2016-08-08T23:09:00.11Z",
275                                      },
276                     "payload": "<PAYLOAD>",
277                     [Additional fields],
278                     "status": {
279                                 "code": <RESULT\_CODE>,
280                                 "message": "<RESULT\_MESSAGE>"
281                               }
282                   }
283     }
284
285
286 Table 3 LCM Response Fields
287
288 +----------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
289 |     **Field**        |     **Description**                                                                                                                                                                                                       |     **Required?**   |
290 +======================+===========================================================================================================================================================================================================================+=====================+
291 |     output           |     The block that defines the details of the output of the command processing. Contains the common-header details.                                                                                                       |     Yes             |
292 +----------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
293 |     common- header   |     The block that contains the generic details about a request.                                                                                                                                                          |     Yes             |
294 +----------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
295 |     api-ver          |     Identifies the API version, in X.YY format, where X denotes the major version increased with each APPC release, and YY is the minor release version. For example:                                                     |     Yes             |
296 |                      |                                                                                                                                                                                                                           |                     |
297 |                      | -  5.00 for this version                                                                                                                                                                                                  |                     |
298 +----------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
299 |     originator-id    |     An identifier of the calling system limited to a length of 40 characters.                                                                                                                                             |     Yes             |
300 |                      |                                                                                                                                                                                                                           |                     |
301 |                      |     It can be used for addressing purposes, such as to return an asynchronous response to the correct destination, in particular where there are multiple consumers of APPC APIs.                                         |                     |
302 +----------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
303 |     request-id       |     The UUID for the request ID, limited to a length of 40 characters. The unique OSS/BSS identifier for the request ID that triggers the current LCM action. Multiple API calls can be made with the same request- id.   |     Yes             |
304 |                      |                                                                                                                                                                                                                           |                     |
305 |                      |     The request-id is stored throughout the operations performed during a single request.                                                                                                                                 |                     |
306 +----------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
307 |     sub-request-id   |     Uniquely identifies a specific LCM or control action, limited to a length of 40 characters. Persists throughout the life cycle of a single request.                                                                   |     No              |
308 +----------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
309 |     timestamp        |     The time of the request, in ISO 8601 format, ZULU offset. For example: 2016-08-03T08:50:18.97Z.                                                                                                                       |     Yes             |
310 +----------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
311 |     status           |     The status describes the outcome of the command processing. Contains a code and a message providing success or failure details.                                                                                       |     Yes             |
312 |                      |                                                                                                                                                                                                                           |                     |
313 |                      |     ***NOTE:** See* status *for code values.*                                                                                                                                                                             |                     |
314 +----------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
315 |     payload          |     An open-format field.                                                                                                                                                                                                 |     No              |
316 |                      |                                                                                                                                                                                                                           |                     |
317 |                      |     The payload can be any valid JSON string value. JSON escape characters need to be added when an inner JSON string is included within the payload, for example: "{\\"upload\_config\_id\\": \\"<value\\"}".            |                     |
318 |                      |                                                                                                                                                                                                                           |                     |
319 |                      |     The payload is typically used to provide parametric data associated with the response to the command.                                                                                                                 |                     |
320 |                      |                                                                                                                                                                                                                           |                     |
321 |                      |     Note that not all LCM commands need have a payload.                                                                                                                                                                   |                     |
322 |                      |                                                                                                                                                                                                                           |                     |
323 |                      |     ***NOTE:** The specific value(s) for the response payload, where relevant, is provided for in each* command *description.*                                                                                            |                     |
324 +----------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
325 |     [Field name]     |     Additional fields can be provided in the response, if needed, by specific commands.                                                                                                                                   |     No              |
326 +----------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
327 |     code             |     A unique pre-defined value that identifies the exact nature of the success or failure status.                                                                                                                         |     No              |
328 +----------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
329 |     message          |     The description of the success or failure status.                                                                                                                                                                     |     No              |
330 +----------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+
331
332
333 Status Codes
334 ------------
335
336 The status code is returned in the response message as the code parameter, and the description as the message parameter.
337
338 The different responses are categorized as follows:
339
340 **ACCEPTED**
341
342     Request is valid and accepted for processing.
343
344 **ERROR**
345
346     Request invalid or incomplete.
347
348 **REJECT**
349
350     Request rejected during processing due to invalid data, such as an
351     unsupported command or a non-existent service-instance-id.
352
353 **SUCCESS**
354
355     Request is valid and completes successfully.
356
357 **FAILURE**
358
359     The request processing resulted in failure.
360
361     A FAILURE response is always returned asynchronously via the message
362     bus.
363
364 **PARTIAL SUCCESS**
365
366     The request processing resulted in partial success where at least
367     one step in a longer process completed successfully.
368
369     A PARTIAL SUCCESS response is always returned asynchronously via the
370     message bus.
371
372 **PARTIAL FAILURE**
373
374     The request processing resulted in partial failure.
375
376     A PARTIAL FAILURE response is always returned asynchronously via the
377     message bus.
378
379 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
380 |     **Category**      |     **Code**   |     **Message / Description**                                                                                                        |
381 +=======================+================+======================================================================================================================================+
382 |     ACCEPTED          |     100        |     ACCEPTED - Request accepted                                                                                                      |
383 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
384 |     ERROR             |     200        |     UNEXPECTED ERROR - ${detailedErrorMsg}                                                                                           |
385 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
386 |     REJECT            |     300        |     REJECTED - ${detailedErrorMsg}                                                                                                   |
387 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
388 |                       |     301        |     INVALID INPUT PARAMETER -${detailedErrorMsg}                                                                                     |
389 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
390 |                       |     302        |     MISSING MANDATORY PARAMETER - Parameter ${paramName} is missing                                                                  |
391 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
392 |                       |     303        |     REQUEST PARSING FAILED - ${detailedErrorMsg}                                                                                     |
393 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
394 |                       |     304        |     NO TRANSITION DEFINED - No Transition Defined for ${actionName} action and ${currentState} state                                 |
395 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
396 |                       |     305        |     ACTION NOT SUPPORTED - ${actionName} action is not supported                                                                     |
397 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
398 |                       |     306        |     VNF NOT FOUND - VNF with ID ${vnfId} was not found                                                                               |
399 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
400 |                       |     307        |     DG WORKFLOW NOT FOUND - No DG workflow found for the combination of ${dgModule} module ${dgName} name and ${dgVersion} version   |
401 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
402 |                       |     308        |     WORKFLOW NOT FOUND - No workflow found for VNF type                                                                              |
403 |                       |                |                                                                                                                                      |
404 |                       |                |     ${vnfTypeVersion} and ${actionName} action                                                                                       |
405 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
406 |                       |     309        |     UNSTABLE VNF - VNF ${vnfId} is not stable to accept the command                                                                  |
407 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
408 |                       |     310        |     LOCKING FAILURE -${detailedErrorMsg}                                                                                             |
409 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
410 |                       |     311        |     EXPIREDREQUEST. The request processing time exceeded the maximum available time                                                  |
411 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
412 |                       |     312        |     DUPLICATEREQUEST. The request already exists                                                                                     |
413 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
414 |                       |     313        |     MISSING VNF DATA IN A&AI - ${attributeName} not found for VNF ID =                                                               |
415 |                       |                |                                                                                                                                      |
416 |                       |                |     ${vnfId}                                                                                                                         |
417 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
418 |     SUCCESS           |     400        |     The request was processed successfully                                                                                           |
419 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
420 |     FAILURE           |     401        |     DG FAILURE - ${ detailedErrorMsg }                                                                                               |
421 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
422 |                       |     402        |     NO TRANSITION DEFINED - No Transition Defined for ${ actionName} action and ${currentState} state                                |
423 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
424 |                       |     403        |     UPDATE\_AAI\_FAILURE - failed to update AAI. ${errorMsg}                                                                         |
425 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
426 |                       |     404        |     EXPIRED REQUEST FAILURE - failed during processing because TTL expired                                                           |
427 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
428 |                       |     405        |     UNEXPECTED FAILURE - ${detailedErrorMsg}                                                                                         |
429 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
430 |                       |     406        |     UNSTABLE VNF FAILURE - VNF ${vnfId} is not stable to accept the command                                                          |
431 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
432 |                       |     450        |     Requested action is not supported on the VNF                                                                                     |
433 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
434 |     PARTIAL SUCCESS   |     500        |     PARTIAL SUCCESS                                                                                                                  |
435 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
436 |     PARTIAL FAILURE   |     501 -      |     PARTIAL FAILURE                                                                                                                  |
437 |                       |                |                                                                                                                                      |
438 |                       |     599        |                                                                                                                                      |
439 +-----------------------+----------------+--------------------------------------------------------------------------------------------------------------------------------------+
440
441
442 Malformed Message Response
443 --------------------------
444
445 A malformed message is an invalid request based on the LCM API YANG scheme specification. APPC rejects malformed requests as implemented by ODL infrastructure level.
446
447 **Response Format for Malformed Requests**::
448
449     {
450       "errors": {
451                   "error": [
452                             {
453                               "error-type": "protocol",
454                               "error-tag": "malformed-message",
455                               "error-message": "<ERROR-MESSAGE>",
456                               "error-info": "<ERROR-INFO>"
457                             }
458                            ]
459                 }
460     }
461
462
463 **Example Response**::
464
465     {
466       "errors": {
467                   "error": [
468                             {
469                               "error-type": "protocol",
470                               "error-tag": "malformed-message",
471                               "error-message": "Error parsing input: Invalid value 'Stopp' for
472                                enum type. Allowed values are: [Sync, Audit, Stop, Terminate]",
473                               "error-info": "java.lang.IllegalArgumentException: Invalid value
474                                 'Stopp' for enum type. Allowed values are: [Sync, Audit, Stop,
475                                 Terminate]..."
476                             }
477                            ]
478                 }
479     }
480
481
482
483 API Scope
484 =========
485
486 Defines the level at which the LCM command operates for the current release of APPC and the VNF types which are supported for each command.
487
488
489 Commands, or actions, can be performed at one or more of the following scope levels:
490
491
492 +-----------------+----------------------------------------------------------------------------------------+
493 | **VNF**         | Commands can be applied at the level of a specific VNF instance using the vnf-id.      |
494 +-----------------+----------------------------------------------------------------------------------------+
495 | **VF-Module**   | Commands can be applied at the level of a specific VF-Module using the vf-module-id.   |
496 +-----------------+----------------------------------------------------------------------------------------+
497 | **VNFC**        | Commands can be applied at the level of a specific VNFC instance using a vnfc-name.    |
498 +-----------------+----------------------------------------------------------------------------------------+
499 | **VM**          | Commands can be applied at the level of a specific VM instance using a vserver-id.     |
500 +-----------------+----------------------------------------------------------------------------------------+
501
502
503 **VNF’s Types Supported**
504
505 Commands, or actions, may be currently supported on all VNF types or a limited set of VNF types. Note that the intent in the 1710 release is to support all actions on all VNF types which have been successfully onboarded in a self-service mode.
506
507 **Any -** Currently supported on any vnf-type.
508
509 **Any (requires self-service onboarding) –** Currently supported on any vnf-type which has been onboarded using the APPC self-service onboarding process. See further discussion on self-service onboarding below.
510
511
512 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
513 |     **Command**        |     **VNF**   |     **VF-Module**   |     **VNFC**   |     **VM**   |     **VNF/VM Types Supported**                                 |
514 +========================+===============+=====================+================+==============+================================================================+
515 |     Audit              |     Yes       |                     |                |              |     Any (requires self-service onboarding)                     |
516 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
517 |     CheckLock          |     Yes       |                     |                |              |     Any (APPC internal command)                                |
518 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
519 |     Configure          |     Yes       |                     |     Yes        |              |     Any (requires self-service onboarding)                     |
520 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
521 |     ConfigModify       |     Yes       |                     |     Yes        |              |     Any (requires self-service onboarding)                     |
522 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
523 |     ConfigBackup       |     Yes       |                     |                |              |     Chef and Ansible only (requires self-service onboarding)   |
524 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
525 |     ConfigRestore      |     Yes       |                     |                |              |     Chef and Ansible only (requires self-service onboarding)   |
526 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
527 |     Evacuate           |               |                     |                |     Yes      | Any (uses OpenStack Evacuate command)                          |
528 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
529 |     HealthCheck        |     Yes       |                     |                |              |     Any (requires self-service onboarding)                     |
530 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
531 |     Lock               |     Yes       |                     |                |              |     Any (APPC internal command)                                |
532 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
533 |     Migrate            |               |                     |                |     Yes      |     Any (uses OpenStack Migrate command)                       |
534 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
535 |     Rebuild            |               |                     |                |     Yes      |     Any (uses OpenStack Rebuild command)                       |
536 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
537 |     Restart            |     Yes       |                     |                |     Yes      |     Any (uses OpenStack Start and Stop commands)               |
538 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
539 |     Snapshot           |               |                     |                |     Yes      |     Any (uses OpenStack Snapshot command)                      |
540 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
541 |     Start              |     Yes       |     Yes             |                |     Yes      |     Any (uses OpenStack Start command)                         |
542 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
543 |     StartApplication   |     Yes       |                     |                |              |     Chef and Ansible only (requires self-service onboarding)   |
544 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
545 |     Stop               |     Yes       |     Yes             |                |     Yes      |     Any (uses OpenStack Stop command)                          |
546 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
547 |     StopApplication    |     Yes       |                     |                |              |     Chef and Ansible only (requires self-service onboarding)   |
548 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
549 |     Sync               |     Yes       |                     |                |              |     Any (requires self-service onboarding)                     |
550 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
551 |     Unlock             |     Yes       |                     |                |              |     Any (APPC internal command)                                |
552 +------------------------+---------------+---------------------+----------------+--------------+----------------------------------------------------------------+
553
554
555
556 Self-Service VNF Onboarding
557 ---------------------------
558
559 The APPC architecture is designed for VNF self-service onboarding (i.e., a VNF owner or vendor through the use of tools can enable a new VNF to support the LCM API actions that are designate as self-service). The VNF must support one or more of the following interface protocols:
560
561 -  Netconf with uploadable Yang model (requires a Netconf server running
562    on the VNF)
563
564 -  Chef (requires a Chef client running on the VNF)
565
566 -  Ansible (does not require any changes to the VNF software)
567
568 The self-service onboarding process is done using an APPC Design GUI which interacts with an APPC instance which is dedicated to self-service onboarding. The steps in the onboarding process using the APPC Design GUI are:
569
570 -  Define the VNF capabilities (set of actions that the VNF can
571    support).
572
573 -  Create a template and parameter definitions for actions which use the
574    Netconf, Chef, or Ansible protocols. The template is an xml or JSON
575    block which defines the “payload” which is included in the request
576    that is downloaded the VNF (if Netconf) or Chef/Ansible server.
577
578 -  Test actions which have templates/parameter definitions.
579
580 -  Upload the VNF definition, template, and parameter definition
581    artifacts to SDC which distributes them to all APPC instances in the
582    same environment (e.g., production).
583
584 For more details, see the APPC Self-Service VNF Onboarding Guide.
585
586
587
588 LCM Commands
589 ============
590
591 The LCM commands that are valid for the current release.
592
593
594 Audit
595 -----
596
597 The Audit command compares the configuration of the VNF associated with the current request against the most recent configuration that is stored in APPC's configuration database.
598
599 A successful Audit means that the current VNF configuration matches the latest APPC stored configuration.
600
601 A failed Audit indicates that the configurations do not match.
602
603 This command can be applied to any VNF type. The only restriction is that the VNF has been onboarded in self-service mode (which requires that the VNF supports a request to return the running configuration).
604
605 The Audit action does not require any payload parameters.
606
607 **NOTE:** Audit does not return a payload containing details of the comparison, only the Success/Failure status.
608
609
610 +------------------------------+------------------------------------------------------+
611 |     **Target URL**           |     /restconf /operations/ appc-provider-lcm:audit   |
612 +------------------------------+------------------------------------------------------+
613 |     **Action**               |     Audit                                            |
614 +------------------------------+------------------------------------------------------+
615 |     **Action-Identifiers**   |     vnf-id                                           |
616 +------------------------------+------------------------------------------------------+
617 |     **Payload Parameters**   |     See below                                        |
618 +------------------------------+------------------------------------------------------+
619 |     **Revision History**     |     Unchanged in this version.                       |
620 +------------------------------+------------------------------------------------------+
621
622 |
623
624 +----------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+----------------------------------+
625 |     **Parameter**    |     **Description**                                                                                                                                       |     **Required?**   |     **Example**                  |
626 +======================+===========================================================================================================================================================+=====================+==================================+
627 |     publish-config   |     \* If the publish\_config field is set to Y in the payload, then always send the running configuration from the VNF using the Data Router             |     Yes             |     "publish-config": "<Y\|N>"   |
628 |                      |                                                                                                                                                           |                     |                                  |
629 |                      |     \* If the publish\_config field is set to N in the payload, then:                                                                                     |                     |                                  |
630 |                      |                                                                                                                                                           |                     |                                  |
631 |                      |     - If the result of the audit is ‘match’ (latest APPC config and the running config match), do not send the running configuration in the Data Router   |                     |                                  |
632 |                      |                                                                                                                                                           |                     |                                  |
633 |                      |     - If the result of the audit is ‘no match’, then send the running configuration on the Data Router                                                    |                     |                                  |
634 +----------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+----------------------------------+
635
636 Audit Response
637 ^^^^^^^^^^^^^^
638
639 The audit response returns an indication of success or failure of the audit. If a new configuration is uploaded to the APPC database, the payload contains the ‘upload\_config\_id’ and values for any records created. In addition, the configuration is sent to the ONAP Data Router bus which may be received by an external configuration storage system.
640
641
642 CheckLock
643 ---------
644
645 The CheckLock command returns true if the specified VNF is locked; otherwise, false is returned.
646
647 A CheckLock command is deemed successful if the processing completes without error, whether the VNF is locked or not. The command returns only a single response with a final status.
648
649 Note that APPC locks the target VNF during any VNF command processing, so a VNF can have a locked status even if no Lock command has been explicitly called.
650
651 The CheckLock command returns a specific response structure that extends the default LCM response.
652
653 The CheckLock action does not require any payload parameters.
654
655 +------------------------------+--------------------------------------------------------+
656 |     **Target URL**           |     /restconf/operations/appc-provider-lcm:checklock   |
657 +------------------------------+--------------------------------------------------------+
658 |     **Action**               |     CheckLock                                          |
659 +------------------------------+--------------------------------------------------------+
660 |     **Action-Identifiers**   |     vnf-id                                             |
661 +------------------------------+--------------------------------------------------------+
662 |     **Payload Parameters**   |     None                                               |
663 +------------------------------+--------------------------------------------------------+
664 |     **Revision History**     |     Unchanged in this version.                         |
665 +------------------------------+--------------------------------------------------------+
666
667 CheckLock Response
668 ^^^^^^^^^^^^^^^^^^
669
670 The CheckLock command returns a customized version of the LCM
671 response.
672
673
674 +---------------------+---------------------------------------------------------------------------------------+--------------------+---------------------------------+
675 |     **Parameter**   |     **Description**                                                                   |     **Required**   | **?Example**                    |
676 +=====================+=======================================================================================+====================+=================================+
677 |     locked          |     "TRUE"\|"FALSE" - returns TRUE if the specified VNF is locked, otherwise FALSE.   |     No             |     "locked": "<TRUE\|FALSE>"   |
678 +---------------------+---------------------------------------------------------------------------------------+--------------------+---------------------------------+
679
680
681 **Example**::
682
683     {
684       "output": {
685                   "status": {
686                               "code": <RESULT\_CODE>, "message": "<RESULT\_MESSAGE>"
687                             },
688                   "common-header": {
689                                      "api-ver": "<API\_VERSION>",
690                                      "request-id": "<ECOMP\_REQUEST\_ID>", "originator-id":
691                                      "<ECOMP\_SYSTEM\_ID>",
692                                      "sub-request-id": "<ECOMP\_SUBREQUEST\_ID>", "timestamp":
693                                      "2016-08-08T23:09:00.11Z",
694                                      "flags": {
695                                                 "ttl": <TTL\_VALUE>, "force": "<TRUE\|FALSE>",
696                                                 "mode": "<EXCLUSIVE\|NORMAL>"
697                                               }
698                                    },
699                   "locked": "<TRUE\|FALSE>"
700     }
701
702
703 Configure
704 ---------
705
706 Configure a VNF or a VNFC on the VNF after instantiation.
707
708 A set of configuration parameter values specified in the configuration template is included in the request. Other configuration parameter values may be obtained from an external system.
709
710 A successful Configure request returns a success response.
711
712 A failed Configure action returns a failure response and the specific failure messages in the response block.
713
714 +------------------------------+--------------------------------------------------------+
715 |     **Target URL**           |     /restconf/operations/appc-provider-lcm:configure   |
716 +------------------------------+--------------------------------------------------------+
717 |     **Action**               |     Configure                                          |
718 +------------------------------+--------------------------------------------------------+
719 |     **Action-Identifiers**   |     vnf-id                                             |
720 +------------------------------+--------------------------------------------------------+
721 |     **Payload Parameters**   |     See below                                          |
722 +------------------------------+--------------------------------------------------------+
723 |     **Revision History**     |     Unchanged in this version.                         |
724 +------------------------------+--------------------------------------------------------+
725
726 |
727
728 +---------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------+
729 |     **Payload Parameter**       |     **Description**                                                                                                                                                                                                                                                                                        |     **Required?**   |     **Example**                                                 |
730 |                                 |                                                                                                                                                                                                                                                                                                            |                     |                                                                 |
731 +=================================+============================================================================================================================================================================================================================================================================================================+=====================+=================================================================+
732 |     request- parameters         |     The parameters required to process the request must include the host-ip-address to connect to the VNF, if Netconf. A template-name may also be included in the event that a specific configuration template needs to be identified. If the request is vnfc-specific, the vnfc-type must be included.   |     Yes             |                                                                 |
733 |                                 |                                                                                                                                                                                                                                                                                                            |                     |     "payload":                                                  |
734 |                                 |                                                                                                                                                                                                                                                                                                            |                     |                                                                 |
735 |                                 |                                                                                                                                                                                                                                                                                                            |                     |     "{\"request-parameters                                      |
736 |                                 |                                                                                                                                                                                                                                                                                                            |                     |                                                                 |
737 |                                 |                                                                                                                                                                                                                                                                                                            |                     |     \": {                                                       |
738 |                                 |                                                                                                                                                                                                                                                                                                            |                     |                                                                 |
739 |                                 |                                                                                                                                                                                                                                                                                                            |                     |     \"host-ip-address\": \”value\”,                             |
740 |                                 |                                                                                                                                                                                                                                                                                                            |                     |                                                                 |
741 |                                 |                                                                                                                                                                                                                                                                                                            |                     |     \”vnfc-type\”: \”value\”’,                                  |
742 |                                 |                                                                                                                                                                                                                                                                                                            |                     |                                                                 |
743 |                                 |                                                                                                                                                                                                                                                                                                            |                     |     \”template-name\”: \”name\”                                 |
744 |                                 |                                                                                                                                                                                                                                                                                                            |                     |                                                                 |
745 |                                 |                                                                                                                                                                                                                                                                                                            |                     |     }                                                           |
746 |                                 |                                                                                                                                                                                                                                                                                                            |                     |                                                                 |
747 |                                 |                                                                                                                                                                                                                                                                                                            |                     |     \"configuration- parameters\": {\"<CONFIG- PARAMS>\"}       |
748 |                                 |                                                                                                                                                                                                                                                                                                            |                     |                                                                 |
749 +---------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------+
750 |     configuration- parameters   |     A set of instance specific configuration parameters should be specified. If provided, APPC replaces variables in the configuration template with the values supplied.                                                                                                                                  |     No              |                                                                 |
751 +---------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------+
752
753
754 Configure Response
755 ^^^^^^^^^^^^^^^^^^
756
757 The Configure response returns an indication of success or failure of the request. If successful, the return payload contains the ‘upload\_config\_id’ and values for any records created. In addition, the configuration is sent to the ONAP Data Router bus  which may be received by an external configuration storage system.
758
759 SO is creating the VNFC records in A&AI. APPC is updating the VNFC status.
760
761 ConfigModify
762 ------------
763
764 Modifies the configuration on a VNF or VNFC in service.
765
766 A successful ConfigModify request returns a success response.
767
768 A failed ConfigModify action returns a failure response code and the specific failure message in the response block.
769
770 **NOTE:** See also `Configure <#_bookmark35>`__
771
772 +------------------------------+-----------------------------------------------------------+
773 |     **Target URL**           |     /restconf/operations/appc-provider-lcm:configmodify   |
774 +------------------------------+-----------------------------------------------------------+
775 |     **Action**               |     ConfigModify                                          |
776 +------------------------------+-----------------------------------------------------------+
777 |     **Action-Identifiers**   |     Vnf-id                                                |
778 +------------------------------+-----------------------------------------------------------+
779 |     **Payload Parameters**   |     See below                                             |
780 +------------------------------+-----------------------------------------------------------+
781 |     **Revision History**     |     Unchanged in this version.                            |
782 +------------------------------+-----------------------------------------------------------+
783
784 |
785
786 +---------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------+
787 |     **Payload Parameter**       |     **Description**                                                                                                                                                                                                                                                                                        |     **Required?**   |     **Example**                                                 |
788 +=================================+============================================================================================================================================================================================================================================================================================================+=====================+=================================================================+
789 |     request- parameters         |     The parameters required to process the request must include the host-ip-address to connect to the VNF, if Netconf. A template-name may also be included in the event that a specific configuration template needs to be identified. If the request is vnfc-specific, the vnfc-type must be included.   |     Yes             |     "payload":                                                  |
790 |                                 |                                                                                                                                                                                                                                                                                                            |                     |                                                                 |
791 |                                 |                                                                                                                                                                                                                                                                                                            |                     |     "{\"request-parameters                                      |
792 |                                 |                                                                                                                                                                                                                                                                                                            |                     |                                                                 |
793 |                                 |                                                                                                                                                                                                                                                                                                            |                     |     \": {                                                       |
794 |                                 |                                                                                                                                                                                                                                                                                                            |                     |                                                                 |
795 |                                 |                                                                                                                                                                                                                                                                                                            |                     |     \"host-ip-address\": \”value\”,                             |
796 |                                 |                                                                                                                                                                                                                                                                                                            |                     |                                                                 |
797 |                                 |                                                                                                                                                                                                                                                                                                            |                     |     \”vnfc-type\”: \”value\”’                                   |
798 |                                 |                                                                                                                                                                                                                                                                                                            |                     |                                                                 |
799 |                                 |                                                                                                                                                                                                                                                                                                            |                     |     \”template-name\”: \”name\”,                                |
800 |                                 |                                                                                                                                                                                                                                                                                                            |                     |                                                                 |
801 |                                 |                                                                                                                                                                                                                                                                                                            |                     |     }                                                           |
802 |                                 |                                                                                                                                                                                                                                                                                                            |                     |                                                                 |
803 |                                 |                                                                                                                                                                                                                                                                                                            |                     |     \"configuration- parameters\": {\"<CONFIG- PARAMS>\"}       |
804 +---------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------+
805 |     configuration- parameters   |     A set of instance specific configuration parameters should be specified. If provided, APPC replaces variables in the configuration template with the values supplied.                                                                                                                                  |     No              |                                                                 |
806 +---------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------+
807
808 If successful, this request returns a success response.
809
810 A failed Configure action returns a failure response and the specific failure message in the response block.
811
812 ConfigModify Response
813 ^^^^^^^^^^^^^^^^^^^^^
814
815 The ConfigModify response returns an indication of success or failure of the request. If successful, the return payload contains the ‘upload\_config\_id’ and values for any records created. In addition, the configuration is sent to the ONAP Data Router bus which may be received by an external configuration storage system.
816
817 ConfigBackup
818 ------------
819
820 Stores the current VNF configuration on a local file system (not in APPC). This is limited to Ansible and Chef. There can only be one stored configuration (if there is a previously saved configuration, it is replaced with the current VNF configuration).
821
822 A successful ConfigBackup request returns a success response.
823
824 A failed ConfigBackup action returns a failure response code and the specific failure message in the response block.
825
826 +------------------------------+-----------------------------------------------------------+
827 |     **Target URL**           |     /restconf/operations/appc-provider-lcm:configbackup   |
828 +------------------------------+-----------------------------------------------------------+
829 |     **Action**               |     ConfigBackup                                          |
830 +------------------------------+-----------------------------------------------------------+
831 |     **Action-Identifiers**   |     Vnf-id                                                |
832 +------------------------------+-----------------------------------------------------------+
833 |     **Payload Parameters**   |     See below                                             |
834 +------------------------------+-----------------------------------------------------------+
835 |     **Revision History**     |     New in this version.                                  |
836 +------------------------------+-----------------------------------------------------------+
837
838 |
839
840 +---------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------+
841 |     **Payload Parameter**       |     **Description**                                                                                                                                                                |     **Required?**   |     **Example**                                                 |
842 +=================================+====================================================================================================================================================================================+=====================+=================================================================+
843 |     request- parameters         |     The parameters required to process the request must include the host-ip-address to connect to the VNF (for Chef and Ansible, this will be the url to connect to the server).   |     Yes             | "payload":                                                      |
844 |                                 |                                                                                                                                                                                    |                     |                                                                 |
845 |                                 |                                                                                                                                                                                    |                     |     "{\"request-parameters                                      |
846 |                                 |                                                                                                                                                                                    |                     |                                                                 |
847 |                                 |                                                                                                                                                                                    |                     |     \": {                                                       |
848 |                                 |                                                                                                                                                                                    |                     |                                                                 |
849 |                                 |                                                                                                                                                                                    |                     |     \"host-ip-address\": \”value\”                              |
850 |                                 |                                                                                                                                                                                    |                     |                                                                 |
851 |                                 |                                                                                                                                                                                    |                     |     }                                                           |
852 |                                 |                                                                                                                                                                                    |                     |                                                                 |
853 |                                 |                                                                                                                                                                                    |                     |     \"configuration- parameters\": {\"<CONFIG- PARAMS>\"}       |
854 +---------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------+
855 |     configuration- parameters   |     A set of instance specific configuration parameters should be specified, as required by the Chef cookbook or Ansible playbook.                                                 |     No              |                                                                 |
856 +---------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------+
857
858 ConfigBackup Response
859 ^^^^^^^^^^^^^^^^^^^^^
860
861 The ConfigBackup response returns an indication of success or failure of the request.
862
863 ConfigRestore
864 -------------
865
866 Applies a previously saved configuration to the active VNF configuration. This is limited to Ansible and Chef. There can only be one stored configuration.
867
868 A successful ConfigRestore request returns a success response.
869
870 A failed ConfigRestore action returns a failure response code and the specific failure message in the response block.
871
872 +------------------------------+------------------------------------------------------------------------------------------+
873 |     **Target URL**           |     /restconf/operations/appc-provider-lcm:configrestore                                 |
874 +------------------------------+------------------------------------------------------------------------------------------+
875 |     **Action**               |     ConfigRestore                                                                        |
876 +------------------------------+------------------------------------------------------------------------------------------+
877 |     **Action-Identifiers**   |     Vnf-id                                                                               |
878 +------------------------------+------------------------------------------------------------------------------------------+
879 |     **Payload Parameters**   |     `request-parameters <#_bookmark24>`__, `configuration-parameters <#_bookmark26>`__   |
880 +------------------------------+------------------------------------------------------------------------------------------+
881 |     **Revision History**     |     New in this version.                                                                 |
882 +------------------------------+------------------------------------------------------------------------------------------+
883
884 |
885
886 +---------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------+
887 |     **Parameter**               |     **Description**                                                                                                                                                                |     **Required?**   |     **Example**                                                 |
888 +=================================+====================================================================================================================================================================================+=====================+=================================================================+
889 |     request- parameters         |     The parameters required to process the request must include the host-ip-address to connect to the VNF (for Chef and Ansible, this will be the url to connect to the server).   |     Yes             |     "payload":                                                  |
890 |                                 |                                                                                                                                                                                    |                     |                                                                 |
891 |                                 |                                                                                                                                                                                    |                     |     "{\"request-parameters                                      |
892 |                                 |                                                                                                                                                                                    |                     |                                                                 |
893 |                                 |                                                                                                                                                                                    |                     |     \": {                                                       |
894 |                                 |                                                                                                                                                                                    |                     |                                                                 |
895 |                                 |                                                                                                                                                                                    |                     |     \"host-ip-address\\": \”value\”                             |
896 |                                 |                                                                                                                                                                                    |                     |                                                                 |
897 |                                 |                                                                                                                                                                                    |                     |     }                                                           |
898 |                                 |                                                                                                                                                                                    |                     |                                                                 |
899 |                                 |                                                                                                                                                                                    |                     |     \"configuration- parameters\": {\"<CONFIG- PARAMS>\"}       |
900 +---------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------+
901 |     configuration- parameters   |     A set of instance specific configuration parameters should be specified, as required by the Chef cookbook or Ansible playbook.                                                 |     No              |                                                                 |
902 +---------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------+
903
904 ConfigRestore Response
905 ^^^^^^^^^^^^^^^^^^^^^^
906
907 The ConfigRestore response returns an indication of success or failure of the request.
908
909 Evacuate
910 --------
911
912 Evacuates a specified VM from its current host to another. After a successful evacuate, a rebuild VM is performed if a snapshot is available (and the VM boots from a snapshot.
913
914 The host on which the VM resides needs to be down.
915
916 If the node is not specified in the request, it will be selected by relying on internal rules to evacuate. The Evacuate action will fail if the specified target host is not UP/ENABLED.
917
918 After Evacuate, the rebuild VM can be disabled by setting the optional `rebuild-vm <#_bookmark43>`__ parameter to false.
919
920 A successful Evacuate action returns a success response. A failed Evacuate action returns a failure.
921
922 **NOTE:** The command implementation is based on Openstack functionality. For further details, see http://developer.openstack.org/api-ref/compute/.
923
924 +------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
925 |     **Target URL**           |     /restconf/operations/appc-provider-lcm:evacuate                                                                                                            |
926 +------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
927 |     **Action**               |     Evacuate                                                                                                                                                   |
928 +------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
929 |     **Action-identifiers**   |     Vnf-id, vserver-id                                                                                                                                         |
930 +------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
931 |     **Payload Parameters**   |     `vm-id <#_bookmark40>`__, `identity-url <#_bookmark41>`__, `tenant-id <#_bookmark42>`__, `rebuild-vm <#_bookmark43>`__, `targethost-id <#_bookmark44>`__   |
932 +------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
933 |     **Revision History**     |     Unchanged in this version.                                                                                                                                 |
934 +------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
935
936 |
937
938 +----------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+---------------------------------------+
939 |     **Parameter**    |     **Description**                                                                                                                                                              |     **Required?**   |     **Example**                       |
940 +======================+==================================================================================================================================================================================+=====================+=======================================+
941 |     vm-id            |     The unique identifier (UUID) of the resource. For backwards- compatibility, this can be the self- link URL of the VM.                                                        |     Yes             |     "payload":                        |
942 |                      |                                                                                                                                                                                  |                     |                                       |
943 |                      |                                                                                                                                                                                  |                     |     "{\"vm-id\": \"<VM-ID>            |
944 |                      |                                                                                                                                                                                  |                     |                                       |
945 |                      |                                                                                                                                                                                  |                     |     \",                               |
946 |                      |                                                                                                                                                                                  |                     |                                       |
947 |                      |                                                                                                                                                                                  |                     |     \"identity-url\":                 |
948 |                      |                                                                                                                                                                                  |                     |                                       |
949 |                      |                                                                                                                                                                                  |                     |     \"<IDENTITY-URL>\",               |
950 |                      |                                                                                                                                                                                  |                     |                                       |
951 |                      |                                                                                                                                                                                  |                     |     \"tenant-id\\": \"<TENANT-ID>     |
952 |                      |                                                                                                                                                                                  |                     |                                       |
953 |                      |                                                                                                                                                                                  |                     |     \",                               |
954 |                      |                                                                                                                                                                                  |                     |                                       |
955 |                      |                                                                                                                                                                                  |                     |     \"rebuild-vm\": \"false\",        |
956 |                      |                                                                                                                                                                                  |                     |                                       |
957 |                      |                                                                                                                                                                                  |                     |     \"targethost-id\":                |
958 |                      |                                                                                                                                                                                  |                     |                                       |
959 |                      |                                                                                                                                                                                  |                     |     \"nodeblade7\"}"                  |
960 +----------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+---------------------------------------+
961 |     identity- url    |     The identity URL used to access the resource                                                                                                                                 |     No              |                                       |
962 +----------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+---------------------------------------+
963 |     tenant-id        |     The id of the provider tenant that owns the resource                                                                                                                         |     No              |                                       |
964 +----------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+---------------------------------------+
965 |     rebuild- vm      |     A boolean flag indicating if a Rebuild is to be performed after an Evacuate. The default action is to do a Rebuild. It can be switched off by setting the flag to "false".   |     No              |                                       |
966 +----------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+---------------------------------------+
967 |     targethost- id   |     A target hostname indicating the host the VM is evacuated to. By default, the cloud determines the target host.                                                              |     No              |                                       |
968 +----------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+---------------------------------------+
969
970 HealthCheck
971 -----------
972
973 This command runs a VNF health check and returns the result.
974
975 A health check is VNF-specific. For a complex VNF, APPC initiates further subordinate health checks.
976
977 HealthCheck is a VNF level command which interrogates the VNF in order to determine the health of the VNF and the VNFCs. The HealthCheck will be implemented differently for each VNF.
978
979
980 +------------------------------+-----------------------------------------------------------+
981 |     **Target URL**           |     /restconf/operations/appc-provider-lcm:health-check   |
982 +------------------------------+-----------------------------------------------------------+
983 |     **Action**               |     HealthCheck                                           |
984 +------------------------------+-----------------------------------------------------------+
985 |     **Action-Identifiers**   |     Vnf-id                                                |
986 +------------------------------+-----------------------------------------------------------+
987 |     **Payload Parameters**   |     `vnf-host-ip-address <#_bookmark46>`__                |
988 +------------------------------+-----------------------------------------------------------+
989 |     **Revision History**     |     Changed in this version.                              |
990 +------------------------------+-----------------------------------------------------------+
991
992 |
993
994 +-----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------+------------------+-------------------------------------+
995 |     **Paramete**            |     **Description**                                                                                                                                            |  **Required?**   | **Example**                         |
996 +=============================+================================================================================================================================================================+==================+=====================================+
997 |     vnf- host-ip- address   |     The IP address used to connect to the VNF, using a protocol such as SSH. For example, for a vSCP VNF, the floating IP address of the SMP should be used.   |     Yes          |     "payload":                      |
998 |                             |                                                                                                                                                                |                  |                                     |
999 |                             |                                                                                                                                                                |                  |     "{\"vnf-host-ip-address\":      |
1000 |                             |                                                                                                                                                                |                  |                                     |
1001 |                             |                                                                                                                                                                |                  |     \"10.222.22.2\"}"               |
1002 +-----------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------+------------------+-------------------------------------+
1003
1004 Lock
1005 ----
1006
1007 Use the Lock command to ensure exclusive access during a series of critical LCM commands.
1008
1009 The Lock action will return a successful result if the VNF is not already locked or if it was locked with the same request-id, otherwise the action returns a response with a reject status code.
1010
1011 Lock is a command intended for APPC and does not execute an actual VNF command. Instead, lock will ensure that ONAP is granted exclusive access to the VNF.
1012
1013 When a VNF is locked, any subsequent sequential commands with same request-id will be accepted. Commands associated with other request-ids will be rejected.
1014
1015 The Lock command returns only one final response with the status of the request processing.
1016
1017 APPC locks the target VNF during any VNF command processing. If a lock action is then requested on that VNF, it will be rejected because the VNF was already locked, even though no actual lock command was explicitly invoked.
1018
1019 +------------------------------+---------------------------------------------------+
1020 |     **Target URL**           |     /restconf/operations/appc-provider-lcm:lock   |
1021 +------------------------------+---------------------------------------------------+
1022 |     **Action**               |     Lock                                          |
1023 +------------------------------+---------------------------------------------------+
1024 |     **Action-Identifier**    |     Vnf-id                                        |
1025 +------------------------------+---------------------------------------------------+
1026 |     **Payload Parameters**   |     None                                          |
1027 +------------------------------+---------------------------------------------------+
1028 |     **Revision History**     |     Unchanged in this version.                    |
1029 +------------------------------+---------------------------------------------------+
1030
1031 Migrate
1032 -------
1033
1034 Migrates a running target VM from its current host to another.
1035
1036 A destination node will be selected by relying on internal rules to migrate. Migrate calls a command in order to perform the operation.
1037
1038 Migrate suspends the guest virtual machine, and moves an image of the guest virtual machine's disk to the destination host physical machine. The guest virtual machine is then resumed on the destination host physical machine and the disk storage that it used on the source host physical machine is freed.
1039
1040 The migrate action will leave the VM in the same Openstack state the VM had been in prior to the migrate action. If a VM was stopped before migration, a separate VM-level restart command would be needed to restart the VM after migration.
1041
1042 A successful Migrate action returns a success response and the new node identity in the response payload block.
1043
1044 A failed Migrate action returns a failure and the failure messages in the response payload block.
1045
1046 **NOTE:** The command implementation is based on Openstack functionality. For further details, see http://developer.openstack.org/api-ref/compute/.
1047
1048 +--------------------------------+-----------------------------------------------------------------------------------------------+
1049 |     **Target URL**             |     /restconf/operations/appc-provider-lcm:migrate                                            |
1050 +--------------------------------+-----------------------------------------------------------------------------------------------+
1051 |     **Action**                 |     Migrate                                                                                   |
1052 +--------------------------------+-----------------------------------------------------------------------------------------------+
1053 |     **Action-Identifiers**     |     Vnf-id, vserver-id                                                                        |
1054 +--------------------------------+-----------------------------------------------------------------------------------------------+
1055 |     \ **Payload Parameters**   |     `vm-id <#_bookmark52>`__, `identity-url <#_bookmark54>`__, `tenant-id <#_bookmark55>`__   |
1056 +--------------------------------+-----------------------------------------------------------------------------------------------+
1057 |     **Revision History**       |     Unchanged in this version.                                                                |
1058 +--------------------------------+-----------------------------------------------------------------------------------------------+
1059
1060 Payload Parameters
1061
1062 +---------------------+-------------------------------------------------------------------------+---------------------+------------------------------------+
1063 | **Parameter**       |     **Description**                                                     |     **Required?**   |     **Example**                    |
1064 +=====================+=========================================================================+=====================+====================================+
1065 |     vm-id           |     The unique identifier (UUID) of                                     |     Yes             |                                    |
1066 |                     |     the resource. For backwards- compatibility, this can be the self-   |                     |     "payload":                     |
1067 |                     |     link URL of the VM.                                                 |                     |                                    |
1068 |                     |                                                                         |                     |     "{\\"vm-id\": \\"<VM-ID>\\",   |
1069 |                     |                                                                         |                     |     \\"identity-url\\":            |
1070 |                     |                                                                         |                     |                                    |
1071 |                     |                                                                         |                     |     \\"<IDENTITY-URL>\\",          |
1072 +---------------------+-------------------------------------------------------------------------+---------------------+                                    +
1073 |     identity- url   |     The identity url used to access the resource                        |     No              |     \\"tenant-id\\": \\"<TENANT-   |
1074 |                     |                                                                         |                     |     ID>\\"}"                       |
1075 +---------------------+-------------------------------------------------------------------------+---------------------+                                    +
1076 |     tenant-id       |     The id of the provider tenant that owns the resource                |     No              |                                    |
1077 +---------------------+-------------------------------------------------------------------------+---------------------+------------------------------------+
1078
1079 Rebuild
1080 -------
1081
1082 Recreates a target VM instance to a known, stable state.
1083
1084 Rebuild calls an OpenStack command immediately and therefore does not expect any prerequisite operations to be performed, such as shutting off a VM.
1085
1086 APPC only supports the rebuild operation for a VM that boots from image (snapshot), i.e., APPC rejects a rebuild request if it determines the VM boots from volume (disk).
1087
1088 A successful rebuild returns a success response and the rebuild details in the response payload block. A failed rebuild returns a failure and the failure messages in the response payload block.
1089
1090 **NOTE:** The command implementation is based on Openstack functionality. For further details, see http://developer.openstack.org/api-ref/compute/.
1091
1092 +------------------------------+-----------------------------------------------------------------------------------------------+
1093 |     **Target URL**           |     /restconf/operations/appc-provider-lcm:rebuild                                            |
1094 +------------------------------+-----------------------------------------------------------------------------------------------+
1095 |     **Action**               |     Rebuild                                                                                   |
1096 +------------------------------+-----------------------------------------------------------------------------------------------+
1097 |     **Action-identifiers**   |     Vnf-id, vserver-id                                                                        |
1098 +------------------------------+-----------------------------------------------------------------------------------------------+
1099 |     **Payload Parameters**   |     `vm-id <#_bookmark52>`__, `identity-url <#_bookmark54>`__, `tenant-id <#_bookmark55>`__   |
1100 +------------------------------+-----------------------------------------------------------------------------------------------+
1101 |     **Revision History**     |     Unchanged in this version.                                                                |
1102 +------------------------------+-----------------------------------------------------------------------------------------------+
1103
1104 Restart
1105 -------
1106
1107 Use the Restart command to restart a VNF or a single VM. The generic VNF Restart uses a simple restart logic where all VM’s are stopped and re-started.
1108
1109 The generic Restart operation is invoked either for the VM or the VNF level.
1110
1111 +------------------------------+-----------------------------------------------------------------------------------------------------------------+
1112 |     **Input Block**          |     api-ver must be set to 2.00 for *VNF Restart*                                                               |
1113 +------------------------------+-----------------------------------------------------------------------------------------------------------------+
1114 |     **Target URL**           |     /restconf/operations/appc-provider-lcm:restart                                                              |
1115 +------------------------------+-----------------------------------------------------------------------------------------------------------------+
1116 |     **Action**               |     Restart                                                                                                     |
1117 +------------------------------+-----------------------------------------------------------------------------------------------------------------+
1118 |     **Action-identifiers**   |     Vnf-id is required; if restart is for a single VM, then vserver-id is also required.                        |
1119 +------------------------------+-----------------------------------------------------------------------------------------------------------------+
1120 |     **Payload Parameters**   |     For *VNF* Restart: `host Identity <#_bookmark57>`__, `vnf-host-ip-address <#_bookmark58>`__                 |
1121 |                              |                                                                                                                 |
1122 |                              |     For *VM* Restart: `vm-id <#_bookmark52>`__, `identity-url <#_bookmark54>`__, `tenant-id <#_bookmark55>`__   |
1123 +------------------------------+-----------------------------------------------------------------------------------------------------------------+
1124 |     **Revision History**     |     Revised in this version.                                                                                    |
1125 +------------------------------+-----------------------------------------------------------------------------------------------------------------+
1126
1127 Payload Parameters for **VNF Restart**
1128
1129 +-----------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+---------------------------------------+
1130 |     **Parameter**           |     **Description**                                                                                                                                               |     **Required?**   |     **Example**                       |
1131 +=============================+===================================================================================================================================================================+=====================+=======================================+
1132 |     Cloud Identity          |     The identity URL of the OpenStack host on which the VNF resource was created. If not provided, this information will be retrieved from the properties file.   |     No              |     "payload":                        |
1133 |                             |                                                                                                                                                                   |                     |     "{\\" vnf-host-ip-address \\":    |
1134 |                             |                                                                                                                                                                   |                     |                                       |
1135 |                             |                                                                                                                                                                   |                     |     \\"<VNF\_FLOATING\_IP\_ADDRESS>   |
1136 |                             |                                                                                                                                                                   |                     |     \\",                              |
1137 |                             |                                                                                                                                                                   |                     |     \\" hostIdentity \\":             |
1138 |                             |                                                                                                                                                                   |                     |     \\"<OpenStack IP Address>\\"      |
1139 |                             |                                                                                                                                                                   |                     |     }"                                |
1140 +-----------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+---------------------------------------+
1141 |     vnf- host-ip- address   |     The IP address used to connect to the VNF, using a protocol such as SSH. For example, for a vSCP VNF, the floating IP address of the SMP should be used.      |     Yes             |                                       |
1142 +-----------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+---------------------------------------+
1143
1144 Payload Parameters for **VM Restart**
1145
1146 +---------------------+-------------------------------------------------------------------------+---------------------+------------------------------------+
1147 | **Parameter**       |     **Description**                                                     |     **Required?**   |     **Example**                    |
1148 +=====================+=========================================================================+=====================+====================================+
1149 |     vm-id           |     The unique identifier (UUID) of                                     |     Yes             |                                    |
1150 |                     |     the resource. For backwards- compatibility, this can be the self-   |                     |     "payload":                     |
1151 |                     |     link URL of the VM.                                                 |                     |                                    |
1152 |                     |                                                                         |                     |     "{\\"vm-id\\": \\"<VM-ID>\\",  |
1153 |                     |                                                                         |                     |     \\"identity-url\\":            |
1154 |                     |                                                                         |                     |                                    |
1155 +---------------------+-------------------------------------------------------------------------+---------------------+     \\"<IDENTITY-URL>\\",          |
1156 |     identity- url   |     The identity url used to access the resource                        |     No              |     \"tenant-id\": \"<TENANT-      |
1157 |                     |                                                                         |                     |     ID>\"}"                        |
1158 +---------------------+-------------------------------------------------------------------------+---------------------+                                    +
1159 |     tenant-id       |     The id of the provider tenant that owns the resource                |     No              |                                    |
1160 +---------------------+-------------------------------------------------------------------------+---------------------+------------------------------------+
1161
1162 Snapshot
1163 --------
1164
1165 Creates a snapshot of a VM.
1166
1167 The Snapshot command returns a customized response containing a reference to the newly created snapshot instance if the action is successful.
1168
1169 This command can be applied to any VNF type. The only restriction is that the particular VNF should be built based on the generic heat stack.
1170
1171 **NOTE:** The command implementation is based on Openstack functionality. For further details, see http://developer.openstack.org/api-ref/compute/.
1172
1173 +------------------------------+-----------------------------------------------------------------------------------------------------+
1174 |     **Target URL**           |     /restconf/operations/appc-provider-lcm:snapshot                                                 |
1175 +------------------------------+-----------------------------------------------------------------------------------------------------+
1176 |     **Action**               |     Snapshot                                                                                        |
1177 +------------------------------+-----------------------------------------------------------------------------------------------------+
1178 |     **Action-identifiers**   |     Vnf-id is required. If the snapshot is for a single VM, then the vserver-id is also required.   |
1179 +------------------------------+-----------------------------------------------------------------------------------------------------+
1180 |     **Payload Parameters**   |     `vm-id <#_bookmark52>`__, `identity-url <#_bookmark54>`__, `tenant-id <#_bookmark55>`__         |
1181 +------------------------------+-----------------------------------------------------------------------------------------------------+
1182 |     **Revision History**     |     Unchanged in this version.                                                                      |
1183 +------------------------------+-----------------------------------------------------------------------------------------------------+
1184
1185 Payload Parameters
1186
1187 +---------------------+-------------------------------------------------------------------------+---------------------+------------------------------------+
1188 | **Parameter**       |     **Description**                                                     |     **Required?**   |     **Example**                    |
1189 +=====================+=========================================================================+=====================+====================================+
1190 |     vm-id           |     The unique identifier (UUID) of                                     |     Yes             |                                    |
1191 +---------------------+-------------------------------------------------------------------------+---------------------+------------------------------------+
1192 |                     |     the resource. For backwards- compatibility, this can be the self-   |                     |     "payload":                     |
1193 |                     |     link URL of the VM.                                                 |                     |                                    |
1194 |                     |                                                                         |                     |     "{\\"vm-id\": \\"<VM-ID>       |
1195 |                     |                                                                         |                     |                                    |
1196 |                     |                                                                         |                     |     \\",                           |
1197 |                     |     link URL of the VM.                                                 |                     |     \\"identity-url\\":            |
1198 |                     |                                                                         |                     |                                    |
1199 |                     |                                                                         |                     |     \\"<IDENTITY-URL>\\",          |
1200 +---------------------+-------------------------------------------------------------------------+---------------------+                                    +
1201 |     identity- url   |     The identity url used to access the resource                        |     No              |     \\"tenant-id\\": \\"<TENANT-   |
1202 |                     |                                                                         |                     |     ID>\\"}"                       |
1203 +---------------------+-------------------------------------------------------------------------+---------------------+------------------------------------+
1204 |     tenant-id       |     The id of the provider tenant that owns the resource                |     No              |                                    |
1205 +---------------------+-------------------------------------------------------------------------+---------------------+------------------------------------+
1206
1207 Snapshot Response
1208 ^^^^^^^^^^^^^^^^^
1209
1210 The Snapshot command returns an extended version of the LCM response.
1211
1212 The Snapshot response conforms to the `standard response format <#_bookmark5>`__, but has the following additional field.
1213
1214 Additional Parameters
1215
1216 +---------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------+---------------------------------------+
1217 |     **Parameter**   |     **Description**                                                                                                                                    |     **Required**   | **?Example**                          |
1218 +=====================+========================================================================================================================================================+====================+=======================================+
1219 |     snapshot-id     |     The snapshot identifier created by cloud host. This identifier will be returned only in the final success response returned via the message bus.   |     No             |     "snapshot-id": "<SNAPSHOT\_ID>"   |
1220 +---------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------+---------------------------------------+
1221
1222 Start
1223 -----
1224
1225 Use the Start command to start a VNF, VF-Module, or VM that is stopped or not running.
1226
1227 **NOTE:** The command implementation is based on Openstack functionality. For further details, see http://developer.openstack.org/api-ref/compute/.
1228
1229 +------------------------------+--------------------------------------------------------------------------------------------------------------------------------+
1230 |     **Target URL**           |     /restconf/operations/appc-provider-lcm:start                                                                               |
1231 +------------------------------+--------------------------------------------------------------------------------------------------------------------------------+
1232 |     **Action**               |     Start                                                                                                                      |
1233 +------------------------------+--------------------------------------------------------------------------------------------------------------------------------+
1234 |     **Action-identifiers**   |     Vnf-id is required; vf-module-id or vserver-id is also required if the action is at vf-module or vm level, respectively.   |
1235 +------------------------------+--------------------------------------------------------------------------------------------------------------------------------+
1236 |     **Payload Parameters**   |     None                                                                                                                       |
1237 +------------------------------+--------------------------------------------------------------------------------------------------------------------------------+
1238 |     **Revision History**     |     Revised in this version.                                                                                                   |
1239 +------------------------------+--------------------------------------------------------------------------------------------------------------------------------+
1240
1241 StartApplication
1242 ----------------
1243
1244 Starts the VNF application, if needed, after a VM is instantiated/configured or after VM start or restart. Supported using Chef cookbook or Ansible playbook only.
1245
1246 A successful StartApplication request returns a success response.
1247
1248 A failed StartApplication action returns a failure response code and the specific failure message in the response block.
1249
1250 +------------------------------+---------------------------------------------------------------+
1251 |     **Target URL**           |     /restconf/operations/appc-provider-lcm:startapplication   |
1252 +------------------------------+---------------------------------------------------------------+
1253 |     **Action**               |     StartApplication                                          |
1254 +------------------------------+---------------------------------------------------------------+
1255 |     **Action-Identifiers**   |     Vnf-id                                                    |
1256 +------------------------------+---------------------------------------------------------------+
1257 |     **Payload Parameters**   |     See below                                                 |
1258 +------------------------------+---------------------------------------------------------------+
1259 |     **Revision History**     |     New in this version.                                      |
1260 +------------------------------+---------------------------------------------------------------+
1261
1262 |
1263
1264 +---------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------+
1265 |     **Payload Parameter**       |     **Description**                                                                                                                                                                |     **Required?**   |     **Example**                                                 |
1266 +=================================+====================================================================================================================================================================================+=====================+=================================================================+
1267 |     request- parameters         |     The parameters required to process the request must include the host-ip-address to connect to the VNF (for Chef and Ansible, this will be the url to connect to the server).   |     Yes             |     "payload":                                                  |
1268 |                                 |                                                                                                                                                                                    |                     |                                                                 |
1269 |                                 |                                                                                                                                                                                    |                     |     "{\\"request-parameters                                     |
1270 |                                 |                                                                                                                                                                                    |                     |     \\": {                                                      |
1271 |                                 |                                                                                                                                                                                    |                     |     \\"host-ip-address\\": \\”value\\”                          |
1272 |                                 |                                                                                                                                                                                    |                     |     }                                                           |
1273 |                                 |                                                                                                                                                                                    |                     |     \\"configuration- parameters\\": {\\"<CONFIG- PARAMS>\\"}   |
1274 +---------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------+
1275 |     configuration- parameters   |     A set of instance specific configuration parameters should be specified, as required by the Chef cookbook or Ansible playbook.                                                 |     No              |                                                                 |
1276 +---------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------+
1277
1278 StartApplication Response
1279 ^^^^^^^^^^^^^^^^^^^^^^^^^
1280
1281 The StartApplication response returns an indication of success or failure of the request.
1282
1283 Stop
1284 ----
1285
1286 Use the Stop command to start a VNF, VF-Module, or VM that is stopped or not running.
1287
1288 **NOTE:** The command implementation is based on Openstack functionality. For further details, see http://developer.openstack.org/api-ref/compute/.
1289
1290 +------------------------------+--------------------------------------------------------------------------------------------------------------------------------+
1291 |     **Target URL**           |     /restconf/operations/appc-provider-lcm:stop                                                                                |
1292 +------------------------------+--------------------------------------------------------------------------------------------------------------------------------+
1293 |     **Action**               |     Stop                                                                                                                       |
1294 +------------------------------+--------------------------------------------------------------------------------------------------------------------------------+
1295 |     **Action-identifiers**   |     Vnf-id is required; vf-module-id or vserver-id is also required if the action is at vf-module or vm level, respectively.   |
1296 +------------------------------+--------------------------------------------------------------------------------------------------------------------------------+
1297 |     **Payload Parameters**   |     None                                                                                                                       |
1298 +------------------------------+--------------------------------------------------------------------------------------------------------------------------------+
1299 |     **Revision History**     |     Revised in this version.                                                                                                   |
1300 +------------------------------+--------------------------------------------------------------------------------------------------------------------------------+
1301
1302 StopApplication
1303 ---------------
1304
1305 Stops the VNF application gracefully (not lost traffic), if needed, prior to a Stop command. Supported using Chef cookbook or Ansible playbook only.
1306
1307 A successful StopApplication request returns a success response.
1308
1309 A failed StopApplication action returns a failure response code and the specific failure message in the response block.
1310
1311 +------------------------------+--------------------------------------------------------------+
1312 |     **Target URL**           |     /restconf/operations/appc-provider-lcm:stopapplication   |
1313 +------------------------------+--------------------------------------------------------------+
1314 |     **Action**               |     StopApplication                                          |
1315 +------------------------------+--------------------------------------------------------------+
1316 |     **Action-Identifiers**   |     Vnf-id                                                   |
1317 +------------------------------+--------------------------------------------------------------+
1318 |     **Payload Parameters**   |     See below                                                |
1319 +------------------------------+--------------------------------------------------------------+
1320 |     **Revision History**     |     New in this version.                                     |
1321 +------------------------------+--------------------------------------------------------------+
1322
1323 |
1324
1325 +---------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------+
1326 |     **Payload Parameter**       |     **Description**                                                                                                                                                                |     **Required?**   |     **Example**                                                 |
1327 +=================================+====================================================================================================================================================================================+=====================+=================================================================+
1328 |     request- parameters         |     The parameters required to process the request must include the host-ip-address to connect to the VNF (for Chef and Ansible, this will be the url to connect to the server).   |     Yes             |     "payload":                                                  |
1329 |                                 |                                                                                                                                                                                    |                     |     "{\\"request-parameters                                     |
1330 |                                 |                                                                                                                                                                                    |                     |     \\": {                                                      |
1331 |                                 |                                                                                                                                                                                    |                     |     \\"host-ip-address\\": \\”va lue\\”                         |
1332 |                                 |                                                                                                                                                                                    |                     |     }                                                           |
1333 |                                 |                                                                                                                                                                                    |                     |     \\"configuration- parameters\\": {\\"<CONFIG- PARAMS>\\"}   |
1334 +---------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------+
1335 |     configuration- parameters   |     A set of instance specific configuration parameters should be specified, as required by the Chef cookbook or Ansible playbook.                                                 |     No              |                                                                 |
1336 +---------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------+
1337
1338 StopApplication Response
1339 ^^^^^^^^^^^^^^^^^^^^^^^^
1340
1341 The StopApplication response returns an indication of success or failure of the request.
1342
1343 Sync
1344 ----
1345
1346 The Sync action updates the current configuration in the APPC store with the running configuration from the device.
1347
1348 A successful Sync returns a success status.
1349
1350 A failed Sync returns a failure response status and failure messages in the response payload block.
1351
1352 This command can be applied to any VNF type. The only restriction is that the VNF has been onboarded in self-service mode (which requires that the VNF supports a request to return the running configuration).
1353
1354 +------------------------------+---------------------------------------------------+
1355 |     **Target URL**           |     /restconf/operations/appc-provider-lcm:sync   |
1356 +------------------------------+---------------------------------------------------+
1357 |     **Action**               |     Sync                                          |
1358 +------------------------------+---------------------------------------------------+
1359 |     **Action-identifiers**   |     Vnf-id                                        |
1360 +------------------------------+---------------------------------------------------+
1361 |     **Payload Parameters**   |     None                                          |
1362 +------------------------------+---------------------------------------------------+
1363 |     **Revision History**     |     Unchanged in this version.                    |
1364 +------------------------------+---------------------------------------------------+
1365
1366 Unlock
1367 ------
1368
1369 Run the Unlock command to release the lock on a VNF and allow other clients to perform LCM commands on that VNF.
1370
1371 Unlock is a command intended for APPC and does not execute an actual VNF command. Instead, unlock will release the VNF from the exclusive access held by the specific request-id allowing other requests for the VNF to be accepted.
1372
1373 The Unlock command will result in success if the VNF successfully unlocked or if it was already unlocked, otherwise commands will be rejected.
1374
1375 The Unlock command will only return success if the VNF was locked with same `request-id <#_bookmark4>`__.
1376
1377 The Unlock command returns only one final response with the status of the request processing.
1378
1379 Note: APPC locks the target VNF during any command processing. If an Unlock action is then requested on that VNF with a different request-id, it will be rejected because the VNF is already locked for another process, even though no actual lock command was explicitly invoked.
1380
1381 +------------------------------+-----------------------------------------------------+
1382 |     **Target URL**           |     /restconf/operations/appc-provider-lcm:unlock   |
1383 +------------------------------+-----------------------------------------------------+
1384 |     **Action**               |     Unlock                                          |
1385 +------------------------------+-----------------------------------------------------+
1386 |     **Action-identifiers**   |     Vnf-id                                          |
1387 +------------------------------+-----------------------------------------------------+
1388 |     **Payload Parameters**   |     None                                            |
1389 +------------------------------+-----------------------------------------------------+
1390 |     **Revision History**     |     Unchanged in this version.                      |
1391 +------------------------------+-----------------------------------------------------+
1392