InitializationParams class
Configuration passed to VuTelemetry.initialize.
Values are forwarded to the native layer (via OpentelemetryPlatform), which owns the resource, session, and telemetry egress. Attribute management is native-side: the VuNet agent applies globalAttributes/resourceAttributes to every native span/log and the SpanBridge stamps the same set onto bridged Dart spans.
Constructors
-
InitializationParams({required String baseUri, required String appName, required String apiKey, required String buildType, InstrumentationsConfig instrumentations = const InstrumentationsConfig(), String? serviceName, Map<
String, String> globalAttributes = const {}, Map<String, String> resourceAttributes = const {}, Duration actionWindowDuration = const Duration(milliseconds: 500), List<String> captureRequestHeaders = const [], List<String> captureResponseHeaders = const [], Map<String, String> peerServiceByHost = const {}, SdkLogLevel logLevel = SdkLogLevel.info, HttpConnectionFactory? httpConnectionFactory})
Properties
- actionWindowDuration → Duration
-
How long a user-interaction / navigation "action window" stays open after
it is opened. While open, every Dart span created through the tracer
auto-parents to the action span (same trace tree), and native span
creators can parent to the shared action context until it expires.
final
- apiKey → String
-
The API key for authentication.
final
- appName → String
-
final
- baseUri → String
-
OTLP ingest base URI (e.g.
https://collector.exampleorhttp://10.0.2.2:4318). Native derives per-signal endpoints (/v1/traces,/v1/logs) from this base.final - buildType → String
-
The type of build (e.g., 'debug', 'release', 'uat')
final
-
captureRequestHeaders
→ List<
String> -
Request header names to record as
http.request.header.<name>on HTTP client spans. Empty (default) means no request headers are captured.final -
captureResponseHeaders
→ List<
String> -
Response header names to record as
http.response.header.<name>on HTTP client spans. Empty (default) means no response headers are captured.final -
globalAttributes
→ Map<
String, String> -
App-wide global (span-level) attributes, managed by the native layer.
The VuNet agent merges them onto every native span/log, and the native
SpanBridge stamps the same set onto every bridged Dart span. Update at
runtime with VuTelemetry.setCustomAttribute/VuTelemetry.setCustomAttributes.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- httpConnectionFactory → HttpConnectionFactory?
-
The app's own
dart:ioHttpClient connection factory, when it has one.final - instrumentations → InstrumentationsConfig
-
Dart auto-instrumentation enable/disable flags. See InstrumentationsConfig.
final
- logLevel → SdkLogLevel
-
Developer-facing SDK diagnostics verbosity. Defaults to SdkLogLevel.info.
final
-
peerServiceByHost
→ Map<
String, String> -
Maps
server.address(host) →peer.servicefor HTTP client spans. Empty (default) meanspeer.serviceis omitted.final -
resourceAttributes
→ Map<
String, String> -
Extra resource attributes, fixed at initialisation and managed natively:
applied to the VuNet agent's resource (native spans/logs) and to the
resource of bridged Dart spans.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- serviceName → String?
-
The OpenTelemetry
service.name. Native owns the resource and applies this to all spans (native-origin and Flutter-bridged). Defaults to appName.final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited