2 * Copyright © 2017-2018 AT&T Intellectual Property.
\r
3 * Modifications Copyright © 2018 IBM.
\r
5 * Licensed under the Apache License, Version 2.0 (the "License");
\r
6 * you may not use this file except in compliance with the License.
\r
7 * You may obtain a copy of the License at
\r
9 * http://www.apache.org/licenses/LICENSE-2.0
\r
11 * Unless required by applicable law or agreed to in writing, software
\r
12 * distributed under the License is distributed on an "AS IS" BASIS,
\r
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
\r
14 * See the License for the specific language governing permissions and
\r
15 * limitations under the License.
\r
18 package org.onap.ccsdk.apps.blueprintsprocessor.core.api.data
\r
20 import com.fasterxml.jackson.annotation.JsonFormat
\r
21 import com.fasterxml.jackson.databind.node.ObjectNode
\r
22 import io.swagger.annotations.ApiModelProperty
\r
26 * BlueprintProcessorData
\r
27 * @author Brinda Santh
\r
31 open class ExecutionServiceInput {
\r
32 @get:ApiModelProperty(required = true)
\r
33 lateinit var commonHeader: CommonHeader
\r
34 @get:ApiModelProperty(required = true)
\r
35 lateinit var actionIdentifiers: ActionIdentifiers
\r
36 @get:ApiModelProperty(required = true)
\r
37 lateinit var payload: ObjectNode
\r
40 open class ExecutionServiceOutput {
\r
41 @get:ApiModelProperty(required = true)
\r
42 lateinit var commonHeader: CommonHeader
\r
43 @get:ApiModelProperty(required = true)
\r
44 lateinit var actionIdentifiers: ActionIdentifiers
\r
45 @get:ApiModelProperty(required = true)
\r
46 var status: Status = Status()
\r
47 @get:ApiModelProperty(required = true)
\r
48 lateinit var payload: ObjectNode
\r
51 open class ActionIdentifiers {
\r
52 @get:ApiModelProperty(required = false)
\r
53 lateinit var blueprintName: String
\r
54 @get:ApiModelProperty(required = false)
\r
55 lateinit var blueprintVersion: String
\r
56 @get:ApiModelProperty(required = true)
\r
57 lateinit var actionName: String
\r
58 @get:ApiModelProperty(required = true, allowableValues = "sync, async")
\r
59 lateinit var mode: String
\r
62 open class CommonHeader {
\r
63 @get:ApiModelProperty(required = true, example = "2012-04-23T18:25:43.511Z")
\r
64 @get:JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd'T'HH:mm:ss.SSS'Z'")
\r
65 var timestamp: Date = Date()
\r
66 @get:ApiModelProperty(required = true)
\r
67 lateinit var originatorId: String
\r
68 @get:ApiModelProperty(required = true)
\r
69 lateinit var requestId: String
\r
70 @get:ApiModelProperty(required = true)
\r
71 lateinit var subRequestId: String
\r
72 @get:ApiModelProperty(required = false)
\r
73 var flags: Flags? = null
\r
77 var isForce: Boolean = false
\r
78 @get:ApiModelProperty(value = "3600")
\r
83 @get:ApiModelProperty(required = true)
\r
85 @get:ApiModelProperty(required = true)
\r
86 var eventType: String = "EVENT-ACTION-RESPONSE"
\r
87 @get:ApiModelProperty(required = true, example = "2012-04-23T18:25:43.511Z")
\r
88 @get:JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd'T'HH:mm:ss.SSS'Z'")
\r
89 var timestamp: Date = Date()
\r
90 @get:ApiModelProperty(required = false)
\r
91 var errorMessage: String? = null
\r
92 @get:ApiModelProperty(required = true)
\r
93 var message: String = "success"
\r