Skip to content

docs: make server-side batching the default import method#466

Merged
g-despot merged 5 commits into
mainfrom
docs/server-side-batching-snippets
Jul 7, 2026
Merged

docs: make server-side batching the default import method#466
g-despot merged 5 commits into
mainfrom
docs/server-side-batching-snippets

Conversation

@g-despot

@g-despot g-despot commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

What

Makes server-side batching (SSB) the default, recommended way to import data on the batch-import how-to page, and fills in the SSB code snippets for every client that supports it. SSB shipped in Weaviate v1.36; the concepts page already called it "the recommended approach," but the how-to page still led with client-side batching and only Python had an SSB snippet.

Import page restructure (manage-objects/import.mdx)

  • Server-side batching is now the first section, framed as the recommended starting point "for most use cases."
  • The old "Basic import" (client-side) is demoted to "Manual batching" — the alternative for manual control or for the Go client. Client-side batching stays valid, not obsolete.
  • The Go tab points to manual batching ("the Go client does not support server-side batching") instead of "coming soon".
  • A one-line note that SSB uses the gRPC API (enabled by default), cross-linking the gRPC section.

SSB snippets added (were "coming soon")

Client Server-side batching API
Python collection.batch.stream() (already documented)
TypeScript collection.data.ingest()
Java v6 collection.batch.start()BatchContext
C# collection.Batch.InsertMany()
Go — no client API yet (uses manual batching)

Fixes found while making the snippets actually run

  • TS: data.ingest() silently dropped properties when passed bare objects on an untyped collection (imported empty objects). Switched to the { properties: { title } } DataObject wrapper + a fetchObjects() assertion. (The underlying client inconsistency is tracked separately for the TS client.)
  • Java tests: the java-v6 examples module depended on an unpublished 6.2.1-SNAPSHOT while CI built 6.2.0 (which lacks text2vec-digitalocean + tokenize APIs), so the whole module failed to compile. Pinned the pom + CI to the released 6.3.0.
  • concepts/data-import.mdx: corrected the stale "only the Python client supports server-side batch imports" (now Python/TS/Java/C#; Go not yet) + a broken sentence.

Verification

All three new snippets were compiled and run end-to-end against a live Weaviate 1.38 (auto-schema on, matching CI) with the CI-pinned clients (TS 3.13.1, Java client6 6.3.0, C# 1.1.1):

  • TS data.ingest → 5 objects, titles persisted (assertion passes; fails on the old bare shape).
  • Java 6.3.0 → whole java-v6 module compiles (all 44 test classes), testServerSideBatchImport passes.
  • C# Batch.InsertMany → 5 objects, title persisted.
  • yarn build-dev succeeds; validate-links-dev shows 0 new broken links (new #manual-batching/#use-the-grpc-api anchors resolve; the preserved lower anchors still serve their inbound links).

Notes

  • Out of scope (flagged for later): the Python client-library reference page still teaches batch.dynamic()/fixed_size() without mentioning stream(); the tutorial and Python best-practices pages already lead SSB-first.
g-despot added 3 commits July 7, 2026 13:02
The "Server-side batching" section of manage-objects/import only had a
Python example (plus a placeholder C# reference). Fill in the clients
that support server-side batching (added in Weaviate v1.36):

- TypeScript: enable the data.ingest() example and wire the tab
- Java v6: implement the test using collection.batch.start() -> BatchContext
- C#: implement the test using collection.Batch.InsertMany()

Go has no server-side batching client API, so its tab stays "coming soon".

Verified: all three snippets compile and run against Weaviate 1.38 with the
CI-pinned client versions (TS v3.13.1, Java 6.2.0, C# 1.1.1).
The TypeScript server-side batching example passed bare objects ({ title })
to data.ingest(). Unlike data.insertMany(), data.ingest() does not treat a
bare object as properties on an untyped collection, so under auto-schema it
silently imported 5 objects with EMPTY properties (title dropped). Use the
DataObject wrapper ({ properties: { title } }) so the property persists, and
add a post-example fetchObjects() assertion that fails if the objects or
their titles are missing.
The java-v6 examples module depended on client6:6.2.1-SNAPSHOT (which no
release publishes, and the pom has no snapshot repository), while docs CI
built and installed client tag 6.2.0. That version lacks text2vecDigitalOcean
and the tokenize APIs, so ModelProvidersTest and TokenizationTest failed to
compile — breaking the whole module, including the new server-side batching
test. Pin both the dependency and the CI-built client to the released 6.2.1.

@orca-security-eu orca-security-eu 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.

Orca Security Scan Summary

Status Check Issues by priority
Passed Passed Infrastructure as Code high 0   medium 0   low 0   info 0 View in Orca
Passed Passed SAST high 0   medium 0   low 0   info 0 View in Orca
Passed Passed Secrets high 0   medium 0   low 0   info 0 View in Orca
Passed Passed Vulnerabilities high 0   medium 0   low 0   info 0 View in Orca
g-despot added 2 commits July 7, 2026 14:17
Restructure the batch-import guide so server-side (automatic) batching is the
first and recommended way to import data, instead of a separate feature section:

- Lead with server-side batching; present client-side batching as "Manual
  batching", the alternative for manual control or for the Go client.
- The Go tab points to manual batching (the Go client has no server-side
  batching API) instead of "coming soon".
- Note that server-side batching uses the gRPC API (enabled by default).
- concepts/data-import.mdx: correct the now-stale "only the Python client
  supports server-side batch imports" (now Python, TypeScript, Java, and C#;
  Go does not yet), and fix a broken sentence.
6.3.0 is the current release; it keeps the java-v6 examples module compiling
(text2vec-digitalocean + tokenize APIs) and passes the server-side batching
test. Supersedes the 6.2.1 pin from the previous commit.
@g-despot g-despot changed the title docs: add server-side batching snippets for TypeScript, Java, and C# docs: make server-side batching the default import method Jul 7, 2026
@g-despot g-despot merged commit 84b2d7f into main Jul 7, 2026
13 checks passed
@g-despot g-despot deleted the docs/server-side-batching-snippets branch July 7, 2026 12:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

1 participant