Skip to main content

%Trace.Provider

class %Trace.Provider extends %Library.RegisteredObject

Store and retrieve a TracerProvider singleton for this Namespace. An application can define a TracerProvider at startup, and then save it using this class. Then all instrumentation code can access the single TracerProvider to create a Tracer.

Note that this uses temporary storage in the Namespace in which it's created, so it must be initialized at each startup.

Method Inventory

Methods

classmethod GetTracerProvider() as %Trace.TracerProvider
Retrieve the defined TracerProvider for this Namespace. If none has been defined, then a default NoopTracerProvider is returned.
classmethod IsDefined() as %Boolean
Determine if a TraceProvider has been defined for this Namespace. Note that GetTracerProvider() will return a default NoopTracerProvider if none has been defined. This will distinguish between that default or an intentionally defined NoopTracerProvider.
classmethod SetTracerProvider(Provider As %Trace.TracerProvider) as %Status
Save a defined TracerProvider for this Namespace.

Inherited Members

Inherited Methods

FeedbackOpens in a new tab