fallintoplace opened a new pull request, #1967:
URL: https://github.com/apache/iceberg-go/pull/1967

   ## Summary
   
   - **Added schema ID indexes** to metadata and `MetadataBuilder`.
   - Keeps indexes current when schemas are added or removed.
   - Uses copy-on-write for builder clones and built metadata.
   - **Added regression tests and benchmarks** for lookup behavior, stale 
slices, cloning, and concurrent reads.
   
   ## Benchmark
   
   Command: `go test ./table -run ^ -bench 
"Benchmark(CommonMetadataSchemaByID|MetadataBuilderGetSchemaByID)" 
-benchtime=50ms -count=1`
   
   - **8,192 schemas, builder last:** about 9 ns/op indexed vs 7.4 us/op linear.
   - **8,192 schemas, builder miss:** about 150 ns/op indexed vs 7.8 us/op 
linear.
   - **8,192 schemas, metadata last:** about 200 ns/op indexed vs 7.7 us/op 
linear.
   - Metadata lookups still return defensive schema copies.
   
   ## Tests
   
   - `go test ./table -count=1`
   - `go test -race ./table -run 
"SchemaIndex|SchemaByID|MetadataBuilderCloneCoversAllFields" -count=1`
   - `go vet ./table`
   - `golangci-lint run --timeout=10m`


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to