Package com.intergral.deep.agent.api
Interface IDeep
-
public interface IDeep
This type describes the main API for Deep.This API can only be used after the agent has been loaded.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description String
getVersion()
Get the version of deep being used.boolean
isEnabled()
Get the current state of deep.IRegistration<IDeepPlugin>
registerPlugin(IDeepPlugin plugin)
This allows the registration of custom plugins.ITracepoint.ITracepointRegistration
registerTracepoint(String path, int line)
Create a tracepoint that will only exist on this instance.ITracepoint.ITracepointRegistration
registerTracepoint(String path, int line, Map<String,String> args, Collection<String> watches, Collection<MetricDefinition> metrics)
Create a tracepoint that will only exist on this instance.void
setEnabled(boolean enabled)
This method can be used to disabled or enable Deep.
-
-
-
Method Detail
-
isEnabled
boolean isEnabled()
Get the current state of deep.- Returns:
true
if deep is currently enabled and sending requests, elsefalse
-
setEnabled
void setEnabled(boolean enabled)
This method can be used to disabled or enable Deep.Changing the state to
false
(ie disabled) will cause deep to uninstall all the tracepoints and clear the current config. Meaning that when deep is enabled again it will have to reinstall the configuration. It is therefore advised to not call this function too frequently.- Parameters:
enabled
- the new state to become
-
getVersion
String getVersion()
Get the version of deep being used.- Returns:
- the sematic version of deep as a string e.g. 1.2.3
-
registerPlugin
IRegistration<IDeepPlugin> registerPlugin(IDeepPlugin plugin)
This allows the registration of custom plugins.- Parameters:
plugin
- the plugin that can be used to decorate snapshots- Returns:
- a
IRegistration
that can be used to unregister the plugin
-
registerTracepoint
ITracepoint.ITracepointRegistration registerTracepoint(String path, int line)
Create a tracepoint that will only exist on this instance.- Parameters:
path
- the path to the fileline
- the line number- Returns:
- a
ITracepoint.ITracepointRegistration
that can be used to remove the tracepoint
-
registerTracepoint
ITracepoint.ITracepointRegistration registerTracepoint(String path, int line, Map<String,String> args, Collection<String> watches, Collection<MetricDefinition> metrics)
Create a tracepoint that will only exist on this instance.- Parameters:
path
- the path to the fileline
- the line numberargs
- the key value pairs that further define the tracepointwatches
- the list of watch expressionsmetrics
- the list of metric expressions- Returns:
- a
ITracepoint.ITracepointRegistration
that can be used to remove the tracepoint
-
-