Skip to content

Bad request on executing activity #18

@Vandevska-E

Description

@Vandevska-E

Hi,

I am trying to configure an example of a schema and instance by using the Callback Api, and I am getting a bad request error.
When I test via the callback swagger it is successful, but when I set an action on an activity i always get a bad request:

{"@t":"2025-02-18T14:51:13.5089705Z","@m":"Caught an exception","@i":"ebd50127","@l":"Error","ExceptionInfo":{"Exceptions":"(ProcessExecutionException)Create instance of the process, ProcessId=0e4f7da7-7089-1f89-42bb-aab55a1d4fd1, failed.\r\n->(ProcessExecutionException)Error while executing implementation of Activity activity of the process, ProcessId=0e4f7da7-7089-1f89-42bb-aab55a1d4fd1\r\n-->(CallbackException)Code: BadRequest. Requested url https://localhost:7143/api/workflowaction/executeaction.","Message":"Code: BadRequest. Requested url https://localhost:7143/api/workflowaction/executeaction.","StackTrace":" at OptimaJet.WorkflowServer.Callback.CallbackProvider.ExecuteActionInternalAsync(String name, ProcessInstance processInstance, String actionParameter) in /home/teamcity-agent/agent/work/a7a0351d523d7d93/OptimaJet.WorkflowServer/Callback/CallbackProvider.cs:line 515\r\n at OptimaJet.WorkflowServer.Callback.CallbackProvider.ExecuteActionAsync(String name, ProcessInstance processInstance, WorkflowRuntime runtime, String actionParameter, CancellationToken token) in /home/teamcity-agent/agent/work/a7a0351d523d7d93/OptimaJet.WorkflowServer/Callback/CallbackProvider.cs:line 147\r\n at OptimaJet.Workflow.Core.Runtime.AggregatingActionProvider.ExecuteActionAsync(String name, ProcessInstance processInstance, WorkflowRuntime runtime, String actionParameter, CancellationToken token)\r\n at OptimaJet.Workflow.Core.Execution.ActivityExecutor.ExecuteActionFromProviderAsync(ActionDefinitionReference method, ExecutionResponseComplete response, CancellationToken token)\r\n at OptimaJet.Workflow.Core.Execution.ActivityExecutor.ExecuteMethodAsync(ExecutionRequestParameters parameters, CancellationToken token)\r\n at OptimaJet.Workflow.Core.Execution.ActivityExecutor.ExecuteMethodAsyncWithHandling(ExecutionRequestParameters parameters)\r\n at OptimaJet.Workflow.Core.Execution.ActivityExecutor.ExecuteMethodAsyncWithHandling(ExecutionRequestParameters parameters)\r\n at OptimaJet.Workflow.Core.Execution.ActivityExecutor.TryExecuteAlwaysCondition()\r\n----------\r\n at OptimaJet.Workflow.Core.Execution.ProcessExecutor.ProcessErrorResponseAsync(ExecutionResponse response, ProcessInstance processInstance, CancellationToken token)\r\n at OptimaJet.Workflow.Core.Execution.ProcessExecutor.ExecuteFullAsync(ExecutionRequest executionRequest, CancellationToken token)\r\n at OptimaJet.Workflow.Core.Execution.ProcessExecutor.ExecuteCreatedProcessAsync(ProcessInstance processInstance, String identityId, String impersonatedIdentityId, CancellationToken token, ProcessInstancesTree processInstancesTree)\r\n----------\r\n at OptimaJet.Workflow.Core.Execution.ProcessExecutor.ExecuteCreatedProcessAsync(ProcessInstance processInstance, String identityId, String impersonatedIdentityId, CancellationToken token, ProcessInstancesTree processInstancesTree)\r\n at OptimaJet.Workflow.Core.Execution.ProcessExecutor.<>c__DisplayClass11_0.<<InitCreatedProcessAsync>b__1>d.MoveNext()\r\n--- End of stack trace from previous location ---\r\n at OptimaJet.Workflow.Core.Runtime.MultiThreadProcessExecutor.ExecuteAsync(WorkflowRuntime runtime, ProcessInstance processInstance, ProcessStatus status, TransitionDefinition executedTransition, Func`1 needNewThreadCheck, Func`2 action)\r\n at OptimaJet.Workflow.Core.Execution.ProcessExecutor.InitCreatedProcessAsync(String identityId, String impersonatedIdentityId, ProcessInstance processInstance, IDictionary`2 initialProcessParameters, CancellationToken token, ProcessInstancesTree processInstancesTree, TransitionDefinition startingTransition, List`1 persist)\r\n at OptimaJet.Workflow.Core.Runtime.WorkflowRuntime.CreateInstanceAsync(CreateInstanceParams createInstanceParams, CancellationToken token)\r\n at OptimaJet.WorkflowServer.ConfigApi.WorkflowProcessingAsync(WorkflowServerRuntime workflowServerRuntime, NameValueCollection form) in /home/teamcity-agent/agent/work/a7a0351d523d7d93/OptimaJet.WorkflowServer/ConfigApi.cs:line 1276\r\n at OptimaJet.WorkflowServer.ConfigApi.ConfigAPI(WorkflowServerRuntime workflowServerRuntime, HttpRequest request, NameValueCollection form, Stream filestream) in /home/teamcity-agent/agent/work/a7a0351d523d7d93/OptimaJet.WorkflowServer/ConfigApi.cs:line 199\r\n at OptimaJet.WorkflowServer.WorkflowServerRuntime.ConfigApiProcessingAsync(HttpRequest request) in /home/teamcity-agent/agent/work/a7a0351d523d7d93/OptimaJet.WorkflowServer/WorkflowServerRuntime.cs:line 1640"}}

I get the same issue regardless if I launch via Docker or not.

Any idea what could be the issue?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions