Tips on using AsyncInvocation: * Always use await() or get() * Both check and throw any remote exceptions * Both use GeodeAwaitility Timeout and will throw TimeoutException if it’s exceeded * Use await() for Void types and get() when expecting a non-null value
Recent improvements: Timeout now gets a remote stack trace to use as the cause and dumps stack traces for that JVM’s threads. You can also declare your instance of AsyncInvocation as a Future and simply use the standard Java API for Futures. This basically means the test will invoke get() for both Void and non-Void types. AsyncInvocation handles everything for you when you invoke await() or get() -- there is no need to invoke any of the deprecated APIs on AsyncInvocation: * Both use the GeodeAwaitility Timeout and throw TImeoutException * If Timeout occurs, AsyncInvocation will use the remote stack trace of the stuck thread as the cause and it will also print all threads stacks for that DUnit VM to facilitate debugging * Both will check for a remote failure and rethrow it