public abstract class AbstractInstrumentationProvider extends Object implements InstrumentationProvider, Configurable
Constructor and Description |
---|
AbstractInstrumentationProvider() |
Modifier and Type | Method and Description |
---|---|
void |
addInstrument(Instrument instrument)
Adds an instrument to this providers list of managed instruments.
|
void |
endConfiguration()
Invoked upon completion of bean property configuration for this object.
|
Configuration |
getConfiguration()
Gets the configuration associated with the instrumentation provider
|
String |
getInstrument()
Returns the string-based list of instruments directly configured by
this provider via setInstrument.
|
String[] |
getInstrumentAliases()
Returns an string array of identifier to class name aliases for
instruments known to the instrumentation provider.
|
Instrument |
getInstrumentByName(String name)
Returns an instrument instrumented by this provider by name
|
Set<Instrument> |
getInstruments()
Gets all instruments instrumented by this provider
|
String |
getOptions()
Gets configuration options for this provider
|
void |
initializeInstrument(Instrument instrument,
Object context)
Initializes an instrument within the provided context.
|
void |
initializeInstrument(Instrument instrument,
String options,
Object context)
Initializes an instrument within the provided options and context.
|
boolean |
isStarted()
Whether the instrumentation provider started
|
void |
removeInstrumentByName(String name)
Removes an instrument instrumented by this provider by name
|
void |
setConfiguration(Configuration conf)
Invoked prior to setting bean properties.
|
void |
setInstrument(String instrument)
Used to associate one or more instruments to a provider.
|
void |
setOptions(String options)
Sets configuration options for this provider
|
protected void |
setStarted(boolean started) |
abstract void |
start()
Stops the instrumentation provider
|
void |
startConfiguration()
Invoked before bean property configuration is begun on this object.
|
void |
startInstruments(InstrumentationLevel level,
Object context)
Starts all instruments of the specified instrumentation level and context.
|
abstract void |
stop()
Starts the instrumentation provider
|
void |
stopInstrument(Instrument instrument)
Stops an instrument
|
void |
stopInstruments(InstrumentationLevel level,
Object context)
Stops all instruments of the specified instrumentation level and context.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
startInstrument, stopInstrument
public void setConfiguration(Configuration conf)
Configurable
setConfiguration
in interface Configurable
public Configuration getConfiguration()
InstrumentationProvider
getConfiguration
in interface InstrumentationProvider
public void startConfiguration()
Configurable
startConfiguration
in interface Configurable
public void endConfiguration()
Configurable
endConfiguration
in interface Configurable
public void setInstrument(String instrument)
InstrumentationProvider
setInstrument
in interface InstrumentationProvider
instrument
- one or more instrument class names or aliasespublic String getInstrument()
InstrumentationProvider
getInstrument
in interface InstrumentationProvider
public void setOptions(String options)
InstrumentationProvider
setOptions
in interface InstrumentationProvider
public String getOptions()
InstrumentationProvider
getOptions
in interface InstrumentationProvider
public void addInstrument(Instrument instrument)
InstrumentationProvider
addInstrument
in interface InstrumentationProvider
public void initializeInstrument(Instrument instrument, Object context)
InstrumentationProvider
initializeInstrument
in interface InstrumentationProvider
instrument
- an instrumentcontext
- instrumentation context (factory, broker, config)public void initializeInstrument(Instrument instrument, String options, Object context)
InstrumentationProvider
initializeInstrument
in interface InstrumentationProvider
instrument
- an instrumentoptions
- configuration options to provide the instrument during initializationcontext
- instrumentation context (factory, broker, config)public Instrument getInstrumentByName(String name)
InstrumentationProvider
getInstrumentByName
in interface InstrumentationProvider
name
- the name of the instrument to returnpublic Set<Instrument> getInstruments()
InstrumentationProvider
getInstruments
in interface InstrumentationProvider
public void stopInstruments(InstrumentationLevel level, Object context)
InstrumentationProvider
stopInstruments
in interface InstrumentationProvider
level
- instrumentation levelcontext
- instrumentation context (factory, broker, config)public void startInstruments(InstrumentationLevel level, Object context)
InstrumentationProvider
startInstruments
in interface InstrumentationProvider
level
- instrumentation levelcontext
- instrumentation context (factory, broker, config)public void stopInstrument(Instrument instrument)
InstrumentationProvider
stopInstrument
in interface InstrumentationProvider
instrument
- the instrument to stoppublic void removeInstrumentByName(String name)
InstrumentationProvider
removeInstrumentByName
in interface InstrumentationProvider
name
- the name of the instrument to removepublic boolean isStarted()
InstrumentationProvider
isStarted
in interface InstrumentationProvider
protected void setStarted(boolean started)
public String[] getInstrumentAliases()
InstrumentationProvider
getInstrumentAliases
in interface InstrumentationProvider
public abstract void start()
InstrumentationProvider
start
in interface InstrumentationProvider
public abstract void stop()
InstrumentationProvider
stop
in interface InstrumentationProvider
Copyright © 2006–2017 Apache Software Foundation. All rights reserved.