public class InstrumenterUtil extends Object
| Constructor and Description |
|---|
InstrumenterUtil() |
| Modifier and Type | Method and Description |
|---|---|
static org.hawkular.apm.api.model.config.CollectorConfiguration |
getCollectorConfiguration(String type,
String version,
boolean offline)
This method returns the complete collector configuration for the requested version.
|
static void |
initRuntime(org.hawkular.apm.api.model.config.CollectorConfiguration config)
This method initializes the instrumentation rules at runtime.
|
static boolean |
instrument(org.jboss.shrinkwrap.api.spec.JavaArchive archive,
org.hawkular.apm.api.model.config.CollectorConfiguration config)
This method attempts to instrument the classes within the supplied archive using
the instrumentation rules associated with the supplied configuration.
|
static void |
main(String[] args)
The main function for the instrumenter util.
|
public static void main(String[] args)
args - The archive path and config json pathpublic static boolean instrument(org.jboss.shrinkwrap.api.spec.JavaArchive archive,
org.hawkular.apm.api.model.config.CollectorConfiguration config)
archive - The archive to be instrumentedconfig - The instrumentation rulespublic static org.hawkular.apm.api.model.config.CollectorConfiguration getCollectorConfiguration(String type, String version, boolean offline) throws Exception
type - The client environment typeversion - The versionoffline - Whether to obtain the config offline (otherwise contacts remove maven repo)Exception - Failed to get collector configurationpublic static void initRuntime(org.hawkular.apm.api.model.config.CollectorConfiguration config)
config - The collector configurationCopyright © 2015–2016 Red Hat, Inc.. All rights reserved.