Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Workflow Update in Test Environment should dedup updates by ID #1638

Open
Quinn-With-Two-Ns opened this issue Sep 17, 2024 · 4 comments · May be fixed by #1695
Open

Workflow Update in Test Environment should dedup updates by ID #1638

Quinn-With-Two-Ns opened this issue Sep 17, 2024 · 4 comments · May be fixed by #1695

Comments

@Quinn-With-Two-Ns
Copy link
Contributor

Expected Behavior

Workflow Updates in Test Environment behave like Updates against a real server and either dupes for fails if an update with a duplicate ID is sent

Actual Behavior

Test Environment accepts update with duplicate ID

@sync-by-unito sync-by-unito bot changed the title Workflow Update in Test Environment does not dup. updates by ID Workflow Update in Test Environment should dedup updates by ID Oct 8, 2024
@yuandrew
Copy link
Contributor

Is the ID here referring to UpdateID from the UpdateClientWorkflow options? I'm working through some other failures in setting up this workflow, want to double check I'm going down the right path.

@Quinn-With-Two-Ns
Copy link
Contributor Author

Quinn-With-Two-Ns commented Oct 10, 2024

Is the ID here referring to UpdateID from the UpdateClientWorkflow options

Conceptually yes, but the test environment does not use a client since it is all in memory in the same process

Here is an example of sending an update with the test environment https://github.com/temporalio/samples-go/blob/main/reqrespupdate/workflow_test.go#L41, here "test id" is the UpdateID

@yuandrew
Copy link
Contributor

I'm playing around with the update go sample, and when I add UpdateID: we.GetID() to the UpdateWorkflowOptions, I'm not seeing the real server throw any error. Shouldn't this update fail?

@Quinn-With-Two-Ns
Copy link
Contributor Author

Shouldn't this update fail?

No, the real server will dedup the update request by the update ID

@yuandrew yuandrew linked a pull request Oct 29, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants