otel_cloud_functions 0.1.0
otel_cloud_functions: ^0.1.0 copied to clipboard
OpenTelemetry instrumentation for `package:cloud_functions`. Wraps HttpsCallable.call with `rpc.*` semconv spans for callable Firebase Functions.
Changelog #
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
0.1.0 - 2026-08-08 #
Added #
tracedHttpsCall(HttpsCallable, name:, parameters:)— wraps an [HttpsCallable.call] invocation in aCLIENTspan namedfirebase_functions <name>withrpc.system.name=firebase_functionsand a fully-qualifiedrpc.method=firebase_functions/<name>.tracedCloudFunctionCall<R>({name, invoke})— generic helper used internally and exposed for cases where you can't or don't want to use a realHttpsCallable(testing, custom transports).FirebaseFunctionsException.code-aware error handling:error.typeis set to the canonical Google Cloud RPC code name (not-found,permission-denied,unauthenticated, …). Generic exceptions fall back to the runtime class name.runWithoutCloudFunctionsInstrumentation/runWithoutCloudFunctionsInstrumentationAsync— zone-scoped suppression helpers.- Tests cover success, FirebaseFunctionsException error path,
generic exception fallback, suppression scope, and parent-span
inheritance via
startActiveSpan.