-
Notifications
You must be signed in to change notification settings - Fork 49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Disambiguate workflows #59
Changes from 4 commits
8c26d39
65e0c21
5b8e4e5
532e99c
4f1d7ff
06211ec
ab33786
05dc5d0
6852e00
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -142,7 +142,7 @@ info: | |
This workflow walks you through the steps of `searching` for, `selecting`, and `purchasing` an available pet. | ||
version: 1.0.1 | ||
sources: | ||
- name: petStoreDefinition | ||
- sourceId: petStoreDefinition | ||
url: https://github.com/swagger-api/swagger-petstore/blob/master/src/main/resources/openapi.yaml | ||
type: openapi | ||
|
||
|
@@ -234,7 +234,7 @@ An object storing a map between named document keys and location URLs to the sou | |
|
||
Field Name | Type | Description | ||
---|:---:|--- | ||
<a name="sourceName"></a>name | `string` | **REQUIRED**. A unique name for the source document. | ||
<a name="sourceId"></a>sourceId | `string` | **REQUIRED**. Unique string to represent the source. The id MUST be unique amongst all sources describe in the Workflows document. The `sourceId` value is **case-sensitive**. Tools and libraries MAY use the `sourceId` to uniquely identify a source, therefore, it is RECOMMENDED to follow common programming naming conventions. | ||
<a name="sourceURL"></a>url | `string` | **REQUIRED**. A URL to a source document to be used by a Workflow. MUST be in the form of a [URL](https://url.spec.whatwg.org/). MAY be defined using relative references as defined by [RFC3986](https://spec.openapis.org/oas/latest.html#bib-RFC3986). | ||
<a name="infoType"></a>type | `string` | The type of source document. Possible values are `"openapi"`, `"asyncapi"`, or `"workflowsSpec"`. | ||
|
||
|
@@ -244,7 +244,7 @@ This object MAY be extended with [Specification Extensions](#specification-exten | |
##### Source Object Example | ||
|
||
```yaml | ||
name: petStoreDefinition | ||
sourceId: petStoreDefinition | ||
url: https://github.com/swagger-api/swagger-petstore/blob/master/src/main/resources/openapi.yaml | ||
type: openapi | ||
``` | ||
|
@@ -314,7 +314,8 @@ Field Name | Type | Description | |
<a name="stepId"></a>stepId | `string` | **REQUIRED**. Unique string to represent the step. The id SHOULD be unique amongst all steps described in the workflow. The stepId value is **case-sensitive**. Tools and libraries MAY use the stepId to uniquely identify a workflow step, therefore, it is RECOMMENDED to follow common programming naming conventions. | ||
<a name="stepOperationId"></a>operationId | `string` | The name of an existing, resolvable operation, as defined with a unique `operationId` and existing within one of the `source` documents. The referenced operation will be invoked by this workflow step. If more than one `source` document is defined within a Workflows document, then the `operationId` specified MUST be prefixed with the source name to avoid ambiguity or potential clashes. This field is mutually exclusive of the `operationRef` and `workflowId` fields respectively. | ||
<a name="stepOperationRef"></a>operationRef | `string` | A relative or absolute URI reference to an OAS operation. This field is mutually exclusive of the `operationId` and `workflowId` fields respectively. Relative `operationRef` values MAY be used to locate an existing. See [OpenAPI relative reference resolution rules](https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.1.0.md#relativeReferencesURI) for guidance. A complete [URI Template](https://www.rfc-editor.org/rfc/rfc6570) can also be used. | ||
<a name="stepWorkflowId"></a>workflowId | `string` | The [workflowId](#fixed-fields-2) referencing an existing workflow within the Workflows document. The field is mutually exclusive of the `operationId` and `operationRef` fields respectively. | ||
<a name="stepWorkflowId"></a>workflowId | `string` | The [workflowId](#fixed-fields-2) referencing an existing workflow within the Workflows document. The field is mutually exclusive of the `operationId` and `operationRef` fields respectively. In the event that two workflows with the same `workflowId` are available, because they are both defined in separate [Sources](#source-object), then the provided value MUST contain the | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The description here seems incomplete (e.g. finishes with I was thinking we'd follow on from how we clarified the operationId and just modify with workflowId:
|
||
<a name="stepWorkflowIdSourceId"></a>workflowIdSourceId | `string` | Optional. The `sourceId` of the [Source](#source-object) where the Workflow identified by `workflowId` is defined. Required in cases where multiple [Sources](#source-object) define different workflows with colliding values of `workflowId`. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is this needed if we follow the |
||
<a name="stepParameters"></a>parameters | [[Parameter Object](#parameter-object) \| [Reference Object](#reference-object)] | A list of parameters to pass to an operation or workflow as referenced by `operationId`, `operationRef`, or `workflowId`. If a Reference Object is provided, it MUST link to parameters defined in [components/parameters](#component-object). | ||
<a name="dependsOn"></a>dependsOn | [`string`] | A list of steps that MUST be completed before this step can be processed. This helps to ensure workflow steps are executed in the correct order and that dependent steps are not processed in parallel. The values provided MUST be the be the `stepId` which uniquely references a step. | ||
<a name="stepSuccessCriteria"></a>successCriteria | [{expression}] | A list of assertions to determine the success of the step | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a need to revamp the source object?