Class TraceCollector
- java.lang.Object
-
- org.eclipse.steady.java.monitor.trace.TraceCollector
-
public class TraceCollector extends Object
Offers callback methods used by the two trace instrumentorsSingleTraceInstrumentorandStackTraceInstrumentor. Prepares and uploads trace information to the backend and triggers the analysis of JAR files.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddTrace(ConstructId _id, ClassLoader _class_loader, URL _url, String _archive_digest, String _app_groupid, String _app_artifactid, String _app_version, Map<String,Serializable> _params)addTrace.voidawaitUpload()awaitUpload.static booleancallbackClinit(String _qname, ClassLoader _class_loader, URL _url, String _archive_digest, String _app_groupid, String _app_artifactid, String _app_version, Map<String,Serializable> _params)Callback method for instrumented class constructors.static booleancallbackConstructor(String _qname, ClassLoader _class_loader, URL _url, String _archive_digest, String _app_groupid, String _app_artifactid, String _app_version, Map<String,Serializable> _params)Callback method for instrumented class constructors.static booleancallbackMethod(String _qname, ClassLoader _class_loader, URL _url, String _archive_digest, String _app_groupid, String _app_artifactid, String _app_version, Map<String,Serializable> _params)Callback method for instrumented class methods.static TraceCollectorgetInstance()Getter for the fieldinstance.Map<String,Long>getStatistics()getStatistics.voiduploadInformation(AbstractGoal _exe, int batchSize)uploadInformation.voiduploadPaths(int _batch_size)Upload _batch_size paths gathered from stack trace information (all if _batch_size is negative).
-
-
-
Method Detail
-
getInstance
public static TraceCollector getInstance()
Getter for the field
instance.- Returns:
- a
TraceCollectorobject.
-
callbackMethod
public static boolean callbackMethod(String _qname, ClassLoader _class_loader, URL _url, String _archive_digest, String _app_groupid, String _app_artifactid, String _app_version, Map<String,Serializable> _params)
Callback method for instrumented class methods.- Parameters:
_qname- the qualified name of the method or constructor instrumented, thus, performing the callback_archive_digest- the SHA1 digest of the original JAR archive (optional, must be added to the class during offline instrumentation)_app_groupid- the Maven group Id of the application context (optional, can be added to the class during offline instrumentation)_app_artifactid- the Maven artifact Id of the application context (optional, see above)_app_version- the Maven version of the application context (optional, see above)_class_loader- aClassLoaderobject._url- aURLobject._params- aMapobject.- Returns:
- a boolean.
-
callbackConstructor
public static boolean callbackConstructor(String _qname, ClassLoader _class_loader, URL _url, String _archive_digest, String _app_groupid, String _app_artifactid, String _app_version, Map<String,Serializable> _params)
Callback method for instrumented class constructors.- Parameters:
_qname- the qualified name of the method or constructor instrumented, thus, performing the callback_archive_digest- the SHA1 digest of the original JAR archive (optional, must be added to the class during static instrumentation)_app_groupid- the Maven group Id of the application context (optional, can be added to the class during static instrumentation)_app_artifactid- the Maven artifact Id of the application context (optional, see above)_app_version- the Maven version of the application context (optional, see above)_class_loader- aClassLoaderobject._url- aURLobject._params- aMapobject.- Returns:
- a boolean.
-
callbackClinit
public static boolean callbackClinit(String _qname, ClassLoader _class_loader, URL _url, String _archive_digest, String _app_groupid, String _app_artifactid, String _app_version, Map<String,Serializable> _params)
Callback method for instrumented class constructors.- Parameters:
_qname- the qualified name of the method or constructor instrumented, thus, performing the callback_archive_digest- the SHA1 digest of the original JAR archive (optional, must be added to the class during static instrumentation)_app_groupid- the Maven group Id of the application context (optional, can be added to the class during static instrumentation)_app_artifactid- the Maven artifact Id of the application context (optional, see above)_app_version- the Maven version of the application context (optional, see above)_class_loader- aClassLoaderobject._url- aURLobject._params- aMapobject.- Returns:
- a boolean.
-
addTrace
public void addTrace(ConstructId _id, ClassLoader _class_loader, URL _url, String _archive_digest, String _app_groupid, String _app_artifactid, String _app_version, Map<String,Serializable> _params)
addTrace.
- Parameters:
_id- aConstructIdobject._class_loader- aClassLoaderobject._url- aURLobject._archive_digest- aStringobject._app_groupid- aStringobject._app_artifactid- aStringobject._app_version- aStringobject._params- aMapobject.
-
uploadInformation
public void uploadInformation(AbstractGoal _exe, int batchSize)
uploadInformation.
- Parameters:
_exe- aAbstractGoalobject.batchSize- a int.
-
awaitUpload
public void awaitUpload()
awaitUpload.
-
uploadPaths
public void uploadPaths(int _batch_size)
Upload _batch_size paths gathered from stack trace information (all if _batch_size is negative).- Parameters:
_batch_size- a int.
-
-