`maintained_indexes` on a MemWAL table has three values: a named list, `[]` for none, and `null` for every index the table has, including ones created later. This PR makes every client read all three back as they were set. - **Rust remote client** (also used by the Python and Node SDKs) reads `null` as `None`. - **Java client** reads `null` as `null`, not as an empty list. - **Docs** for the setter, the field and the getter describe the three values the same way in Rust, Python, Node and Java. The generated JS docs are regenerated to match. ## Testing - `rust/lancedb`: 73 LSM tests pass, including one case per value. With the decoder typed as a list, the `null` case fails. - Java: two cases for `null` and `[]` on the read path, run by the Java CI job. - `cargo fmt`, `cargo clippy -D warnings` and `ruff format` are clean.
1.3 KiB
@lancedb/lancedb • Docs
@lancedb/lancedb / LsmWriteSpec
Interface: LsmWriteSpec
Specification selecting Lance's MemWAL LSM-style write path for
mergeInsert.
specType is "bucket", "identity", or "unsharded". For "bucket",
column and numBuckets are required; for "identity", column is
required and must be a deterministic function of the unenforced primary
key (every row with a given primary key must always produce the same
column value, or upserts of that key can land in different shards and a
stale version can win).
Properties
column?
optional column: string;
Bucket and identity variants: the sharding column.
maintainedIndexes?
optional maintainedIndexes: string[];
Indexes the MemWAL keeps up to date. Omit for every index the table has,
including ones created later. Pass [] for none.
numBuckets?
optional numBuckets: number;
Bucket variant: the number of buckets, in [1, 1024].
specType
specType: "bucket" | "identity" | "unsharded";
One of "bucket", "identity", or "unsharded".
writerConfigDefaults?
optional writerConfigDefaults: Record<string, string>;
Default ShardWriter configuration recorded in the MemWAL index.