Skip to content

v0.5.1 - Simplified Chunking API

Choose a tag to compare

@botirkhaltaev botirkhaltaev released this 27 Nov 18:33
· 24 commits to master since this release

What's Changed

This patch release simplifies the chunking configuration API for better usability.

Refactoring

  • Simplified API: Replaced WithChunking(config) and WithoutChunking() with a single WithChunking(enabled bool, config ...chunker.ChunkConfig) function
  • Backward Compatible: Default chunking behavior remains unchanged (enabled by default)
  • Flexible Configuration: Optional config parameter allows custom chunking settings when enabling

API Changes

Before:

// Enable with custom config
options.WithChunking(customConfig)

// Disable chunking  
options.WithoutChunking()

After:

// Enable with defaults (unchanged default behavior)
options.WithChunking(true)

// Enable with custom config
options.WithChunking(true, customConfig)

// Disable chunking
options.WithChunking(false)

Testing

  • All existing tests pass
  • Updated test code to use new API
  • No breaking changes to functionality

Full Changelog: v0.5.0...v0.5.1