Skip to content

Commit e1d565a

Browse files
fix: restrict extra properties
Signed-off-by: Matthias Pichler <[email protected]>
1 parent 855b691 commit e1d565a

File tree

1 file changed

+39
-2
lines changed

1 file changed

+39
-2
lines changed

schema/workflow.yaml

Lines changed: 39 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ type: object
55
properties:
66
document:
77
type: object
8+
unevaluatedProperties: false
89
properties:
910
dsl:
1011
type: string
@@ -39,6 +40,7 @@ properties:
3940
description: Configures the workflow's input.
4041
use:
4142
type: object
43+
unevaluatedProperties: false
4244
properties:
4345
authentications:
4446
type: object
@@ -87,6 +89,7 @@ properties:
8789
description: Configures the workflow's output.
8890
schedule:
8991
type: object
92+
unevaluatedProperties: false
9093
properties:
9194
every:
9295
$ref: '#/$defs/duration'
@@ -324,6 +327,7 @@ $defs:
324327
properties:
325328
fork:
326329
type: object
330+
unevaluatedProperties: false
327331
required: [ branches ]
328332
properties:
329333
branches:
@@ -352,6 +356,7 @@ $defs:
352356
properties:
353357
emit:
354358
type: object
359+
unevaluatedProperties: false
355360
properties:
356361
event:
357362
type: object
@@ -390,6 +395,7 @@ $defs:
390395
properties:
391396
for:
392397
type: object
398+
unevaluatedProperties: false
393399
properties:
394400
each:
395401
type: string
@@ -418,6 +424,7 @@ $defs:
418424
properties:
419425
listen:
420426
type: object
427+
unevaluatedProperties: false
421428
properties:
422429
to:
423430
$ref: '#/$defs/eventConsumptionStrategy'
@@ -433,6 +440,7 @@ $defs:
433440
properties:
434441
raise:
435442
type: object
443+
unevaluatedProperties: false
436444
properties:
437445
error:
438446
$ref: '#/$defs/error'
@@ -453,6 +461,7 @@ $defs:
453461
properties:
454462
container:
455463
type: object
464+
unevaluatedProperties: false
456465
properties:
457466
image:
458467
type: string
@@ -477,6 +486,7 @@ $defs:
477486
properties:
478487
script:
479488
type: object
489+
unevaluatedProperties: false
480490
properties:
481491
language:
482492
type: string
@@ -506,6 +516,7 @@ $defs:
506516
properties:
507517
shell:
508518
type: object
519+
unevaluatedProperties: false
509520
properties:
510521
command:
511522
type: string
@@ -528,6 +539,7 @@ $defs:
528539
workflow:
529540
title: RunWorkflowDescriptor
530541
type: object
542+
unevaluatedProperties: false
531543
properties:
532544
namespace:
533545
type: string
@@ -579,8 +591,8 @@ $defs:
579591
additionalProperties:
580592
type: object
581593
title: SwitchCase
582-
required:
583-
- then
594+
unevaluatedProperties: false
595+
required: [ then ]
584596
properties:
585597
when:
586598
type: string
@@ -601,6 +613,7 @@ $defs:
601613
$ref: '#/$defs/taskList'
602614
catch:
603615
type: object
616+
unevaluatedProperties: false
604617
properties:
605618
errors:
606619
title: CatchErrors
@@ -639,6 +652,7 @@ $defs:
639652
- type: string
640653
referenceableAuthenticationPolicy:
641654
type: object
655+
unevaluatedProperties: false
642656
oneOf:
643657
- title: AuthenticationPolicyReference
644658
properties:
@@ -650,6 +664,7 @@ $defs:
650664
- $ref: '#/$defs/authenticationPolicy'
651665
secretBasedAuthenticationPolicy:
652666
type: object
667+
unevaluatedProperties: false
653668
properties:
654669
use:
655670
type: string
@@ -663,6 +678,7 @@ $defs:
663678
properties:
664679
basic:
665680
type: object
681+
unevaluatedProperties: false
666682
oneOf:
667683
- properties:
668684
username:
@@ -679,6 +695,7 @@ $defs:
679695
properties:
680696
bearer:
681697
type: object
698+
unevaluatedProperties: false
682699
oneOf:
683700
- properties:
684701
token:
@@ -692,6 +709,7 @@ $defs:
692709
properties:
693710
oauth2:
694711
type: object
712+
unevaluatedProperties: false
695713
oneOf:
696714
- properties:
697715
authority:
@@ -703,6 +721,7 @@ $defs:
703721
description: The grant type to use.
704722
client:
705723
type: object
724+
unevaluatedProperties: false
706725
properties:
707726
id:
708727
type: string
@@ -740,6 +759,7 @@ $defs:
740759
description: Defines an authentication policy.
741760
oauth2Token:
742761
type: object
762+
unevaluatedProperties: false
743763
properties:
744764
token:
745765
type: string
@@ -751,6 +771,7 @@ $defs:
751771
duration:
752772
type: object
753773
minProperties: 1
774+
unevaluatedProperties: false
754775
properties:
755776
days:
756777
type: integer
@@ -770,6 +791,7 @@ $defs:
770791
description: The definition of a duration.
771792
error:
772793
type: object
794+
unevaluatedProperties: false
773795
properties:
774796
type:
775797
type: string
@@ -791,6 +813,7 @@ $defs:
791813
required: [ type, status, instance ]
792814
endpoint:
793815
type: object
816+
unevaluatedProperties: false
794817
properties:
795818
uri:
796819
type: string
@@ -802,6 +825,7 @@ $defs:
802825
required: [ uri ]
803826
eventConsumptionStrategy:
804827
type: object
828+
unevaluatedProperties: false
805829
oneOf:
806830
- title: AllEventConsumptionStrategy
807831
properties:
@@ -827,6 +851,7 @@ $defs:
827851
required: [ one ]
828852
eventFilter:
829853
type: object
854+
unevaluatedProperties: false
830855
properties:
831856
with:
832857
title: WithEvent
@@ -870,6 +895,7 @@ $defs:
870895
description: An event filter is a mechanism used to selectively process or handle events based on predefined criteria, such as event type, source, or specific attributes.
871896
extension:
872897
type: object
898+
unevaluatedProperties: false
873899
properties:
874900
extend:
875901
type: string
@@ -892,6 +918,7 @@ $defs:
892918
format: uri
893919
- title: ExternalResourceURI
894920
type: object
921+
unevaluatedProperties: false
895922
properties:
896923
uri:
897924
type: string
@@ -906,6 +933,7 @@ $defs:
906933
required: [ uri ]
907934
input:
908935
type: object
936+
unevaluatedProperties: false
909937
properties:
910938
schema:
911939
$ref: '#/$defs/schema'
@@ -918,6 +946,7 @@ $defs:
918946
description: Configures the input of a workflow or task.
919947
output:
920948
type: object
949+
unevaluatedProperties: false
921950
properties:
922951
schema:
923952
$ref: '#/$defs/schema'
@@ -930,6 +959,7 @@ $defs:
930959
description: Configures the output of a workflow or task.
931960
export:
932961
type: object
962+
unevaluatedProperties: false
933963
properties:
934964
schema:
935965
$ref: '#/$defs/schema'
@@ -942,6 +972,7 @@ $defs:
942972
description: Set the content of the context.
943973
retryPolicy:
944974
type: object
975+
unevaluatedProperties: false
945976
properties:
946977
when:
947978
type: string
@@ -954,6 +985,7 @@ $defs:
954985
description: The duration to wait between retry attempts.
955986
backoff:
956987
type: object
988+
unevaluatedProperties: false
957989
oneOf:
958990
- title: ConstantBackoff
959991
properties:
@@ -976,9 +1008,11 @@ $defs:
9761008
description: The retry duration backoff.
9771009
limit:
9781010
type: object
1011+
unevaluatedProperties: false
9791012
properties:
9801013
attempt:
9811014
type: object
1015+
unevaluatedProperties: false
9821016
properties:
9831017
count:
9841018
type: integer
@@ -992,6 +1026,7 @@ $defs:
9921026
description: The retry limit, if any
9931027
jitter:
9941028
type: object
1029+
unevaluatedProperties: false
9951030
properties:
9961031
from:
9971032
$ref: '#/$defs/duration'
@@ -1004,6 +1039,7 @@ $defs:
10041039
description: Defines a retry policy.
10051040
schema:
10061041
type: object
1042+
unevaluatedProperties: false
10071043
properties:
10081044
format:
10091045
type: string
@@ -1024,6 +1060,7 @@ $defs:
10241060
description: Represents the definition of a schema.
10251061
timeout:
10261062
type: object
1063+
unevaluatedProperties: false
10271064
properties:
10281065
after:
10291066
$ref: '#/$defs/duration'

0 commit comments

Comments
 (0)