spring-ai icon indicating copy to clipboard operation
spring-ai copied to clipboard

Support configuring BedrockCacheOptions via application.properties

Open choweiyuan opened this issue 1 week ago • 0 comments
trafficstars

Request

Please consider adding support for configuring BedrockCacheOptions via application configuration properties.

Description

At present, cache options for Bedrock—specifically BedrockCacheOptions and its underlying properties such as strategy—cannot be set via application.properties or application.yaml. In contrast, other options (like those in BedrockChatOptions, including maxTokens, model, etc.) can be configured using the spring.ai.bedrock.converse.chat.options.* properties.

It would be very helpful for Spring Boot users if BedrockCacheOptions could be made configurable via application properties in the same way.

Use Case Example

spring.ai.bedrock.converse.chat.options.cache-options=SYSTEM_AND_TOOLS

or similar, depending on property structure.

Benefit

Improves consistency with the rest of the options. Enables externalized configuration for different environments. Empowers users to avoid custom code just to tweak cache strategy.

choweiyuan avatar Nov 13 '25 10:11 choweiyuan