Skip to content

feat(batch): Reimplement batch controller for consistency#138

Merged
behinddwalls merged 2 commits into
mainfrom
sergeyb/batch
Mar 11, 2026
Merged

feat(batch): Reimplement batch controller for consistency#138
behinddwalls merged 2 commits into
mainfrom
sergeyb/batch

Conversation

@sbalabanov
Copy link
Copy Markdown
Contributor

@sbalabanov sbalabanov commented Mar 11, 2026

Summary

BatchDependent is a secondary index stucture to Batch entity, make it
fully eventually consistent:

  • Give it more comments
  • Always create with batch creation so next batch won't have to guess
  • Remove metadata, it won't be used, at least not for state tracking as it
    gets stale
  • Ensure order of operations - dependents first, empty dependent entry
    second, batch itself to follow, and then queue
  • Additional comments added explaining the further stale state
    reconciliation logic

Test Plan

Issues

Stack

  1. refactor(id): Let queue operate on IDs and controller on database #137
  2. @ feat(batch): Reimplement batch controller for consistency #138

Comment thread entity/batch.go
@sbalabanov sbalabanov marked this pull request as ready for review March 11, 2026 00:32
@sbalabanov sbalabanov requested review from a team and behinddwalls as code owners March 11, 2026 00:32
BatchDependent is a secondary index stucture to Batch entity, make it
fully eventually consistent:
- Give it more comments
- Always create with batch creation so next batch won't have to guess
- Remove metadata, it won't be used, at least not for state tracking as it
  gets stale
- Ensure order of operations - dependents first, empty dependent entry
  second, batch itself to follow, and then queue
- Additional comments added explaining the further stale state
  reconciliation logic
@behinddwalls behinddwalls deleted the branch main March 11, 2026 01:48
@behinddwalls behinddwalls reopened this Mar 11, 2026
@behinddwalls behinddwalls changed the base branch from sergeyb/id to main March 11, 2026 01:53
@behinddwalls behinddwalls enabled auto-merge March 11, 2026 03:29
@behinddwalls behinddwalls added this pull request to the merge queue Mar 11, 2026
Merged via the queue into main with commit 8e3e4af Mar 11, 2026
11 checks passed
@github-actions github-actions Bot deleted the sergeyb/batch branch March 11, 2026 09:54
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.

3 participants