Signal received but activity was not performed[JAVA]

Hi Team,

I have few activities planned in my workflow,
Today the after receiving first activity signal, the first activity failed due to expected error and all retries were exhausted
Now second activity signal was received but I see the workflow task was scheduled and the error I get is of the same 1st activity which failed
Problem: 2nd activity is not started even if signal was received
How to make sure the even if 1 activity fails after all retries, the workflow can continue with other activities successfully?


Here in above screen signal for 1st activity failed at 17 and workflow error was seen at 20 and 2nd activity signal was received at 21 but still the error on 24 and 20 are same. Why is 2nd activity not invoked even after receiving signal
Please help me fix this. Thank you.

What is the error inside the WorkflowTaskFailed event?

“message”: "Failure handling event 19 of type ‘EVENT_TYPE_WORKFLOW_TASK_STARTED’ during execution. {WorkflowTaskStartedEventId=19, CurrentStartedEventId=19}
“message”: “WorkflowTask: failure executing SCHEDULED->WORKFLOW_TASK_STARTED, transition history is [CREATED->WORKFLOW_TASK_SCHEDULED]”,
“message”: “Activity with activityType=‘FetchFullData’ failed: ‘Activity task failed’. scheduledEventId=15, startedEventId=16, activityId=73b53541-2a3c-3222-a631-ba25152df7a7, identity=‘1@oem-integration-service-deployment-55845bf8c6-v7w2h’, retryState=RETRY_STATE_MAXIMUM_ATTEMPTS_REACHED”,
“applicationFailureInfo”: {
“type”: “com.kmbl.cb.vlos.oem_integration_service.error.OEMException”
}
},
“applicationFailureInfo”: {
“type”: “java.lang.RuntimeException”
}
},
“applicationFailureInfo”: {
“type”: “io.temporal.internal.statemachines.InternalWorkflowTaskException”
}
@maxim Above are the contents from the same
activity 1 fails and exhausts all its retries, so after activity 2 signal is received it should work right??? activity 2 should start instead at #24 it explains again why activity 1 failed

It looks like the workflow code is throwing “com.kmbl.cb.vlos.oem_integration_service.error.OEMException”. Throwing an unknown exception fails the workflow task.

@maxim True at the event of activity failure we throw a custom exception which extends to Runtime Exception, so as per your comment the workflow will work if we catch the exception and do nothing[or just log the error] in the method @Override
public void executeWorkflow

Throw an ApplicationFailure if you want the workflow to fail.

1 Like

@maxim on the contrary I do not want the workflow to fail so I think I should not throw the exception which will lead workflow to continue with other activities even if any one of the activities fail

1 Like