An ActivityDefinition has the InputSchema property, which is supposed to contain the JSON schema for any input values. The input values are transmitted in Activity.Inputs.
Additionally, each ActivityDefinition declares an OutputSchema, which specifies the format of the activity's output data.
We should validate both those schemas in the following ways:
An
ActivityDefinitionhas theInputSchemaproperty, which is supposed to contain the JSON schema for any input values. The input values are transmitted inActivity.Inputs.Additionally, each
ActivityDefinitiondeclares anOutputSchema, which specifies the format of the activity's output data.We should validate both those schemas in the following ways:
Activity.Inputs) against the correspondingActivityDefinition.InputSchema. This should be done when instantiating the activity, i.e. when creating theOrchestrationDefinitionOrchestrationDefinitionvia API) we should check each activity's outputs against the inputs of its dependents. If AcitivtyB dependsOn ActivityA, then B's inputs must be validated against A's outputs. This is only relevant for activities that have adependsOnrelationship. If a schema validation is detected, the API request should return an HTTP 400.If this proves to be impractical, the check could also be done when instantiating
Orchestrations.