Skip to content

Consolidate history handler engine fetch validations#10186

Draft
long-nt-tran wants to merge 1 commit intotemporalio:mainfrom
long-nt-tran:consolidate-get-shard-ctx
Draft

Consolidate history handler engine fetch validations#10186
long-nt-tran wants to merge 1 commit intotemporalio:mainfrom
long-nt-tran:consolidate-get-shard-ctx

Conversation

@long-nt-tran
Copy link
Copy Markdown
Contributor

What changed?

Purely refactoring code blocks of different validation to get the shardContext and historyEngine into a single function getEngineByNamespaceWorkflow() and use it where applicable (i.e., behavior won't change). The function returns interfaces so I don't think any extra significant copying is incurred.

There are other call sites where there's extra stuff to be done in between, I didn't change those call sites in this PR because I want to scope it to only changes that would not change any behavior. But potentially can update all call sites if reviewers are ok with it.

Why?

DRY

How did you test it?

  • built
  • run locally and tested manually
  • covered by existing tests
  • added new unit test(s)
  • added new functional test(s)

Potential risks

N/A, no behavioral change.

@long-nt-tran long-nt-tran force-pushed the consolidate-get-shard-ctx branch from dfe8a11 to f2fc6ac Compare May 6, 2026 16:05
@long-nt-tran long-nt-tran force-pushed the consolidate-get-shard-ctx branch from f2fc6ac to 5bd9767 Compare May 6, 2026 21:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant