@fougere/observability
Optional observability for Fougere: one span per operation, W3C Trace Context across any transport.
Use it
npm install @fougere/observability
pnpm add @fougere/observability
bun add @fougere/observability
yarn add @fougere/observability
// fougere.config.ts
export default defineFougere({
fronds: { '@fougere/observability': {} },
});
The key names the package, and every process that reads the config calls its observability() export and rises with it. Options that are more than a word go where the extension is built — in a frond's extensions/, or in createApp({ extensions }).
Entries: @fougere/observability
What you import
| name | |
|---|---|
currentSpan | The step running here and now. The step running right now, if any. |
activeCalls | |
flushTelemetry | Send what is buffered, now. |
registerFlush | Declare an exporter's flush, and answer the way to withdraw it — like onSpan. |
tracing | The tracer of one app, handed who takes the spans it finishes. |
statementsUnder | Charges each statement to the operation it ran under, read off the async context. |
otlp | |
metrics | app feeds the topology: which fronds this process found, and which run elsewhere. |
logs | |
observability | Observe this process — one member of the ascent. |
Types
TypeScript types only — they do not run. Import them with import type to type your own code: a variable, a parameter, an option object.
| name | |
|---|---|
SpanKind | What a span is a span of: an operation, or a statement under one. |
Crossing | Which end of a hop an operation span stands at — absent when the call stayed in this process. |
FinishedSpan | A step that has finished, and what it did. |
SpanSink | |
Statement | A statement as its producer describes it — never the values it was given. |
Tracing | What an app's tracer answers for. |
TracingOptions | |
Metrics | |
TopologyReport | |
FrondPlacement | |
Edge |