MetricsConfig class

Configuration for the metrics interceptor.

Constructors

MetricsConfig({bool enabled = true, MetricsHandler? onMetrics, BreadcrumbHandler? onBreadcrumb, bool trackRequestSize = false, bool trackResponseSize = false, String requestIdGenerator()?})
const
MetricsConfig.disabled()
Creates a disabled config.
factory

Properties

enabled → bool
Whether metrics collection is enabled.
final
hashCode → int
The hash code for this object.
no setterinherited
onBreadcrumb → BreadcrumbHandler?
Handler for breadcrumbs.
final
onMetrics → MetricsHandler?
Handler for completed request metrics.
final
requestIdGenerator → String Function()?
Custom request ID generator.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
trackRequestSize → bool
Whether to include request size in metrics, in bytes — see RequestMetrics.requestSize.
final
trackResponseSize → bool
Whether to include response size in metrics, in bytes — see RequestMetrics.responseSize.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited