xintongsong commented on code in PR #616:
URL: https://github.com/apache/flink-agents/pull/616#discussion_r3097525304
##########
docs/content/docs/development/workflow_agent.md:
##########
@@ -301,6 +301,11 @@ on how to setup and configure the external action state
store.
- If a failure happens after a function completes but before its result is
persisted, the call will be re-executed.
Review Comment:
```suggestion
- If a failure happens after a function starts but before it completes and
its result is persisted, the call will be re-executed.
```
##########
docs/content/docs/development/workflow_agent.md:
##########
@@ -301,6 +301,11 @@ on how to setup and configure the external action state
store.
- If a failure happens after a function completes but before its result is
persisted, the call will be re-executed.
Review Comment:
And we can point to the reconciler from here.
##########
docs/content/docs/operations/deployment.md:
##########
@@ -171,6 +171,8 @@ After recovery from a checkpoint, Flink Agents reprocess
events that arrived aft
To ensure exactly-once action consistency, you must configure an external
action state store. Flink Agents record action state in this store on a
per-action basis. After recovering from a checkpoint, Flink Agents consult the
external store and will not re-execute actions that were already completed.
This guarantees each action is executed exactly once after recovering from a
checkpoint.
+The same persisted action state is also used by fine-grained durable
execution, including reconciler-based recovery for durable calls that need to
recover a terminal outcome after failure.
Review Comment:
```suggestion
The same persisted action state is also used by fine-grained durable
execution.
```
##########
docs/content/docs/faq/faq.md:
##########
@@ -83,6 +83,8 @@ Async execution can significantly improve performance by
allowing multiple opera
> **Cross-language async limitation**: When using cross-language resources
> (e.g., calling Java integrations from Python or vice versa), async execution
> is not supported. Cross-language calls always execute synchronously
> regardless of your JDK version.
+Reconciler-backed durable execution is available in both Python and Java, but
it only affects how durable calls recover persisted terminal outcomes. It does
not change the async execution matrix above.
Review Comment:
Not sure about the necessity of adding this. Would there be any confusions
if we don't add it?
##########
docs/content/docs/development/workflow_agent.md:
##########
@@ -301,6 +301,11 @@ on how to setup and configure the external action state
store.
- If a failure happens after a function completes but before its result is
persisted, the call will be re-executed.
- In Python async actions, if `ctx.durable_execute_async(...)` is not awaited,
the result is not recorded and cannot be replayed.
+**Recovered terminal outcome with a reconciler:**
+- A durable call may optionally provide a reconciler that is used only during
recovery, when the same durable call is revisited and no terminal outcome has
been persisted for it yet.
Review Comment:
It feels a bit obscure. Might be better to start with the two questions that
users care most: when to use this feature (call started but not
completed/persisted, framework cannot decide should replay or not), and what it
can do (support custom reconciling logics).
##########
docs/content/docs/development/workflow_agent.md:
##########
@@ -316,6 +321,28 @@ def process_input(event: InputEvent, ctx: RunnerContext)
-> None:
result = ctx.durable_execute(slow_external_call, event.input)
ctx.send_event(OutputEvent(output=result))
```
+
+You can also pass an optional `reconciler` callable to recover a terminal
outcome during recovery.
Review Comment:
This might be my English issue, but TBH I'm a bit confused about what
`terminal outcome` means here.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]