flink-instrumentation/workspace/flink-1.4.1-instrumented/flink-1.4.1/flink-runtime/src/test/java/org/apache/flink/runtime/rpc/akka/AkkaRpcActorTest.java
/**
	 * Checks that the postStop callback is executed within the main thread.
	 */
Checks that the postStop callback is executed within the main thread.
Checks that the postStop callback is executed within the main thread .
@Test
	public void testPostStopExecutedByMainThread() throws Exception {
		SimpleRpcEndpoint simpleRpcEndpoint = new SimpleRpcEndpoint(akkaRpcService, "SimpleRpcEndpoint");
		simpleRpcEndpoint.start();
		simpleRpcEndpoint.shutDown();
		CompletableFuture<Boolean> terminationFuture = simpleRpcEndpoint.getTerminationFuture();
		terminationFuture.get();
	}
@ Test public void testPostStopExecutedByMainThread ( ) throws Exception { SimpleRpcEndpoint simpleRpcEndpoint = new SimpleRpcEndpoint ( akkaRpcService , "SimpleRpcEndpoint" ) ; simpleRpcEndpoint . start ( ) ; simpleRpcEndpoint . shutDown ( ) ; CompletableFuture < Boolean > terminationFuture = simpleRpcEndpoint . getTerminationFuture ( ) ; terminationFuture . get ( ) ; }
Checks that the postStop callback is executed within the main thread.
Checks that the postStop callback is executed within the main thread .
// check that we executed the postStop method in the main thread, otherwise an exception // would be thrown here.