Skip to content

A Nexus callback carrying an older operation token is accepted after a retry persists a new token #12437

Description

@bergundy

Expected Behavior

The callback is rejected.

Actual Behavior

A Nexus callback carrying an older operation token is accepted after a retry persists a new token, allowing a stale remote operation to supply the workflow result when endpoint retries create distinct operations.

Step to Reproduce

  1. Start a standalone nexus operation
  2. In the Nexus handler, on the first attempt, start a workflow that completes after a 5 seconds and fail the Nexus request with a retryable error
  3. In the Nexus handler, on the second attempt, start a workflow that is blocked on a signal, respond successfully to the Nexus request
  4. Observe the standalone Nexus operation, it should be completed and link to the blocked workflow

Notes

We are currently relying on handler idempotency for correctness. We had to choose to either ignore or accept completions for executions that are created from a previous attempt, and we decided to accept them. I think it's a valid point that we may want to reconsider. This hurts the debugging experience when the link on the caller workflow points to a backing primitive and the completion comes from a different primitive.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions