- java.lang.Object
- 
- io.helidon.tracing.config.Traceable
- 
- io.helidon.tracing.config.TracingConfig
 
 
- 
 public abstract class TracingConfig extends Traceable Tracing configuration that contains traced components (such as WebServer, Security) and their traced spans and span logs. Spans can be renamed through configuration, components, spans and span logs may be disabled through this configuration.- See Also:
- create(io.helidon.config.Config),- builder()
 
- 
- 
Nested Class SummaryNested Classes Modifier and Type Class Description static classTracingConfig.BuilderFluent API builder forTracingConfig.
 - 
Field SummaryFields Modifier and Type Field Description static TracingConfigDISABLEDTraced conifg that is disabled for all components, spans and logs.static TracingConfigENABLEDTraced config that is enabled for all components, spans and logs.
 - 
Constructor SummaryConstructors Modifier Constructor Description protectedTracingConfig(String name)A new traced configuration.
 - 
Method SummaryAll Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description static TracingConfig.Builderbuilder()A fluent API builder for tracing configuration.ComponentTracingConfigcomponent(String componentName)Configuration of a traced component.ComponentTracingConfigcomponent(String componentName, boolean enabledByDefault)Configuration of a traced component.static TracingConfigcreate(Config config)Create new tracing configuration based on the provided config.protected abstract Optional<ComponentTracingConfig>getComponent(String componentName)Configuration of a traced component.static TracingConfigmerge(TracingConfig older, TracingConfig newer)Merge two configurations together.SpanTracingConfigspanConfig(String component, String spanName)Return configuration of a specific span.StringtoString()
 
- 
- 
- 
Field Detail- 
ENABLEDpublic static final TracingConfig ENABLED Traced config that is enabled for all components, spans and logs.
 - 
DISABLEDpublic static final TracingConfig DISABLED Traced conifg that is disabled for all components, spans and logs.
 
- 
 - 
Constructor Detail- 
TracingConfigprotected TracingConfig(String name) A new traced configuration.- Parameters:
- name- name of this configuration, when created using- TracingConfig.Builder, the name is- helidon
 
 
- 
 - 
Method Detail- 
getComponentprotected abstract Optional<ComponentTracingConfig> getComponent(String componentName) Configuration of a traced component.- Parameters:
- componentName- name of the component
- Returns:
- component tracing configuration or empty if defaults should be used
 
 - 
componentpublic ComponentTracingConfig component(String componentName) Configuration of a traced component.- Parameters:
- componentName- name of the component
- Returns:
- component tracing configuration if configured, or an enabled component configuration
 
 - 
componentpublic ComponentTracingConfig component(String componentName, boolean enabledByDefault) Configuration of a traced component.- Parameters:
- componentName- name of the component
- enabledByDefault- whether the component should be enabled or disabled in case it is not configured
- Returns:
- component tracing configuration if configured, or an enabled/disabled component configuration depending on
          enabledByDefault
 
 - 
createpublic static TracingConfig create(Config config) Create new tracing configuration based on the provided config.- Parameters:
- config- configuration of tracing
- Returns:
- tracing configuration
 
 - 
builderpublic static TracingConfig.Builder builder() A fluent API builder for tracing configuration.- Returns:
- a new builder instance
 
 - 
mergepublic static TracingConfig merge(TracingConfig older, TracingConfig newer) Merge two configurations together. The result will combine configuration from both configurations. In case of conflicts, thenewerwins.- Parameters:
- older- older instance to merge
- newer- newer (more significant) instance to merge
- Returns:
- a new configuration combining odler and newer
 
 - 
spanConfigpublic SpanTracingConfig spanConfig(String component, String spanName) Return configuration of a specific span. This is a shortcut method tocomponent(String)andComponentTracingConfig.span(String).- Parameters:
- component- component, such as "web-server", "security"
- spanName- name of the span, such as "HTTP Request", "security:atn"
- Returns:
- configuration of the span if present in this traced system configuration
 
 
- 
 
-