You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flink.apache.org by zh...@apache.org on 2020/02/29 05:50:42 UTC

[flink] 01/03: Revert "Fixup! [FLINK-16276][tests] Introduce a builder and factory methods to create DefaultScheduler for testing"

This is an automated email from the ASF dual-hosted git repository.

zhuzh pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/flink.git

commit 0abab7e6ade5e762fecf6b91a59cbc8ce80b0599
Author: Zhu Zhu <re...@gmail.com>
AuthorDate: Sat Feb 29 13:47:48 2020 +0800

    Revert "Fixup! [FLINK-16276][tests] Introduce a builder and factory methods to create DefaultScheduler for testing"
    
    This reverts commit 622bd31ab8e48afa120b9bb37e8fdc5fdb04f193.
---
 .../org/apache/flink/runtime/scheduler/SchedulerTestingUtils.java | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/flink-runtime/src/test/java/org/apache/flink/runtime/scheduler/SchedulerTestingUtils.java b/flink-runtime/src/test/java/org/apache/flink/runtime/scheduler/SchedulerTestingUtils.java
index 2a2c73e..b9d81e3 100644
--- a/flink-runtime/src/test/java/org/apache/flink/runtime/scheduler/SchedulerTestingUtils.java
+++ b/flink-runtime/src/test/java/org/apache/flink/runtime/scheduler/SchedulerTestingUtils.java
@@ -66,7 +66,7 @@ import org.apache.flink.runtime.shuffle.NettyShuffleMaster;
 import org.apache.flink.runtime.shuffle.ShuffleMaster;
 import org.apache.flink.runtime.taskexecutor.TaskExecutorOperatorEventGateway;
 import org.apache.flink.runtime.taskmanager.TaskExecutionState;
-import org.apache.flink.runtime.testingUtils.TestingUtils;
+import org.apache.flink.runtime.testutils.DirectScheduledExecutorService;
 import org.apache.flink.util.SerializedValue;
 
 import org.slf4j.Logger;
@@ -278,11 +278,11 @@ public class SchedulerTestingUtils {
 
 		private Logger log = LOG;
 		private BackPressureStatsTracker backPressureStatsTracker = VoidBackPressureStatsTracker.INSTANCE;
-		private Executor ioExecutor = TestingUtils.defaultExecutor();
+		private Executor ioExecutor = java.util.concurrent.Executors.newSingleThreadExecutor();
 		private Configuration jobMasterConfiguration = new Configuration();
-		private ScheduledExecutorService futureExecutor = TestingUtils.defaultExecutor();
+		private ScheduledExecutorService futureExecutor = new DirectScheduledExecutorService();
 		private ScheduledExecutor delayExecutor = new ScheduledExecutorServiceAdapter(futureExecutor);
-		private ClassLoader userCodeLoader = ClassLoader.getSystemClassLoader();
+		private ClassLoader userCodeLoader = getClass().getClassLoader();
 		private CheckpointRecoveryFactory checkpointRecoveryFactory = new StandaloneCheckpointRecoveryFactory();
 		private Time rpcTimeout = DEFAULT_TIMEOUT;
 		private BlobWriter blobWriter = VoidBlobWriter.getInstance();