Hello,
I have been going through our logs and noticed pattern of two exceptions thrown by the sdk.
I don’t think they affected the workflow executions but I am trying to get rid of any errors.
The first one is in the WorkflowHistoryIterator
:
j.u.NoSuchElementException: null
at j.u.Collections$EmptyIterator.next(Unknown Source)
at i.t.i.r.WorkflowHistoryIterator.next(WorkflowHistoryIterator.java:116)
at i.t.i.r.WorkflowHistoryIterator.next(WorkflowHistoryIterator.java:40)
at i.t.i.r.ReplayWorkflowRunTaskHandler.handleWorkflowTaskImpl(ReplayWorkflowRunTaskHandler.java:179)
at i.t.i.r.ReplayWorkflowRunTaskHandler.handleWorkflowTask(ReplayWorkflowRunTaskHandler.java:150)
at i.t.i.r.ReplayWorkflowTaskHandler.handleWorkflowTaskWithEmbeddedQuery(ReplayWorkflowTaskHandler.java:202)
at i.t.i.r.ReplayWorkflowTaskHandler.handleWorkflowTask(ReplayWorkflowTaskHandler.java:112)
at i.t.i.w.WorkflowWorker$TaskHandlerImpl.handle(WorkflowWorker.java:309)
at i.t.i.w.WorkflowWorker$TaskHandlerImpl.handle(WorkflowWorker.java:275)
at i.t.i.w.PollTaskExecutor.lambda$process$0(PollTaskExecutor.java:73)
at j.u.c.ThreadPoolExecutor.runWorker(Unknown Source)
at j.u.c.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
And the second one is this rather generic sounding failure that seems to be sometimes logged AFTER the workflow execution finishes (~100-200ms after last application log from the workflow)
i.g.StatusRuntimeException: INVALID_ARGUMENT: UnhandledCommand
at i.g.stub.ClientCalls.toStatusRuntimeException(ClientCalls.java:244)
at i.g.stub.ClientCalls.getUnchecked(ClientCalls.java:225)
at i.g.stub.ClientCalls.blockingUnaryCall(ClientCalls.java:142)
at i.t.a.w.v.WorkflowServiceGrpc$WorkflowServiceBlockingStub.respondWorkflowTaskCompleted(WorkflowServiceGrpc.java:2673)
at i.t.i.w.WorkflowWorker$TaskHandlerImpl.lambda$sendReply$0(WorkflowWorker.java:369)
at i.t.i.c.GrpcRetryer.lambda$retry$0(GrpcRetryer.java:109)
at i.t.i.c.GrpcRetryer.retryWithResult(GrpcRetryer.java:127)
at i.t.i.c.GrpcRetryer.retry(GrpcRetryer.java:106)
at i.t.i.w.WorkflowWorker$TaskHandlerImpl.sendReply(WorkflowWorker.java:362)
at i.t.i.w.WorkflowWorker$TaskHandlerImpl.handle(WorkflowWorker.java:313)
at i.t.i.w.WorkflowWorker$TaskHandlerImpl.handle(WorkflowWorker.java:275)
at i.t.i.w.PollTaskExecutor.lambda$process$0(PollTaskExecutor.java:73)
... 3 common frames omitted
Wrapped by: j.l.RuntimeException: Failure processing workflow task. WorkflowId=workflow-search-b399e9d8-f1b3-476b-8937-365c03ebd7e1, RunId=f682e1ea-1700-43d6-a554-fedcebd1c9b3
at i.t.i.w.WorkflowWorker$TaskHandlerImpl.wrapFailure(WorkflowWorker.java:337)
at i.t.i.w.WorkflowWorker$TaskHandlerImpl.wrapFailure(WorkflowWorker.java:275)
at i.t.i.w.PollTaskExecutor.lambda$process$0(PollTaskExecutor.java:79)
at j.u.c.ThreadPoolExecutor.runWorker(Unknown Source)
at j.u.c.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Are these exceptions known or expected? Is there something we can do on the application side to remedy them?