1 .. This work is licensed under a
2 .. Creative Commons Attribution 4.0 International License.
3 .. http://creativecommons.org/licenses/by/4.0
14 Overview of APPC Legacy Actor
15 #############################
16 ONAP Policy Framework enables APPC Legacy as one of the supported actors.
17 APPC Legacy uses a single DMaaP topic for both requests and responses. As a result, the
18 actor implementation must cope with the fact that requests may appear on the same
19 stream from which it is reading responses, thus it must use the message content to
20 distinguish responses from requests. This particular implementation uses the *Status*
21 field to identify responses.
23 In addition, APPC may generate more than one response for a particular request, the
24 first response simply indicating that the request was accepted, while the second
25 response indicates completion of the request. For each request, a unique sub-request
26 ID is generated. This is used to match the received responses with the published
29 Each operation supported by the actor is associated with its own java class, which is
30 responsible for populating the request structure appropriately. The operation-specific
31 classes are all derived from the *AppcOperation* class, which is, itself, derived from
32 *BidirectionalTopicOperation*.
41 The "CommonHeader" field in the request is built by policy.
43 =============================== =========== ==================================================================
44 "CommonHeader" field name type Description
45 =============================== =========== ==================================================================
46 SubRequestID string Generated by Policy. Is a UUID and used internally by policy
47 to match the response with the request.
48 RequestID string Inserted by Policy. Maps to the UUID sent by DCAE i.e. the ID
49 used throughout the closed loop lifecycle to identify a request.
50 =============================== =========== ==================================================================
55 The "Action" field uniquely identifies the operation to perform. Currently, only
56 "ModifyConfig" is supported.
61 =============================== =========== ==================================================================
62 "Payload" field name type Description
63 =============================== =========== ==================================================================
64 generic-vnf.vnf-id string The ID of the VNF selected from the A&AI Custom Query response
65 using the Target resource ID specified in the
66 *ControlLoopOperationParams*.
67 =============================== =========== ==================================================================
69 Additional fields are populated based on the *payload* specified within the
70 *ControlLoopOperationParams*. Each value found within the *payload* is treated as a
71 JSON string and is decoded into a POJO, which is then inserted into the request payload
78 Suppose the *ControlLoopOperationParams* were populated as follows:
84 "operation": "ModifyConfig",
86 "resourceID": "2246ebc9-9b9f-42d0-a5e4-0248324fb884"
89 "my-key-A": "{\"input\":\"hello\"}",
90 "my-key-B": "{\"output\":\"world\"}"
94 "requestId": "c7c6a4aa-bb61-4a15-b831-ba1472dd4a65"
102 "model-invariant-id": "2246ebc9-9b9f-42d0-a5e4-0248324fb884"
111 An example of a request constructed by the actor using the above parameters, published
118 "TimeStamp": 1589400050910,
120 "RequestID": "c7c6a4aa-bb61-4a15-b831-ba1472dd4a65",
121 "SubRequestID": "ee3f2dc0-a2e0-4ae8-98c3-478c784b8eb5",
125 "Action": "ModifyConfig",
133 "generic-vnf.vnf-id": "my-vnf"
138 An example initial response received from APPC on the same topic:
144 "TimeStamp": 1589400050923,
146 "RequestID": "c7c6a4aa-bb61-4a15-b831-ba1472dd4a65",
147 "SubRequestID": "ee3f2dc0-a2e0-4ae8-98c3-478c784b8eb5",
158 An example final response received from APPC on the same topic:
164 "TimeStamp": 1589400050934,
166 "RequestID": "c7c6a4aa-bb61-4a15-b831-ba1472dd4a65",
167 "SubRequestID": "ee3f2dc0-a2e0-4ae8-98c3-478c784b8eb5",
178 Configuration of the APPC Legacy Actor
179 ######################################
181 The following table specifies the fields that should be provided to configure the APPC
184 =============================== ==================== ==================================================================
185 Field name type Description
186 =============================== ==================== ==================================================================
187 sinkTopic string Name of the topic to which the request should be published.
188 sourceTopic string Name of the topic from which the response should be read.
189 timeoutSec integer (optional) Maximum time, in seconds, to wait for a response to be received
191 =============================== ==================== ==================================================================
193 The individual operations are configured using these same field names. However, all
194 of them are optional, as they inherit their values from the corresponding actor-level