MCPcopy Index your code
hub / github.com/triggerdotdev/trigger.dev / getTracer

Function getTracer

references/v3-catalog/src/tracer.ts:13–40  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

11export const tracer = getTracer();
12
13function getTracer() {
14 diag.setLogger(new DiagConsoleLogger(), DiagLogLevel.ERROR);
15
16 const provider = new NodeTracerProvider({
17 forceFlushTimeoutMillis: 500,
18 resource: new Resource({
19 [SEMRESATTRS_SERVICE_NAME]: "v3-catalog",
20 }),
21 });
22
23 const loggerExporter = new ConsoleSpanExporter();
24 provider.addSpanProcessor(new SimpleSpanProcessor(loggerExporter));
25
26 provider.register();
27
28 let instrumentations: InstrumentationOption[] = [
29 new HttpInstrumentation(),
30 new FetchInstrumentation(),
31 new UndiciInstrumentation(),
32 ];
33
34 registerInstrumentations({
35 tracerProvider: provider,
36 instrumentations,
37 });
38
39 return provider.getTracer("v3-catalog", "3.0.0.dp.1");
40}

Callers 1

tracer.tsFile · 0.70

Calls 1

registerMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…