I have written workflow A with a signal and query. I want to send a signal from workflow B and workflow C.
On signal calling an external API will take 10 min to complete. once API complete I am adding result to map with key, using query reading the result from the map
looks working but while query getting DEADLINE_EXCEEDED error message with retry is working.
What is the recommended way to send a signal and query from a Workflow?
In workflow code how can we use this? When I started implementing the workflow I couldn’t found the suggestion for this class. Need I to create the separate class for the WorkflowToSignal? In the Java sdk
On the receiving workflow side, you can either add the signal method to the receiving workflow interface or create a separate interface and register it through Workflow.registerListener.
What is the use of the signalMethod( ) in temporal?
Can you give me the explanation for it?
Because I am new to temporal. So I need to understand about it.
Signals can be used to deliver external data/messages to running workflows. One common use case is when a workflow needs to wait for an external event (for example a human decision) in order to proceed execution. Another use case is when you want to start a workflow execution upon arrival of an external signal/message/event.
Check out this sample in our samples-java repo.
The app shows how to send signals with different Temporal SDKs (Java, Go, PHP, and NodeJS).
Here is the specific code of the workflow written in Java sending signals to a workflow written in Go, but the same code can be used to signal a workflow that is written using any of the Temporal SDKs.