GitHub user wenjin272 added a comment to the discussion: [Discussion] Native 
Timer Support for Flink Agents

Thanks for pointing this out. The approval example is intended to illustrate 
timer registration, cancellation, and Event delivery, rather than provide a 
complete approval workflow. We described the checks in the timeout handler but 
omitted the corresponding checks in the approval handler.

Those checks and the reply belong in application code. The approval handler 
should validate the request version, state, and deadline before accepting the 
decision. A late approval should receive an explicit expired response, even if 
the timeout Action has not yet performed cleanup. A repeated submission for an 
already accepted decision should be handled separately.

The timer provides the scheduling mechanism; it does not determine whether an 
approval is valid. The runtime therefore does not tell the handler that the 
business request has expired based on whether its timer fired.

GitHub link: 
https://github.com/apache/flink-agents/discussions/1420#discussioncomment-19827596

----
This is an automatically sent email for [email protected].
To unsubscribe, please send an email to: [email protected]

Reply via email to