Skip to content

feat(core): add experimental batch loading modes - #11104

Merged
ibgreen merged 14 commits into
masterfrom
codex/experimental-batch-loading
Nov 15, 2026
Merged

ibgreen merged 14 commits into
masterfrom
codex/experimental-batch-loading

Conversation

@ibgreen

@ibgreen ibgreen commented Nov 13, 2026 •

Copy link
Copy Markdown
Collaborator

For #11069. Prerequisite for #11089.

Background

Layers need to consume batches directly from loaders.gl and Arrow streams.

Change List

  • Add _dataLoadOptions for complete loads, append, and replacement
  • Unwrap data batches and discard stream metadata
  • Report accepted batches through onDataProgress
  • Unit tests and WebGL/WebGPU rendering and picking checks
  • Documentation

Build, lint, 43 Node tests, 28 headless tests, and the website check passed locally.


Note

Medium Risk
Modifies core layer asynchronous data resolution and resource subscription lifecycles to support streamed data and Arrow batching.

Overview
Adds experimental _dataLoadOptions ('auto' | 'batched' | 'snapshots') and onDataProgress props to Layer to support streaming and incremental batch data loading. When configured for batching, layers fetch remote URLs using loaders.gl loadInBatches and automatically reload if loader options change.

Layers can now stream Apache Arrow RecordBatch and Table chunks directly while preserving columnar storage without converting inputs into row objects. Stream handling also normalizes Arrow schemas and batches across runtimes, discards loader metadata chunks, and triggers onDataProgress as each chunk is applied.

Reviewed by Cursor Bugbot for commit 97858d6. Bugbot is set up for automated code reviews on this repo. Configure here.

@greptile-apps

greptile-apps Bot commented Nov 13, 2026 •

Copy link
Copy Markdown

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] The PR appears safe to merge; no new blocking issue was established.

Summary

Adds experimental batch loading and Arrow streams.

  • Layers can report each streamed data batch as it arrives.
  • Layers can load URL data as batches or snapshots.
  • Arrow stream batches stay in column-based tables.

No new actionable issues were found. The earlier dataTransform thread was manually resolved without explanation.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart TD
  A[Layer data] --> B{URL loading mode}
  B -->|auto| C[Complete load]
  B -->|batched or snapshots| D[Batch stream]
  E[Application stream] --> D
  D --> F[Discard metadata]
  F --> G{Chunk kind}
  G -->|Rows| H[Transform and append]
  G -->|Arrow| I[Normalize foreign batches or empty schema]
  I --> J[Append or replace table]
  H --> K[Update data and report progress]
  J --> K
  K --> L[Report completion when stream ends]
Loading

Reviews (11) · Last reviewed commit: "fix(core): preserve Arrow schema type in..." · Reviewed by Greptile

Comment thread modules/core/src/lib/layer-state.ts Resolved
Comment thread modules/core/src/lib/layer-state.ts Resolved
@coveralls

coveralls commented Nov 13, 2026 •

Copy link
Copy Markdown

Coverage Status

Coverage is 83.444% — codex/experimental-batch-loading into master. No base build found for master.

Comment thread modules/core/src/lib/layer.ts Resolved
Comment thread modules/core/src/utils/loader-utils.ts Resolved

@cursor cursor Bot left a comment •

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Stale Bugbot comment from a previous run.

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using default effort and found 2 potential issues.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 5a85834. Configure here.

@ibgreen
ibgreen merged commit 42c168c into master Nov 15, 2026
9 checks passed
@ibgreen
ibgreen deleted the codex/experimental-batch-loading branch November 15, 2026 16:35
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.

2 participants