ADR : New API to handle System workflows
System workflows are the workflows which are available to all the data partitions. Any System workflow can be triggered and retrieved by any of the tenants, but it can be Created, updated, deleted by only a user with special privilege (Let’s say it has system role).
This is more with respect to the workflows or DAGs that OSDU provides with.
How it's done today:
- There is no concept of system workflows.
- The workflow metadata is stored in partition specific cosmos collection.
Issue with current design:
- The behavior of create api endpoint will change and can be confusing to users if we use same for system as well as private workflow. Users might end up unknowingly creating system workflow by passing data-partition-id of special partition.
- It is difficult for the updates to be managed for the changes from the OSDU community, if we try to copy or replicate the information across all the customer partitions.
There are two types of workflows in the system, System workflows and Private workflows. The proposal is to create a new API endpoint to register System workflows.
- The new API shall be termed as
- To create/update/delete System workflows -
/workflow/systemendpoint shall be used
- To Get/Trigger System workflows, existing workflow service endpoint must be used.
- The authorization of new end point shall be different from existing groups. We'll use service principal based authorization.
- The new API shall not accept data-partition-id as a header. Service would be aware where the System workflows are located.
- This API should interact only with System workflows. It should not have access to other workflows.