|
413 | 413 | "description": "References a function to be invoked", |
414 | 414 | "$ref": "#/definitions/functionref" |
415 | 415 | }, |
416 | | - "eventRef": { |
417 | | - "description": "References a `produce` and `consume` reusable event definitions", |
418 | | - "$ref": "#/definitions/eventref" |
| 416 | + "publish": { |
| 417 | + "description": "Publish an event", |
| 418 | + "$ref": "#/definitions/publish" |
| 419 | + }, |
| 420 | + "subscribe": { |
| 421 | + "description": "Subscribe to an event channel", |
| 422 | + "$ref": "#/definitions/subscribe" |
419 | 423 | }, |
420 | 424 | "subFlowRef": { |
421 | 425 | "description": "References a sub-workflow to invoke", |
|
468 | 472 | { |
469 | 473 | "required": [ |
470 | 474 | "name", |
471 | | - "eventRef" |
| 475 | + "publish" |
| 476 | + ] |
| 477 | + }, |
| 478 | + { |
| 479 | + "required": [ |
| 480 | + "name", |
| 481 | + "subscribe" |
472 | 482 | ] |
473 | 483 | }, |
474 | 484 | { |
|
521 | 531 | } |
522 | 532 | ] |
523 | 533 | }, |
524 | | - "eventref": { |
| 534 | + "publish": { |
525 | 535 | "type": "object", |
526 | | - "description": "Event References", |
| 536 | + "description": "Publish an event", |
527 | 537 | "properties": { |
528 | | - "produceEventRef": { |
| 538 | + "event": { |
529 | 539 | "type": "string", |
530 | | - "description": "Reference to the unique name of a 'produced' event definition", |
| 540 | + "description": "Reference to the unique name of a 'published' event definition", |
531 | 541 | "pattern": "^[a-z0-9](-?[a-z0-9])*$" |
532 | 542 | }, |
533 | | - "consumeEventRef": { |
534 | | - "type": "string", |
535 | | - "description": "Reference to the unique name of a 'consumed' event definition", |
536 | | - "pattern": "^[a-z0-9](-?[a-z0-9])*$" |
537 | | - }, |
538 | | - "consumeEventTimeout": { |
539 | | - "type": "string", |
540 | | - "description": "Maximum amount of time (ISO 8601 format) to wait for the result event. If not defined it should default to the actionExecutionTimeout" |
541 | | - }, |
542 | 543 | "data": { |
543 | 544 | "type": [ |
544 | 545 | "string", |
545 | 546 | "object" |
546 | 547 | ], |
547 | | - "description": "If string type, an expression which selects parts of the states data output to become the data (payload) of the event referenced by 'produceEventRef'. If object type, a custom object to become the data (payload) of the event referenced by 'produceEventRef'." |
| 548 | + "description": "If string type, an expression which selects parts of the states data output to become the data (payload) of the event referenced by 'publish'. If object type, a custom object to become the data (payload) of the event referenced by 'publish'." |
548 | 549 | }, |
549 | 550 | "contextAttributes": { |
550 | 551 | "type": "object", |
|
556 | 557 | }, |
557 | 558 | "additionalProperties": false, |
558 | 559 | "required": [ |
559 | | - "produceEventRef" |
| 560 | + "event", "data" |
| 561 | + ] |
| 562 | + }, |
| 563 | + "subscribe": { |
| 564 | + "type": "object", |
| 565 | + "description": "Subscribe to an event channel", |
| 566 | + "properties": { |
| 567 | + "event": { |
| 568 | + "type": "string", |
| 569 | + "description": "Reference to the unique name of a 'subscribed' event definition", |
| 570 | + "pattern": "^[a-z0-9](-?[a-z0-9])*$" |
| 571 | + }, |
| 572 | + "timeout": { |
| 573 | + "type": "string", |
| 574 | + "description": "Maximum amount of time (ISO 8601 format) to wait for the result event. If not defined it should default to the actionExecutionTimeout" |
| 575 | + } |
| 576 | + }, |
| 577 | + "additionalProperties": false, |
| 578 | + "required": [ |
| 579 | + "event" |
560 | 580 | ] |
561 | 581 | }, |
562 | 582 | "subflowref": { |
|
1690 | 1710 | "name", |
1691 | 1711 | "type", |
1692 | 1712 | "action", |
1693 | | - "eventRef" |
| 1713 | + "" |
1694 | 1714 | ] |
1695 | 1715 | }, |
1696 | 1716 | "else": { |
|
0 commit comments