Skip to content

Commit

Permalink
Clarify how to use processExistingClasses in debugging.adoc
Browse files Browse the repository at this point in the history
Improve the hint for alternative setups
  • Loading branch information
kicmeri committed Jul 28, 2022
1 parent 0ff9a38 commit 8b1b6dc
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions docs/asciidoc/debugging.adoc
Expand Up @@ -433,7 +433,7 @@ ReactorDebugAgent.init();
====

TIP: Since the implementation will instrument your classes when they are loaded,
the best place to put it is before everything else in your main(String[]) methood:
the best place to put it is before everything else in your main(String[]) method:
====
[source,java]
----
Expand All @@ -444,14 +444,12 @@ public static void main(String[] args) {
----
====

You may also re-process existing classes if you cannot run the init eagerly (e.g. in the tests):
You may also re-process existing classes with `processExistingClasses()` if you cannot run the init eagerly. For example, in https://junit.org/junit5/docs/current/user-guide/#launcher-api-listeners-custom[JUnit5 tests from a `TestExecutionListener`] or even in the class `static` initializer block:
====
[source,java]
----
static {
ReactorDebugAgent.init();
ReactorDebugAgent.processExistingClasses();
}
ReactorDebugAgent.init();
ReactorDebugAgent.processExistingClasses();
----
====

Expand Down

0 comments on commit 8b1b6dc

Please sign in to comment.