Package io.opentelemetry.sdk.resources
Class ResourcesConfig
- java.lang.Object
-
- io.opentelemetry.sdk.resources.ResourcesConfig
-
@Immutable public abstract class ResourcesConfig extends Object
Class that holds global resources parameters.Configuration options for
ResourcesConfig
can be read from system properties, environment variables, orProperties
objects.For system properties and
Properties
objects,ResourcesConfig
will look for the following names:otel.java.disabled.resource_providers
: to set the fully qualified class names ofResourceProvider
implementations that are found on the classpath but should be disabled.
For environment variables,
ResourcesConfig
will look for the following names:OTEL_JAVA_DISABLED_RESOURCES_PROVIDERS
: to set the fully qualified class names ofResourceProvider
implementations that are found on the classpath but should be disabled.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ResourcesConfig.Builder
Builder forResourcesConfig
.
-
Constructor Summary
Constructors Constructor Description ResourcesConfig()
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description static ResourcesConfig.Builder
builder()
Returns a newResourcesConfig.Builder
.static ResourcesConfig
getDefault()
Returns the defaultResourcesConfig
.abstract Set<String>
getDisabledResourceProviders()
Returns the fully qualified class names ofResourceProvider
implementations that are found on the classpath but should be disabled.abstract ResourcesConfig.Builder
toBuilder()
Returns aResourcesConfig.Builder
initialized to the same property values as the current instance.
-
-
-
Method Detail
-
getDefault
public static ResourcesConfig getDefault()
Returns the defaultResourcesConfig
.- Returns:
- the default
ResourcesConfig
.
-
getDisabledResourceProviders
public abstract Set<String> getDisabledResourceProviders()
Returns the fully qualified class names ofResourceProvider
implementations that are found on the classpath but should be disabled.- Returns:
- the fully qualified class names of
ResourceProvider
implementations that are found on the classpath but should be disabled.
-
builder
public static ResourcesConfig.Builder builder()
Returns a newResourcesConfig.Builder
.- Returns:
- a new
ResourcesConfig.Builder
.
-
toBuilder
public abstract ResourcesConfig.Builder toBuilder()
Returns aResourcesConfig.Builder
initialized to the same property values as the current instance.- Returns:
- a
ResourcesConfig.Builder
initialized to the same property values as the current instance.
-
-