Today, A2A hosting functionality does not fully handle A2A Tasks. It creates a new task in Working state (if background mode is configured) and returns it, but never updates its state or content, so the task remains Working forever.
Two potential solutions are:
- Poll the underlying agent and update task state and content. Perform non-blocking polling (return the task immediately but keep polling and updating the task in the background) if
context.Configuration?.ReturnImmediately; otherwise, perform blocking polling - not exiting/returning the method until the task is complete.
- Use streaming instead of polling.
Today, A2A hosting functionality does not fully handle A2A Tasks. It creates a new task in Working state (if background mode is configured) and returns it, but never updates its state or content, so the task remains Working forever.
Two potential solutions are:
context.Configuration?.ReturnImmediately; otherwise, perform blocking polling - not exiting/returning the method until the task is complete.