Skip to content
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

set_workflow_status: starting workflow should queue it #690

Open
mdonadoni opened this issue Jun 26, 2024 · 0 comments
Open

set_workflow_status: starting workflow should queue it #690

mdonadoni opened this issue Jun 26, 2024 · 0 comments

Comments

@mdonadoni
Copy link
Member

At the moment, calling set_workflow_status to start a workflow will result in the workflow being executed immediately, as r-server calls directly r-w-controller:

if not workflow_id_or_name:
raise ValueError("workflow_id_or_name is not supplied")
status = request.args.get("status")
parameters = request.json if request.is_json else None
response, http_response = current_rwc_api_client.api.set_workflow_status(
user=str(user.id_),
workflow_id_or_name=workflow_id_or_name,
status=status,
parameters=parameters,
).result()

Note that we have a second start_workflow endpoint which correctly queues the workflow:

def start_workflow(workflow_id_or_name, user): # noqa

@mdonadoni mdonadoni added this to Ready for work in 0.95.0 Jun 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
0.95.0
Ready for work
Development

No branches or pull requests

1 participant