Class R2dbcPoolMetricsBinderFactory

java.lang.Object
io.micronaut.configuration.metrics.binder.r2dbc.R2dbcPoolMetricsBinderFactory

@Factory @RequiresMetrics @Requires(property="micronaut.metrics.binders.r2dbc.enabled", notEquals="false") public class R2dbcPoolMetricsBinderFactory extends Object
Instruments Micronaut related R2DBC pool metrics via Micrometer.
Since:
4.2.1
Author:
Leonardo Schick, Caroline Medeiros
  • Constructor Details

    • R2dbcPoolMetricsBinderFactory

      public R2dbcPoolMetricsBinderFactory()
  • Method Details

    • r2dbcPoolMeterBinder

      @EachBean(io.r2dbc.spi.ConnectionFactory.class) @Requires(beans=io.r2dbc.spi.ConnectionFactory.class) public io.micrometer.core.instrument.binder.MeterBinder r2dbcPoolMeterBinder(@Parameter String dataSourceName, io.r2dbc.spi.ConnectionFactory factory)
      Wires beans for each DataSource.
      Parameters:
      dataSourceName - The parameterized name of the datasource
      factory - The datasource factory object to use for the binder
      Returns:
      MeterBinders for each configured ConnectionFactory