bpmnlint-plugin-camunda-compat 0.6.0 → 0.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,245 +0,0 @@
1
- const {
2
- checkEventDefinition,
3
- checkFlowNode,
4
- checkIf,
5
- hasErrorReference,
6
- hasEventDefinitionOfType,
7
- hasEventDefinitionOfTypeOrNone,
8
- hasMessageReference,
9
- hasNoLanes,
10
- isNotBpmn,
11
- withTranslations
12
- } = require('./utils/element');
13
-
14
- const {
15
- hasZeebeCalledElement,
16
- hasZeebeLoopCharacteristics,
17
- hasZeebeSubscription,
18
- hasZeebeTaskDefinition
19
- } = require('./utils/cloud/element');
20
-
21
- const { checkEvery } = require('./utils/rule');
22
-
23
- module.exports = [
24
- {
25
- check: isNotBpmn
26
- },
27
- 'bpmn:Association',
28
- 'bpmn:Collaboration',
29
- 'bpmn:DataObject',
30
- 'bpmn:DataObjectReference',
31
- 'bpmn:DataStoreReference',
32
- 'bpmn:Definitions',
33
- 'bpmn:EventBasedGateway',
34
- 'bpmn:ExclusiveGateway',
35
- 'bpmn:Group',
36
- 'bpmn:MessageFlow',
37
- 'bpmn:ParallelGateway',
38
- 'bpmn:Participant',
39
- 'bpmn:SequenceFlow',
40
- 'bpmn:TextAnnotation',
41
- {
42
- type: 'bpmn:BoundaryEvent',
43
- check: withTranslations(
44
- checkEvery(
45
- hasEventDefinitionOfType([
46
- 'bpmn:ErrorEventDefinition',
47
- 'bpmn:MessageEventDefinition',
48
- 'bpmn:TimerEventDefinition'
49
- ]),
50
- checkIf(
51
- checkEventDefinition(hasErrorReference),
52
- hasEventDefinitionOfType('bpmn:ErrorEventDefinition')
53
- ),
54
- checkIf(
55
- checkEvery(
56
- checkEventDefinition(hasMessageReference),
57
- checkIf(
58
- checkEventDefinition(hasZeebeSubscription),
59
- checkEventDefinition(hasMessageReference)
60
- )
61
- ),
62
- hasEventDefinitionOfType('bpmn:MessageEventDefinition')
63
- )
64
- ),
65
- {
66
- 'Element of type <bpmn:BoundaryEvent> not supported by {{ executionPlatform }}': 'An <Undefined Boundary Event> is not supported by {{ executionPlatform }}',
67
- 'Element of type <bpmn:ErrorEventDefinition> must have property <errorRef>': 'An <Error Boundary Event> must have a defined <Error Reference>',
68
- 'Element of type <bpmn:Error> must have property <errorCode>': 'An <Error Boundary Event> with <Error Reference> must have a defined <Error code>',
69
- 'Element of type <bpmn:MessageEventDefinition> must have property <messageRef>': 'A <Message Boundary Event> must have a defined <Message Reference>',
70
- 'Element of type <bpmn:Message> must have property <name>': 'A <Message Boundary Event> with <Message Reference> must have a defined <Name>',
71
- 'Element of type <bpmn:Message> must have extension element of type <zeebe:Subscription>': 'A <Message Boundary Event> with <Message Reference> must have a defined <Subscription correlation key>',
72
- 'Element of type <zeebe:Subscription> must have property <correlationKey>': 'A <Message Boundary Event> with <Message Reference> must have a defined <Subscription correlation key>'
73
- }
74
- )
75
- },
76
- {
77
- type: 'bpmn:CallActivity',
78
- check: withTranslations(
79
- checkEvery(
80
- hasZeebeCalledElement,
81
- hasZeebeLoopCharacteristics
82
- ),
83
- {
84
- 'Element of type <bpmn:CallActivity> must have extension element of type <zeebe:CalledElement>': 'A <Call Activity> must have a defined <Called element>',
85
- 'Element of type <zeebe:CalledElement> must have property <processId>': 'A <Call Activity> must have a defined <Called element>',
86
- 'Element of type <bpmn:MultiInstanceLoopCharacteristics> must have extension element of type <zeebe:LoopCharacteristics>': 'A <Call Activity> with <Multi-instance marker> must have a defined <Input collection>',
87
- 'Element of type <zeebe:LoopCharacteristics> must have property <inputCollection>': 'A <Call Activity> with <Multi-instance marker> must have a defined <Input collection>',
88
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputElement> if it has property <outputCollection>': 'A <Call Activity> with <Multi-instance marker> and defined <Output collection> must have a defined <Output element>',
89
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputCollection> if it has property <outputElement>': 'A <Call Activity> with <Multi-instance marker> and defined <Output element> must have a defined <Output collection>'
90
- }
91
- )
92
- },
93
- {
94
- type: 'bpmn:EndEvent',
95
- check: withTranslations(
96
- checkEvery(
97
- hasEventDefinitionOfTypeOrNone('bpmn:ErrorEventDefinition'),
98
- checkIf(
99
- checkEventDefinition(hasErrorReference),
100
- hasEventDefinitionOfType('bpmn:ErrorEventDefinition')
101
- )
102
- ),
103
- {
104
- 'Element of type <bpmn:EndEvent> (<bpmn:MessageEventDefinition>) not supported by {{ executionPlatform }}': 'A <Message End Event> is not supported by {{ executionPlatform }}',
105
- 'Element of type <bpmn:ErrorEventDefinition> must have property <errorRef>': 'An <Error End Event> must have a defined <Error Reference>',
106
- 'Element of type <bpmn:Error> must have property <errorCode>': 'An <Error End Event> with <Error Reference> must have a defined <Error code>'
107
- }
108
- )
109
- },
110
- {
111
- type: 'bpmn:IntermediateCatchEvent',
112
- check: withTranslations(
113
- checkEvery(
114
- hasEventDefinitionOfType([
115
- 'bpmn:TimerEventDefinition',
116
- 'bpmn:MessageEventDefinition'
117
- ]),
118
- checkIf(
119
- checkEvery(
120
- checkEventDefinition(hasMessageReference),
121
- checkIf(
122
- checkEventDefinition(hasZeebeSubscription),
123
- checkEventDefinition(hasMessageReference)
124
- )
125
- ),
126
- hasEventDefinitionOfType('bpmn:MessageEventDefinition')
127
- )
128
- ),
129
- {
130
- 'Element of type <bpmn:IntermediateCatchEvent> not supported by {{ executionPlatform }}': 'A <Undefined Intermediate Catch Event> is not supported by {{ executionPlatform }}',
131
- 'Element of type <bpmn:MessageEventDefinition> must have property <messageRef>': 'A <Message Intermediate Catch Event> must have a defined <Message Reference>',
132
- 'Element of type <bpmn:Message> must have property <name>': 'A <Message Intermediate Catch Event> with <Message Reference> must have a defined <Name>',
133
- 'Element of type <bpmn:Message> must have extension element of type <zeebe:Subscription>': 'A <Message Intermediate Catch Event> with <Message Reference> must have a defined <Subscription correlation key>',
134
- 'Element of type <zeebe:Subscription> must have property <correlationKey>': 'A <Message Intermediate Catch Event> with <Message Reference> must have a defined <Subscription correlation key>'
135
- }
136
- )
137
- },
138
- {
139
- type: 'bpmn:Process',
140
- check: withTranslations(
141
- hasNoLanes,
142
- {
143
- 'Element of type <bpmn:Process> (<bpmn:LaneSet>) not supported by {{ executionPlatform }}': 'A <Lane> is not supported by Camunda Platform 8 (Zeebe 1.0)'
144
- }
145
- )
146
- },
147
- {
148
- type: 'bpmn:ReceiveTask',
149
- check: withTranslations(
150
- checkEvery(
151
- checkFlowNode(hasMessageReference),
152
- checkIf(
153
- checkFlowNode(hasZeebeSubscription),
154
- checkFlowNode(hasMessageReference)
155
- ),
156
- hasZeebeLoopCharacteristics
157
- ),
158
- {
159
- 'Element of type <bpmn:MultiInstanceLoopCharacteristics> must have extension element of type <zeebe:LoopCharacteristics>': 'A <Receive Task> with <Multi-instance marker> must have a defined <Input collection>',
160
- 'Element of type <zeebe:LoopCharacteristics> must have property <inputCollection>': 'A <Receive Task> with <Multi-instance marker> must have a defined <Input collection>',
161
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputElement> if it has property <outputCollection>': 'A <Receive Task> with <Multi-instance marker> and defined <Output collection> must have a defined <Output element>',
162
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputCollection> if it has property <outputElement>': 'A <Receive Task> with <Multi-instance marker> and defined <Output element> must have a defined <Output collection>',
163
- 'Element of type <bpmn:ReceiveTask> must have property <messageRef>': 'A <Receive Task> must have a defined <Message Reference>',
164
- 'Element of type <bpmn:Message> must have property <name>': 'A <Receive Task> with <Message Reference> must have a defined <Name>',
165
- 'Element of type <bpmn:Message> must have extension element of type <zeebe:Subscription>': 'A <Receive Task> with <Message Reference> must have a defined <Subscription correlation key>',
166
- 'Element of type <zeebe:Subscription> must have property <correlationKey>': 'A <Receive Task> with <Message Reference> must have a defined <Subscription correlation key>'
167
- }
168
- )
169
- },
170
- {
171
- type: 'bpmn:ServiceTask',
172
- check: withTranslations(
173
- checkEvery(
174
- hasZeebeLoopCharacteristics,
175
- hasZeebeTaskDefinition
176
- ),
177
- {
178
- 'Element of type <bpmn:ServiceTask> must have extension element of type <zeebe:TaskDefinition>': 'A <Service Task> must have a <Task definition type>',
179
- 'Element of type <zeebe:TaskDefinition> must have property <type>': 'A <Service Task> must have a <Task definition type>',
180
- 'Element of type <bpmn:MultiInstanceLoopCharacteristics> must have extension element of type <zeebe:LoopCharacteristics>': 'A <Service Task> with <Multi-instance marker> must have a defined <Input collection>',
181
- 'Element of type <zeebe:LoopCharacteristics> must have property <inputCollection>': 'A <Service Task> with <Multi-instance marker> must have a defined <Input collection>',
182
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputElement> if it has property <outputCollection>': 'A <Service Task> with <Multi-instance marker> and defined <Output collection> must have a defined <Output element>',
183
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputCollection> if it has property <outputElement>': 'A <Service Task> with <Multi-instance marker> and defined <Output element> must have a defined <Output collection>'
184
- }
185
- )
186
- },
187
- {
188
- type: 'bpmn:StartEvent',
189
- check: withTranslations(
190
- checkEvery(
191
- hasEventDefinitionOfTypeOrNone([
192
- 'bpmn:ErrorEventDefinition',
193
- 'bpmn:MessageEventDefinition',
194
- 'bpmn:TimerEventDefinition'
195
- ]),
196
- checkIf(
197
- checkEventDefinition(hasErrorReference),
198
- hasEventDefinitionOfType('bpmn:ErrorEventDefinition')
199
- ),
200
- checkIf(
201
- checkEvery(
202
- checkEventDefinition(hasMessageReference),
203
- checkIf(
204
- checkEventDefinition(hasZeebeSubscription),
205
- checkEventDefinition(hasMessageReference)
206
- )
207
- ),
208
- hasEventDefinitionOfType('bpmn:MessageEventDefinition')
209
- )
210
- ),
211
- {
212
- 'Element of type <bpmn:ErrorEventDefinition> must have property <errorRef>': 'An <Error Start Event> must have a defined <Error Reference>',
213
- 'Element of type <bpmn:Error> must have property <errorCode>': 'An <Error Start Event> with <Error Reference> must have a defined <Error code>',
214
- 'Element of type <bpmn:MessageEventDefinition> must have property <messageRef>': 'A <Message Start Event> must have a defined <Message Reference>',
215
- 'Element of type <bpmn:Message> must have property <name>': 'A <Message Start Event> with <Message Reference> must have a defined <Name>',
216
- 'Element of type <bpmn:Message> must have extension element of type <zeebe:Subscription>': 'A <Message Start Event> with <Message Reference> must have a defined <Subscription correlation key>',
217
- 'Element of type <zeebe:Subscription> must have property <correlationKey>': 'A <Message Start Event> with <Message Reference> must have a defined <Subscription correlation key>'
218
- }
219
- )
220
- },
221
- {
222
- type: 'bpmn:SubProcess',
223
- check: withTranslations(
224
- hasZeebeLoopCharacteristics,
225
- {
226
- 'Element of type <bpmn:MultiInstanceLoopCharacteristics> must have extension element of type <zeebe:LoopCharacteristics>': 'A <Sub Process> with <Multi-instance marker> must have a defined <Input collection>',
227
- 'Element of type <zeebe:LoopCharacteristics> must have property <inputCollection>': 'A <Sub Process> with <Multi-instance marker> must have a defined <Input collection>',
228
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputElement> if it has property <outputCollection>': 'A <Sub Process> with <Multi-instance marker> and defined <Output collection> must have a defined <Output element>',
229
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputCollection> if it has property <outputElement>': 'A <Sub Process> with <Multi-instance marker> and defined <Output element> must have a defined <Output collection>'
230
- }
231
- )
232
- },
233
- {
234
- type: 'bpmn:UserTask',
235
- check: withTranslations(
236
- hasZeebeLoopCharacteristics,
237
- {
238
- 'Element of type <bpmn:MultiInstanceLoopCharacteristics> must have extension element of type <zeebe:LoopCharacteristics>': 'A <User Task> with <Multi-instance marker> must have a defined <Input collection>',
239
- 'Element of type <zeebe:LoopCharacteristics> must have property <inputCollection>': 'A <User Task> with <Multi-instance marker> must have a defined <Input collection>',
240
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputElement> if it has property <outputCollection>': 'A <User Task> with <Multi-instance marker> and defined <Output collection> must have a defined <Output element>',
241
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputCollection> if it has property <outputElement>': 'A <User Task> with <Multi-instance marker> and defined <Output element> must have a defined <Output collection>'
242
- }
243
- )
244
- }
245
- ];
@@ -1,5 +0,0 @@
1
- const { createRule } = require('./utils/rule');
2
-
3
- const checks = require('./camunda-cloud-1-0-checks');
4
-
5
- module.exports = createRule('Camunda Cloud', '1.0', checks, 'Camunda Platform 8 (Zeebe 1.0)');
@@ -1,89 +0,0 @@
1
- const camundaCloud10Checks = require('./camunda-cloud-1-0-checks');
2
-
3
- const { checkEvery } = require('./utils/rule');
4
-
5
- const {
6
- hasNoEventDefinition,
7
- withTranslations
8
- } = require('./utils/element');
9
-
10
- const {
11
- hasZeebeTaskDefinition,
12
- hasZeebeLoopCharacteristics
13
- } = require('./utils/cloud/element');
14
-
15
- module.exports = [
16
- ...camundaCloud10Checks,
17
- {
18
- type: 'bpmn:BusinessRuleTask',
19
- check: withTranslations(
20
- checkEvery(
21
- hasZeebeLoopCharacteristics,
22
- hasZeebeTaskDefinition
23
- ),
24
- {
25
- 'Element of type <bpmn:BusinessRuleTask> must have extension element of type <zeebe:TaskDefinition>': 'A <Business Rule Task> must have a <Task definition type>',
26
- 'Element of type <zeebe:TaskDefinition> must have property <type>': 'A <Business Rule Task> must have a <Task definition type>',
27
- 'Element of type <bpmn:MultiInstanceLoopCharacteristics> must have extension element of type <zeebe:LoopCharacteristics>': 'A <Business Rule Task> with <Multi-instance marker> must have a defined <Input collection>',
28
- 'Element of type <zeebe:LoopCharacteristics> must have property <inputCollection>': 'A <Business Rule Task> with <Multi-instance marker> must have a defined <Input collection>',
29
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputElement> if it has property <outputCollection>': 'A <Business Rule Task> with <Multi-instance marker> and defined <Output collection> must have a defined <Output element>',
30
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputCollection> if it has property <outputElement>': 'A <Business Rule Task> with <Multi-instance marker> and defined <Output element> must have a defined <Output collection>'
31
- }
32
- )
33
- },
34
- {
35
- type: 'bpmn:IntermediateThrowEvent',
36
- check: withTranslations(
37
- hasNoEventDefinition,
38
- {
39
- 'Element of type <bpmn:IntermediateThrowEvent> (<bpmn:MessageEventDefinition>) not supported by {{ executionPlatform }}': 'A <Message Intermediate Throw Event> is not supported by {{ executionPlatform }}'
40
- }
41
- )
42
- },
43
- {
44
- type: 'bpmn:ManualTask',
45
- check: withTranslations(
46
- hasZeebeLoopCharacteristics,
47
- {
48
- 'Element of type <bpmn:MultiInstanceLoopCharacteristics> must have extension element of type <zeebe:LoopCharacteristics>': 'A <Manual Task> with <Multi-instance marker> must have a defined <Input collection>',
49
- 'Element of type <zeebe:LoopCharacteristics> must have property <inputCollection>': 'A <Manual Task> with <Multi-instance marker> must have a defined <Input collection>',
50
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputElement> if it has property <outputCollection>': 'A <Manual Task> with <Multi-instance marker> and defined <Output collection> must have a defined <Output element>',
51
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputCollection> if it has property <outputElement>': 'A <Manual Task> with <Multi-instance marker> and defined <Output element> must have a defined <Output collection>'
52
- }
53
- )
54
- },
55
- {
56
- type: 'bpmn:ScriptTask',
57
- check: withTranslations(
58
- checkEvery(
59
- hasZeebeLoopCharacteristics,
60
- hasZeebeTaskDefinition
61
- ),
62
- {
63
- 'Element of type <bpmn:ScriptTask> must have extension element of type <zeebe:TaskDefinition>': 'A <Script Task> must have a <Task definition type>',
64
- 'Element of type <zeebe:TaskDefinition> must have property <type>': 'A <Script Task> must have a <Task definition type>',
65
- 'Element of type <bpmn:MultiInstanceLoopCharacteristics> must have extension element of type <zeebe:LoopCharacteristics>': 'A <Script Task> with <Multi-instance marker> must have a defined <Input collection>',
66
- 'Element of type <zeebe:LoopCharacteristics> must have property <inputCollection>': 'A <Script Task> with <Multi-instance marker> must have a defined <Input collection>',
67
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputElement> if it has property <outputCollection>': 'A <Script Task> with <Multi-instance marker> and defined <Output collection> must have a defined <Output element>',
68
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputCollection> if it has property <outputElement>': 'A <Script Task> with <Multi-instance marker> and defined <Output element> must have a defined <Output collection>'
69
- }
70
- )
71
- },
72
- {
73
- type: 'bpmn:SendTask',
74
- check: withTranslations(
75
- checkEvery(
76
- hasZeebeLoopCharacteristics,
77
- hasZeebeTaskDefinition
78
- ),
79
- {
80
- 'Element of type <bpmn:SendTask> must have extension element of type <zeebe:TaskDefinition>': 'A <Send Task> must have a <Task definition type>',
81
- 'Element of type <zeebe:TaskDefinition> must have property <type>': 'A <Send Task> must have a <Task definition type>',
82
- 'Element of type <bpmn:MultiInstanceLoopCharacteristics> must have extension element of type <zeebe:LoopCharacteristics>': 'A <Send Task> with <Multi-instance marker> must have a defined <Input collection>',
83
- 'Element of type <zeebe:LoopCharacteristics> must have property <inputCollection>': 'A <Send Task> with <Multi-instance marker> must have a defined <Input collection>',
84
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputElement> if it has property <outputCollection>': 'A <Send Task> with <Multi-instance marker> and defined <Output collection> must have a defined <Output element>',
85
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputCollection> if it has property <outputElement>': 'A <Send Task> with <Multi-instance marker> and defined <Output element> must have a defined <Output collection>'
86
- }
87
- )
88
- }
89
- ];
@@ -1,5 +0,0 @@
1
- const { createRule } = require('./utils/rule');
2
-
3
- const checks = require('./camunda-cloud-1-1-checks');
4
-
5
- module.exports = createRule('Camunda Cloud', '1.1', checks, 'Camunda Platform 8 (Zeebe 1.1)');
@@ -1,60 +0,0 @@
1
- const camundaCloud11Checks = require('./camunda-cloud-1-1-checks');
2
-
3
- const {
4
- checkEvery,
5
- replaceChecks
6
- } = require('./utils/rule');
7
-
8
- const {
9
- checkEventDefinition,
10
- checkIf,
11
- hasErrorReference,
12
- hasEventDefinitionOfType,
13
- hasEventDefinitionOfTypeOrNone,
14
- withTranslations
15
- } = require('./utils/element');
16
-
17
- const { hasZeebeTaskDefinition } = require('./utils/cloud/element');
18
-
19
- module.exports = [
20
- ...replaceChecks(
21
- camundaCloud11Checks,
22
- [
23
- {
24
- type: 'bpmn:IntermediateThrowEvent',
25
- check: withTranslations(
26
- checkEvery(
27
- hasEventDefinitionOfTypeOrNone('bpmn:MessageEventDefinition'),
28
- checkIf(
29
- hasZeebeTaskDefinition,
30
- hasEventDefinitionOfType('bpmn:MessageEventDefinition')
31
- )
32
- ),
33
- {
34
- 'Element of type <bpmn:IntermediateThrowEvent> must have extension element of type <zeebe:TaskDefinition>': 'An <Intermediate Throw Event> must have a <Task definition type>',
35
- 'Element of type <zeebe:TaskDefinition> must have property <type>': 'An <Intermediate Throw Event> must have a <Task definition type>'
36
- }
37
- )
38
- },
39
- {
40
- type: 'bpmn:EndEvent',
41
- check: withTranslations(
42
- checkEvery(
43
- hasEventDefinitionOfTypeOrNone([
44
- 'bpmn:ErrorEventDefinition',
45
- 'bpmn:MessageEventDefinition'
46
- ]),
47
- checkIf(
48
- checkEventDefinition(hasErrorReference),
49
- hasEventDefinitionOfType('bpmn:ErrorEventDefinition')
50
- )
51
- ),
52
- {
53
- 'Element of type <bpmn:ErrorEventDefinition> must have property <errorRef>': 'An <Error End Event> must have a defined <Error Reference>',
54
- 'Element of type <bpmn:Error> must have property <errorCode>': 'An <Error End Event> with <Error Reference> must have a defined <Error code>'
55
- }
56
- )
57
- }
58
- ]
59
- )
60
- ];
@@ -1,5 +0,0 @@
1
- const { createRule } = require('./utils/rule');
2
-
3
- const checks = require('./camunda-cloud-1-2-checks');
4
-
5
- module.exports = createRule('Camunda Cloud', '1.2', checks, 'Camunda Platform 8 (Zeebe 1.2)');
@@ -1,37 +0,0 @@
1
- const camundaCloud12Checks = require('./camunda-cloud-1-2-checks');
2
-
3
- const {
4
- checkEvery,
5
- replaceCheck
6
- } = require('./utils/rule');
7
-
8
- const { withTranslations } = require('./utils/element');
9
-
10
- const {
11
- hasZeebeCalledDecisionOrTaskDefinition,
12
- hasZeebeLoopCharacteristics
13
- } = require('./utils/cloud/element');
14
-
15
- module.exports = [
16
- ...replaceCheck(
17
- camundaCloud12Checks,
18
- 'bpmn:BusinessRuleTask',
19
- withTranslations(
20
- checkEvery(
21
- hasZeebeCalledDecisionOrTaskDefinition,
22
- hasZeebeLoopCharacteristics
23
- ),
24
- {
25
- 'Element of type <bpmn:BusinessRuleTask> must have one extension element of type <zeebe:CalledDecision> or <zeebe:TaskDefinition>': 'A <Business Rule Task> must have a defined <Implementation>',
26
- 'Element of type <bpmn:BusinessRuleTask> must have one or many extension elements of type <zeebe:CalledDecision> or <zeebe:TaskDefinition>': 'A <Business Rule Task> must have a defined <Implementation>',
27
- 'Element of type <zeebe:TaskDefinition> must have property <type>': 'A <Business Rule Task> with <Implementation: Job worker> must have a defined <Task definition type>',
28
- 'Element of type <zeebe:CalledDecision> must have property <decisionId>': 'A <Business Rule Task> with <Implementation: DMN decision> must have a defined <Called decision ID>',
29
- 'Element of type <zeebe:CalledDecision> must have property <resultVariable>': 'A Business Rule Task with <Implementation: DMN decision> must have a defined <Result variable>',
30
- 'Element of type <bpmn:MultiInstanceLoopCharacteristics> must have extension element of type <zeebe:LoopCharacteristics>': 'A <Business Rule Task> with <Multi-instance marker> must have a defined <Input collection>',
31
- 'Element of type <zeebe:LoopCharacteristics> must have property <inputCollection>': 'A <Business Rule Task> with <Multi-instance marker> must have a defined <Input collection>',
32
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputElement> if it has property <outputCollection>': 'A <Business Rule Task> with <Multi-instance marker> and defined <Output collection> must have a defined <Output element>',
33
- 'Element of type <zeebe:LoopCharacteristics> must have property <outputCollection> if it has property <outputElement>': 'A <Business Rule Task> with <Multi-instance marker> and defined <Output element> must have a defined <Output collection>'
34
- }
35
- )
36
- )
37
- ];
@@ -1,5 +0,0 @@
1
- const { createRule } = require('./utils/rule');
2
-
3
- const checks = require('./camunda-cloud-1-3-checks');
4
-
5
- module.exports = createRule('Camunda Cloud', '1.3', checks, 'Camunda Platform 8 (Zeebe 1.3)');
@@ -1,5 +0,0 @@
1
- const camundaCloud13Checks = require('./camunda-cloud-1-3-checks');
2
-
3
- module.exports = [
4
- ...camundaCloud13Checks
5
- ];
@@ -1,5 +0,0 @@
1
- const { createRule } = require('./utils/rule');
2
-
3
- const checks = require('./camunda-cloud-8-0-checks');
4
-
5
- module.exports = createRule('Camunda Cloud', '8.0', checks, 'Camunda Platform 8');
@@ -1,3 +0,0 @@
1
- const { createNoopRule } = require('./utils/rule');
2
-
3
- module.exports = createNoopRule();
@@ -1,3 +0,0 @@
1
- const { createNoopRule } = require('./utils/rule');
2
-
3
- module.exports = createNoopRule();
@@ -1,3 +0,0 @@
1
- const { createNoopRule } = require('./utils/rule');
2
-
3
- module.exports = createNoopRule();
@@ -1,105 +0,0 @@
1
- const { checkEvery } = require('../rule');
2
-
3
- const {
4
- checkFlowNode,
5
- checkLoopCharacteristics,
6
- checkMessage,
7
- hasExtensionElementOfType,
8
- hasExtensionElementsOfTypes,
9
- checkIf,
10
- hasMultiInstanceLoopCharacteristics,
11
- hasLoopCharacteristics
12
- } = require('../element');
13
-
14
- module.exports.hasZeebeCalledDecisionOrTaskDefinition = checkFlowNode(
15
- hasExtensionElementsOfTypes([
16
- {
17
- type: 'zeebe:CalledDecision',
18
- properties: {
19
- decisionId: {
20
- required: true
21
- },
22
- resultVariable: {
23
- required: true
24
- }
25
- }
26
- },
27
- {
28
- type: 'zeebe:TaskDefinition',
29
- properties: {
30
- type: {
31
- required: true
32
- }
33
- }
34
- }
35
- ], true)
36
- );
37
-
38
- module.exports.hasZeebeCalledElement = checkFlowNode(
39
- hasExtensionElementOfType({
40
- type: 'zeebe:CalledElement',
41
- properties: {
42
- processId: {
43
- required: true
44
- }
45
- }
46
- })
47
- );
48
-
49
- /**
50
- * Check if one of the following is true:
51
- *
52
- * 1. no loop characteristics
53
- * 2. bpmn:MultiInstanceLoopCharacteristics with zeebe:LoopCharacteristics
54
- * extension element with zeebe:inputCollection
55
- */
56
- module.exports.hasZeebeLoopCharacteristics = checkEvery(
57
- checkIf(
58
- hasMultiInstanceLoopCharacteristics,
59
- hasLoopCharacteristics
60
- ),
61
- checkIf(
62
- checkLoopCharacteristics(
63
- hasExtensionElementOfType({
64
- type: 'zeebe:LoopCharacteristics',
65
- properties: {
66
- inputCollection: {
67
- required: true
68
- },
69
- outputCollection: {
70
- dependendRequired: 'outputElement'
71
- },
72
- outputElement: {
73
- dependendRequired: 'outputCollection'
74
- }
75
- }
76
- })
77
- ),
78
- checkEvery(
79
- hasLoopCharacteristics,
80
- hasMultiInstanceLoopCharacteristics
81
- )
82
- )
83
- );
84
-
85
- module.exports.hasZeebeSubscription = checkMessage(
86
- hasExtensionElementOfType({
87
- type: 'zeebe:Subscription',
88
- properties: {
89
- correlationKey: {
90
- required: true
91
- }
92
- }
93
- })
94
- );
95
-
96
- module.exports.hasZeebeTaskDefinition = checkFlowNode(
97
- hasExtensionElementOfType({
98
- type: 'zeebe:TaskDefinition',
99
- properties: {
100
- type: {
101
- required: true
102
- }
103
- }
104
- })
105
- );
@@ -1,10 +0,0 @@
1
- /**
2
- * Strip patch version of a major.minor.patch
3
- * semver identifier.
4
- *
5
- * @param {String|null} string
6
- * @return {String|null}
7
- */
8
- module.exports.toSemverMinor = function(string) {
9
- return string && string.split(/\./).slice(0, 2).join('.');
10
- };