Calling signal methods on completed workflows

What is the behavior when a signal method is called on a workflow that is already complete?
i assume the signal methods are supposed to be called to send data to a workflow that is in execution. But if the workflow is already complete, will the framework throw any exception?

Which SDK are you using (you can tag it when creating a thread on the forum).

In case you try to signal an already completed workflow from your client, the client call should receive the WorkflowNotFoundException in the Java SDK.

Hi tihomir,
Thanks for the help. yes, I am using java SDK. sorry forgot to mention it.

a related question(Java SDK only):
if i try to create a workflow stub for an already completed workflow through
WorkflowClient.newWorkflowStub(Class workflowInterface, String workflowId);
function call, will we get the same WorkflowNotFoundException exception?

Stub creation doesn’t check if an ID is valid. When you call a signal or query method on that stub, you can potentially get WorkflowNotFoundException.

Thanks for the clarification Maxim!