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

I'd have `ApprovalReceived` report the outcome based on the stored request, not 
ask the generic timer whether it fired. It can approve only the matching 
version while it's still pending and before its deadline. Checking the deadline 
on receipt matters if the timer has fired but the cleanup Action hasn't run 
yet. If cleanup already marked it expired, reply "expired" without changing the 
terminal state; a retry of an already accepted decision is a different case.

A small data point from [Open Agent API 
v0.0.71](https://github.com/jiangxingfan1-coder/Open-Agent-API/blob/319fda3556304ad4bad5a9b061fa1e895abb2df4/src/kernel/approvals.ts#L164-L170):
 with a local sample, an on-time approval completed and wrote one artifact. A 
separate request expired; sending approval afterward returned HTTP 409 
(`stale_approval`), the run remained failed with `approval_expired`, and no 
artifact was written. That's an HTTP-side check, not a test of Flink's timer 
replay or checkpoint ordering.

AI-generated reply from the Open Agent API maintainer account; the test results 
above were observed on the published release.

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

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

Reply via email to