fallintoplace opened a new pull request, #1941: URL: https://github.com/apache/iceberg-go/pull/1941
## Summary - **Reuse one staged schema** throughout UpdateSpec. - Avoid repeated defensive schema clones during partition field binding and final spec validation. - Keep the public defensive-copy behavior unchanged. - Add a focused benchmark for flat and nested large schemas. ## Benchmark Command: ``` GOMAXPROCS=1 go test -run '^$' -bench '^BenchmarkUpdateSpecBuildUpdates$' -benchmem -benchtime=500ms -count=5 ./table ``` Apple M1 Pro, darwin/arm64. Results are medians of five runs. | Case | Before | After | Speedup | Allocations | | --- | ---: | ---: | ---: | ---: | | 100 fields, 8 partitions, 4 additions | 0.714 ms | 0.152 ms | **4.7x** | 805 KB -> 139 KB | | 1,000 flat fields, 32 partitions, 16 additions | 29.73 ms | 1.46 ms | **20.3x** | 38.8 MB -> 1.75 MB | | 1,000 nested fields, 32 partitions, 16 additions | 91.74 ms | 3.70 ms | **24.8x** | 102.5 MB -> 3.74 MB | ## Checks - `go test ./table/... -count=1` - `go test` for all non-cloud packages - `go vet ./...` -- 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]
