...
Level | Section | Description | Link to the discussion of unique identification |
---|---|---|---|
1 | Platform | The platform the agent is running on. | |
2 | JVM | On each platform can be multiple JVMs | |
3 | "Thread" | Within each JVM different threads are run | |
4 | method | Within one thread a method can be invoked multiple times |
|
...
- Each invocation of a method checks if an invocation sequence is currently active
- The staging area builds up a stack of all methods that are invoked within one "thread"
- This stack must be unique for each thread identification
- The data is sent to the CMR. Based on the JVM identification, the platform identification and the thread identification, the CMR can extend its stack of the methods of one invocation by adding the received stack to it. If no information is currently available, the CMR must assume that this was a new invocation.
...
Invocations within one thread are saved as a stack that is unique per thread identification. The invocation of an instrumented method within an invocation sequence will create two different information objects:
...
- The creation of a Runnable is an additional event that can be added to the
- We need to instrument the creation of a Runnable object and provide the following information
- the current thread identification of the current thread that created the Runnable
- the counter of how many asynchronous calls were already started within this thread
...
ID | unique across | Buildup |
---|---|---|
method invocation identification |
| static counter |
invocation sequence identification |
| JVM_ID + Thread ID |
- Active pushing of invocation sequence id from one thread to another
- hard to realize: how do we know that the next method instrumented will be invoked in a new thread
- at this point in time threadlocal information of the caller is no longer available
- It would be necessary to extend the method signature of all methods of all classes that inherit Thread / Runnable with an additional information (the invocation sequence) ... still very unclear
- Alternative would be to use JVM wide identification of the invocation sequence id with the respective thread
...