SpringJdbcKueryClientBuilder

Builder for a KueryBlockingClient backed by Spring Data JDBC.

Obtain an instance via SpringJdbcKueryClient.builder. dataSource is required; everything else is optional.

Functions

Link copied to clipboard
abstract fun build(): KueryBlockingClient
Link copied to clipboard
abstract fun converters(converters: List<Any>): SpringJdbcKueryClientBuilder

Sets custom converters used for both binding parameters and mapping rows, typically Spring Converters annotated with @WritingConverter / @ReadingConverter.

Link copied to clipboard

Sets the DataSource to execute SQL against. Required.

Link copied to clipboard
abstract fun enableAutoSqlIdGeneration(enableAutoSqlIdGeneration: Boolean): SpringJdbcKueryClientBuilder

Sets whether to automatically generate a sqlId for metrics when sql { ... } is called without an explicit sqlId. When observationRegistry is specified, the default is true; otherwise, the default is false.

Link copied to clipboard

Sets the KueryClientFetchObservationConvention used to customize the observation name and tags. When not set, KueryClientFetchObservationConvention.default is used.

Link copied to clipboard
abstract fun observationRegistry(observationRegistry: ObservationRegistry): SpringJdbcKueryClientBuilder

Sets the ObservationRegistry, enabling Micrometer Observation instrumentation (metrics/tracing) for each fetch.