Details
-
Improvement
-
Resolution: Unresolved
-
None
-
Medium
-
triggerCallbackAction URLs are configurable through the config now, with the ability to override it at the client level. Users can define or modify the callback URLs without need for manual database changes.
-
Empty show more show less
Description
Problem
Enhance the flexibility of the triggerCallbackAction URL configuration by making it client-specific. Currently, the URL for the workflow's trigger callback action is defined in the parameters column as an additional field. This approach lacks flexibility, as any URL change requires manual updates via SQL directly in the database, which is inefficient.
Proposed Solution:
- Allow the callback URL to be configurable through the ZF config files, with the ability to override it at the client level.
- This change will provide greater flexibility for users, enabling them to define or modify the callback URLs without needing our support or manual database changes.
By implementing this, users will have full control over the URL configuration, making the system more adaptable and reducing the need for intervention from our team.
The config definition should be something like this:
name: runtimeOptions.task.workflow.webhooks
type: map (see example runtimeOptions.lengthRestriction.pixelMapping . The user is able to define key value pairs)
value:
{ "handleAllFinishOfARole" : "https://www.callbackaction.de/test", "handleAfterImport" : "https://www.anoterUrl.com/api" }
Example entries in workflow table:
+----------------------+------------+-----------+------------+-----------------------+-------------------+------------+ | trigger | inStep | byRole | userState | actionClass | action | parameters | +----------------------+------------+-----------+------------+-----------------------+-------------------+------------+ | handleAllFinishOfARole| reviewing | reviewer | finished | editor_Workflow_Actions| triggerCallbackAction | | +----------------------+------------+-----------+------------+-----------------------+-------------------+------------+
When the above workflow action is triggered for the task, first check if for the action there is config defined. If yes use the configured url from the config.
In our case this will be https://www.callbackaction.de/test
Second example:
+----------------------+------------+-----------+------------+-----------------------+-------------------+------------+ | trigger | inStep | byRole | userState | actionClass | action | parameters | +----------------------+------------+-----------+------------+-----------------------+-------------------+------------+ | handleAfterImport| reviewing | reviewer | finished | editor_Workflow_Actions| triggerCallbackAction | | +----------------------+------------+-----------+------------+-----------------------+-------------------+------------+
In the second case the url will be https://www.anoterUrl.com/api
Since the config can be client specific, for each (task) client the users are able to define another urls.
We will have to decide which triggers will have callbacks. Initially we can go with only handleAllFinishOfARole but later on to enable new one we will just have to add it in the workflows action table and the users will be able to define it in the configs.
Create a confluence page in the REST API docu, that explains for all different available callback possibilities, how to use them and link to the other pages, where they are referenced
Attachments
Issue Links
- blocks
-
TRANSLATE-2971 Set job deadlines for multiple projects or tasks at the same time
- In Progress
- is blocked by
-
TRANSLATE-4221 Save analysis from xliff
- Final pull request