Skip to content

A6.2: Batch executor with bounded concurrency#21

Closed
paulius-krutkis-dcd wants to merge 1 commit into
batch-input-parsingfrom
scr-3179-batch-executor
Closed

A6.2: Batch executor with bounded concurrency#21
paulius-krutkis-dcd wants to merge 1 commit into
batch-input-parsingfrom
scr-3179-batch-executor

Conversation

@paulius-krutkis-dcd

Copy link
Copy Markdown
Collaborator

Second of four stacked PRs for A6 — batch input (SCR-3092).

Adds runBatch: pulls items from the streaming input iterator (A6.1) and runs them through a worker with a fixed-size concurrency pool.

  • Per-item failures are captured as { class, message } error records and do not abort the batch.
  • Results are emitted via onResult in completion order; returns a { total, succeeded, failed } summary.
  • Iterator pulls and emissions are serialised, so async iterators are never re-entered and onResult is never called concurrently.

Based on scr-3178-batch-input-parsing — review/merge A6.1 (#20) first. GitHub will retarget this PR to main once A6.1 merges.

Stack: A6.1 (#20) → A6.2 (this) → A6.3 → A6.4

Closes SCR-3179.

🤖 Generated with Claude Code

Add runBatch: pulls items from the streaming input iterator and runs them
through a worker with a fixed-size concurrency pool (default applied by
callers). Per-item failures are captured as {class, message} error records
and never abort the batch; results are emitted via onResult in completion
order, and a {total, succeeded, failed} summary is returned.

Iterator pulls and result emissions are each serialised so async iterators
are not re-entered and onResult is never called concurrently.

Depends on A6.1 (SCR-3179).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@paulius-krutkis-dcd

Copy link
Copy Markdown
Collaborator Author

Superseded by #25 (rebranched to drop internal ids).

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