-
Notifications
You must be signed in to change notification settings - Fork 17
/
pipeline-flow-ui-v3-schema.json
467 lines (467 loc) · 15.7 KB
/
pipeline-flow-ui-v3-schema.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
{
"$schema": "https://json-schema.org/draft-04/schema#",
"description": "WDP Pipeline Flow UI Schema. Defines UI-only constructs for pipeline flow documents.",
"type": "object",
"id": "https://api.dataplatform.ibm.com/schemas/common-pipeline/pipeline-flow/pipeline-flow-ui-v3-schema.json",
"properties": {},
"additionalProperties": true,
"definitions": {
"pipeline_overview_def": {
"description": "Top level UI information",
"type": "object",
"properties": {
"name": {
"description": "User-defined name",
"type": "string"
},
"description": {
"description": "User-defined description",
"type": "string"
},
"class_name": {
"description": "CSS class name",
"type": "string"
}
},
"additionalProperties": true
},
"pipeline_def": {
"description": "Pipeline level UI information",
"type": "object",
"properties": {
"description": {
"description": "User-defined description",
"type": "string"
},
"zoom": {
"oneOf": [
{
"description": "Deprecated - use zoom object instead. Scale factor as a percentage. 100% is standard scale amount. Smaller values zoom out. Larger values zoom in.",
"type": "integer",
"deprecated": true
},
{
"description": "A zoom object containing translation and scale amounts.",
"type": "object",
"properties": {
"x": {
"description": "Horizontal translation amount. Positive value moves right, negative to the left.",
"type": "number"
},
"y": {
"description": "Vertical translation amount. Positive value moves down, negative moves up.",
"type": "number"
},
"k": {
"description": "Scale amount. 1.0 is the standard scale amount. Smaller values zoom out. Larger values zoom in.",
"type": "number"
}
},
"required": [
"x",
"y",
"k"
],
"additionalProperties": false
}
]
},
"comments": {
"description": "Array of Comments, optionally associated with nodes",
"type": "array",
"minItems": 0,
"items": {
"$ref": "#/definitions/comment_def"
},
"uniqueItems": true
}
},
"additionalProperties": true
},
"port_info_def": {
"description": "Additional UI info for ports",
"type": "object",
"properties": {
"cardinality": {
"description": "Property to capture how many data assets are allowed for this port, e.g., min: 1, max:1 implies you must supply 1 and only 1; min:0, max:1 implies it is optional and a max of one, min:0, max:-1 means it is optional and you can may have any number of data assets. The default value is 1:1 for inputs and 1:-1 for outputs.",
"type": "object",
"properties": {
"min": {
"description": "Minimum data sets that are required for this port",
"type": "integer",
"default": 1
},
"max": {
"description": "Maximum data sets that are allowed on this port. A negative value indicates unlimited. The default value is 1 for inputs and -1 for outputs.",
"type": "integer"
}
},
"additionalProperties": false
},
"class_name": {
"description": "CSS class name",
"type": "string"
},
"style": {
"description": "A 'style spec' object containing CSS strings to be applied to the SVG objects of the port.",
"type": ["string", "object"]
},
"label": {
"description": "Port name",
"type": "string"
}
},
"additionalProperties": true
},
"node_info_def": {
"description": "object with app-specific UI-information",
"type": "object",
"properties": {
"label": {
"description": "User-defined label",
"type": "string"
},
"description": {
"description": "User-defined description",
"type": "string"
},
"class_name": {
"description": "CSS class name",
"type": "string"
},
"style": {
"description": "A 'style spec' object containing CSS strings to be applied to the SVG objects of the node.",
"type": ["string", "object"]
},
"image": {
"description": "URL to image source. Although a data URL can be used to embed an image inline, it is not recommended. The 'image' property can also be a JSX object that displays an image using an <svg> element however, JSX images must be set programmatically and cannot be stringified into JSON.",
"type": ["string", "object"]
},
"x_pos": {
"description": "x-position",
"type": "number"
},
"y_pos": {
"description": "y-position",
"type": "number"
},
"is_expanded": {
"description": "Indicates whether a supernode is shown in expanded state or as a regular node.",
"type": "boolean"
},
"expanded_height": {
"description": "Height of expanded supernode. If not provided an appropriate height is calculated.",
"type": "number"
},
"expanded_width": {
"description": "Width of expanded supernode. If not provided an appropriate width is calculated.",
"type": "number"
},
"is_resized": {
"description": "Indicates whether a node has been resized or not. If true, resize_width and resize_height are used for node display. If false, the default width and height are used.",
"type": "boolean"
},
"resize_height": {
"description": "Height of resized node. The node will be displayed with this height, when is_resized is true, in preference to its default height.",
"type": "number"
},
"resize_width": {
"description": "Width of resized node. The node will be displayed with this width, when is_resized is true, in preference to its default width.",
"type": "number"
},
"sub_pipelines": {
"description": "An array of pipelines referenced when this node is a supernode. This field is only used when the supernode is in a palette or on the clipboard. It will be an empty array when the supernode references an external pipeline.",
"type": "array",
"minItems": 0,
"items": {
"$ref": "https://api.dataplatform.ibm.com/schemas/common-pipeline/pipeline-flow/pipeline-flow-v3-schema.json#/definitions/pipeline_def"
},
"uniqueItems": true
},
"attributes": {
"description": "additional attributes",
"type": "string"
},
"associations": {
"description": "Array of non-data node linkage",
"type": "array",
"minItems": 0,
"items": {
"$ref": "#/definitions/association_def"
}
},
"messages": {
"description": "An array of messages for the node",
"type": "array",
"minItems": 0,
"items": {
"$ref": "#/definitions/message_def"
},
"uniqueItems": true
},
"ui_parameters": {
"description": "UI only parameter values for the node",
"type": "object",
"properties": {},
"additionalProperties": true
},
"palette_image": {
"description": "Image name for the node displayed in palette. If omitted the image from 'image' field will be used.",
"type": "string"
},
"palette_class_name": {
"description": "CSS class name applied to the <div> shown in palette for the node",
"type": "string"
},
"palette_disabled": {
"description": "Indicates whether the node in the palette is disabled. If true, prevents the node being dragged or double-clicked from palette.",
"type": "boolean"
},
"decorations": {
"description": "Array of decorations used to decorate nodes",
"type": "array",
"minItems": 0,
"items": {
"$ref": "#/definitions/decoration_def"
},
"uniqueItems": true
}
},
"additionalProperties": true
},
"node_link_info_def": {
"description": "object with app-specific UI-information",
"type": "object",
"properties": {
"description": {
"description": "User-defined description",
"type": "string"
},
"class_name": {
"description": "CSS class name",
"type": "string"
},
"style": {
"description": "A 'style spec' object containing CSS strings to be applied to the SVG objects of the node to node link.",
"type": ["string", "object"]
},
"decorations": {
"description": "Array of decorations used to decorate node links",
"type": "array",
"minItems": 0,
"items": {
"$ref": "#/definitions/decoration_def"
},
"uniqueItems": true
}
},
"additionalProperties": true
},
"runtime_info_def": {
"description": "Runtime information",
"type": "object",
"properties": {},
"additionalProperties": true
},
"association_def": {
"description": "Non-data link",
"type": "object",
"properties": {
"id": {
"description": "Association identifier",
"type": "string"
},
"node_ref": {
"description": "Target node id",
"type": "string"
},
"class_name": {
"description": "CSS class name for link styling",
"type": "string"
},
"style": {
"description": "A 'style spec' object containing CSS strings to be applied to the SVG objects of the association link.",
"type": ["string", "object"]
},
"decorations": {
"description": "Array of decorations used to decorate association links",
"type": "array",
"minItems": 0,
"items": {
"$ref": "#/definitions/decoration_def"
},
"uniqueItems": true
}
},
"required": [
"id",
"node_ref"
],
"additionalProperties": false
},
"decoration_def": {
"description": "Decoration used to decorate a node",
"type": "object",
"properties": {
"id": {
"description": "An identifier used to identify the decoration",
"type": "string"
},
"hotspot": {
"description": "Indicates whether the decorator is a hotspot or not. ie does it send an event to consuming app. when clicked",
"type": "boolean"
},
"class_name": {
"description": "CSS class name for decoration styling",
"type": "string"
},
"position": {
"description": "Indicates an anchor point on the node or link from which the decoration will be displayed. If x_pos and y_pos are not provided the decoration is displayed with a default offset from this position.",
"enum": [
"topLeft",
"topCenter",
"topRight",
"middleLeft",
"middleCenter",
"middleRight",
"bottomLeft",
"bottomCenter",
"bottomRight",
"source",
"middle",
"target"
]
},
"x_pos": {
"description": "X position of the decorator relative to the node's position field. If position is not provided it is relative to the 'topLeft' position",
"type": "integer"
},
"y_pos": {
"description": "Y position of the decorator relative to the node's position field. If position is not provided it is relative to the 'topLeft' position",
"type": "integer"
},
"image": {
"description": "Image displayed at the decoration position. Provide either this or a label.",
"type": "string"
},
"label": {
"description": "Label displayed at the decoration position. Provide either this or an image.",
"type": "string"
}
}
},
"message_def": {
"description": "Node message definition",
"type": "object",
"properties": {
"id_ref": {
"description": "Name of the parameter that has the message",
"type": "string"
},
"validation_id": {
"description": "Validation identifier from the fail_message validation section.",
"type": "string"
},
"type": {
"description": "Type of message",
"enum": [
"info",
"error",
"warning"
]
},
"text": {
"description": "Message string",
"type": "string"
}
},
"required": [
"id_ref",
"type",
"text"
]
},
"comment_def": {
"type": "object",
"properties": {
"id": {
"description": "Comment identifier. Must be unique.",
"type": "string"
},
"x_pos": {
"description": "Horizontal comment position",
"type": "number"
},
"y_pos": {
"description": "Vertical comment position",
"type": "number"
},
"width": {
"description": "Comment width",
"type": "number",
"minimum": 10
},
"height": {
"description": "Comment height",
"type": "number",
"minimum": 10
},
"class_name": {
"description": "CSS class(es) to apply to the comment",
"type": "string"
},
"style": {
"description": "A 'style spec' object containing CSS strings to be applied to the SVG objects of the comment.",
"type": ["string", "object"]
},
"attributes": {
"description": "Optional attributes to be added to this element. For example: \"attributes\": \"attr1='value1'; attr2='value2'\"",
"type": "string"
},
"content": {
"description": "Comment content",
"type": "string"
},
"associated_id_refs": {
"description": "Optional array of associated node id references",
"type": "array",
"minItems": 0,
"items": {
"$ref": "#/definitions/comment_link_def"
},
"uniqueItems": true
}
},
"required": [
"id",
"x_pos",
"y_pos",
"width",
"height"
],
"additionalProperties": true
},
"comment_link_def": {
"description": "Comment link definition",
"type": "object",
"properties": {
"node_ref": {
"description": "Node reference",
"type": "string"
},
"class_name": {
"description": "CSS class name for link styling",
"type": "string"
},
"style": {
"description": "A 'style spec' object containing CSS strings to be applied to the SVG objects of the comment link.",
"type": ["string", "object"]
}
},
"required": [
"node_ref"
],
"additionalProperties": true
}
}
}