Package com.bytedance.rheatrace
Class RheaTrace3
- java.lang.Object
-
- com.bytedance.rheatrace.RheaTrace3
-
public class RheaTrace3 extends java.lang.ObjectThis is the only API class exposed externally by RheaTrace. Users are not expected to rely on other classes beyond this one.Note: RheaTrace only support main process tracing.
-
-
Constructor Summary
Constructors Constructor Description RheaTrace3()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidcaptureStackTrace(boolean force)Capture current stacktrace manually and save into RheaTrace sampling buffer for latter transforming to trace data.static voidinit(android.content.Context context)This is the entry point api for RheaTrace.
-
-
-
Method Detail
-
init
public static void init(android.content.Context context)
This is the entry point api for RheaTrace. The initialization stage includes two aspects: 1. If we are tracing app cold launch stage, we will start tracing immediately. 2. Start a http server for receiving latter tracing commands, such as start/stop tracing.- Parameters:
context- used for initializing tracing data directory
-
captureStackTrace
public static void captureStackTrace(boolean force)
Capture current stacktrace manually and save into RheaTrace sampling buffer for latter transforming to trace data.RheaTrace3 is a stacktrace based tracing tool. Inside of it, we've built in some hook points for active stack capturing. However, these hook points can't cover the execution of all methods. So, we offer this method to users. Users can decide to invoke it within appropriate methods to make up for the methods that our hook points fail to cover.
- Parameters:
force- if true, we will ignore the stacktrace capture interval limit and force capture a stacktrace.
-
-