You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/BTraceTutorial.md
+8-2Lines changed: 8 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -374,7 +374,9 @@ public class HelloWorldTrace {
374
374
14. Tracing methods invoked from inside a particular method
375
375
376
376
__Note:__ 'class', 'method' etc. directly in the @OnMethod annotation will determine where we should look for the invocation of the methods defined by 'class', 'method' etc. parameters in the @Location annotation.
377
+
377
378
__Note:__@ProbeMethodName and @ProbeClassName refer to the context method and class; @TargetMethodOrField refers to the traced method invocation
379
+
378
380
__Note:__ You can use the 'type' annotation parameter in @OnMethod annotation to restrict the context methods and in @Location to restrict the traced method invocations
379
381
380
382
```java
@@ -422,6 +424,7 @@ public class HelloWorldTrace {
422
424
16. Tracing methods invoked from inside a particular method and capturing their parameters
423
425
424
426
__Note:__ The captured parameters pertain to the invoked method rather than the context method
427
+
425
428
__Note:__ The @Self annotated parameter captures the context instance and @TargetInstance annotated parameter captures the instance the method is invoked on
426
429
427
430
```java
@@ -494,6 +497,7 @@ public class HelloWorldTrace {
494
497
Allows to register a handler to be invoked periodically at defined intervals.
495
498
496
499
__Note:__ The annotation parameter takes the interval value in milliseconds
500
+
497
501
__Note:__ The signature of the handler method __MUST__ be 'void ()'
498
502
499
503
```java
@@ -569,8 +573,10 @@ public class HelloWorldTrace {
569
573
570
574
2. Let the sampler mean parameter be adjusted dynamically by keeping to the overhead target
571
575
572
-
__Note:__ In this case the 'mean' parameter actually specify the lowest number of nanoseconds the average interval between interception should be.
573
-
__Note:__ Because the adaptive sampling needs to collect timestamps in order to maintain the overhead target the lowest value for the 'mean' parameter is 180 (cca. 60ns for gettint start/stop timestamp pair multiplied by the safety margin of 3)
576
+
__Note:__ In this case the 'mean' parameter actually specify the lowest number of nanoseconds the average interval between interception should be
577
+
578
+
__Note:__ Because the adaptive sampling needs to collect timestamps in order to maintain the overhead target the lowest value for the 'mean' parameter is 180 (cca. 60ns for getting start/stop timestamp pair multiplied by the safety margin of 3)
579
+
574
580
__Note:__ The 'callD' method is very short and the number of iteration is rather limited - we will most probably get only one hit here
0 commit comments