Update DCAE Committer in INFO.yaml
[dcaegen2/platform/cli.git] / component-json-schemas / dcae-cli-v3-draft / dmaap-schema.json
1 {
2   "$id": "http://onap.org/dcaegen2/platform/dmaap",
3   "$schema": "http://json-schema.org/draft-07/schema#",
4   "title": "Schema for dmaap inputs",
5   "type": "object",
6
7   "oneOf": [
8     { "$ref": "#/definitions/message_router" },
9     { "$ref": "#/definitions/data_router" },
10     { "$ref": "#/definitions/kafka" }
11   ],
12
13   "definitions": {
14   
15     "message_router": {
16       "type": "object",
17       "properties": {
18         "type": {
19           "type": "string",
20           "enum": ["message_router"]
21         },
22         "aaf_credentials": {
23           "$ref": "#/definitions/aaf_credentials"
24         },
25         "aaf_username": {
26           "description": "Used for backward compatibility. Use aaf_credentials object in new code.",
27           "type": "string"
28         },
29         "aaf_password": {
30           "description": "Used for backward compatibility. Use aaf_credentials object in new code.",
31           "type": "string"
32         },
33         "dmaap_info": {
34           "$ref":"#/definitions/dmaap_info"
35         }
36       },
37       "required": [
38         "type",
39         "dmaap_info"
40       ],
41       "additionalProperties": false
42     },
43
44     "data_router": {
45       "type": "object",
46       "$comment": "This is currently not specified in schema. However, it is specified in RTD documentation. TODO: specify schema for DMaaP DR",     
47        "properties": {
48         "type": {
49           "type": "string",
50           "enum": ["data_router"]
51         }
52       },
53       "required": [
54         "type"
55       ],
56       "additionalProperties": true
57     },
58
59     "dmaap_info": {
60       "type": "object",
61       "properties": {
62         "client_role": {
63           "type": "string"
64         },
65         "client_id": {
66           "type": "string"
67         },
68         "location": {
69           "type": "string"
70         },
71         "topic_url": {
72           "type": "string"
73         }
74       },
75       "required": [
76         "topic_url"
77       ],
78       "additionalProperties": false
79     },
80
81     "kafka": {
82       "type": "object",
83       "properties": {
84         "type": {
85           "type": "string",
86           "enum": ["kafka"]
87         },
88         "aaf_credentials": {
89           "$ref": "#/definitions/aaf_credentials"
90         },
91         "kafka_info": {
92            "$ref": "#/definitions/kafka_info"
93         }
94       },
95       "required": [
96         "type",
97         "kafka_info"
98       ],
99       "additionalProperties": false
100     },
101
102     "kafka_info": {
103       "type": "object",
104       "description": "Defines Kafka-specific topid properties",
105       "properties": {
106         "client_role": {
107           "type": "string"
108         },
109         "client_id": {
110           "type": "string"
111         },
112         "bootstrap_servers": {
113           "description": "Comma separated list of Kafka bootstrap servers as defined in Kafka documentation",
114           "type": "string"
115         },
116         "topic_name": {
117           "description": "Name of the topic",
118           "type": "string"
119         },
120         "consumer_group_id": {
121           "description": "Can be specifed only for subscribers. More details in Kafka documentation on group.id property",
122           "type": "string"
123         },
124         "max_payload_size_bytes": {
125           "description": "Maximum payload size in bytes. Can be used for validation or creating Kafka client properties.",
126           "type": "string"
127         }
128       },
129       "required": [
130         "bootstrap_servers",
131         "topic_name"
132       ],
133       "additionalProperties": false
134     },
135
136     "aaf_credentials": {
137       "type": "object",
138       "properties": {
139         "username": {
140           "type": "string"
141         },
142         "password": {
143           "type": "string"
144         }
145       },
146       "additionalProperties": false
147     }
148   }
149 }