Skip to content

2.3.2

Choose a tag to compare

@guoshiqiufeng guoshiqiufeng released this 08 May 08:42
· 5 commits to main since this release
52519bc

Release Notes - Version 2.3.2

Overview

Version 2.3.2 is a maintenance release that addresses critical bugs in WebClient Buffer Limit Exception for Large Files.

Bug Fixes

1. WebClient Buffer Limit Exception for Large Files

  • Problem: DataBufferLimitException thrown when response body exceeds 256KB (default WebClient buffer limit).
  • Impact: Affected APIs returning large files (e.g., text-to-audio returning 472KB audio files).
  • Solution: Implemented streaming response handling to avoid buffer limits:
    • Changed from retrieve().toEntity(byte[].class) to exchangeToMono() with streaming
    • Used bodyToFlux(DataBuffer.class) to read data in chunks
    • Immediate DataBuffer release to prevent memory buildup
    • Merged chunks using reduce operation
  • Benefits:
    • Handles responses of any size without configuration changes
    • Consistent with Spring Boot 3 RestClient behavior
    • Improved exception handling and logging (debug → error level)
  • Affected components:
    • WebClientExecutor.executeForEntity() methods (both Class and TypeReference variants)
    • WebClientExecutorTest - Updated test mocks to use exchangeToMono()