File tree Expand file tree Collapse file tree 4 files changed +6
-10
lines changed
main/java/org/apache/flink/runtime/scheduler
test/java/org/apache/flink/runtime/scheduler/adaptive Expand file tree Collapse file tree 4 files changed +6
-10
lines changed Original file line number Diff line number Diff line change @@ -225,7 +225,7 @@ public SchedulerBase(
225
225
226
226
final CheckpointStatsTracker checkpointStatsTracker =
227
227
SchedulerUtils .createCheckpointStatsTrackerIfCheckpointingIsEnabled (
228
- jobGraph . getCheckpointingSettings () ,
228
+ jobGraph ,
229
229
() ->
230
230
new DefaultCheckpointStatsTracker (
231
231
jobMasterConfiguration .get (
Original file line number Diff line number Diff line change 33
33
import org .apache .flink .runtime .client .JobExecutionException ;
34
34
import org .apache .flink .runtime .executiongraph .DefaultExecutionGraphBuilder ;
35
35
import org .apache .flink .runtime .jobgraph .JobGraph ;
36
- import org .apache .flink .runtime .jobgraph .tasks .JobCheckpointingSettings ;
37
36
import org .apache .flink .runtime .state .SharedStateRegistry ;
38
37
39
38
import org .slf4j .Logger ;
40
39
41
- import javax .annotation .Nullable ;
42
-
43
40
import java .util .concurrent .Executor ;
44
41
import java .util .function .Supplier ;
45
42
@@ -114,12 +111,9 @@ public static CheckpointIDCounter createCheckpointIDCounterIfCheckpointingIsEnab
114
111
}
115
112
116
113
public static CheckpointStatsTracker createCheckpointStatsTrackerIfCheckpointingIsEnabled (
117
- @ Nullable JobCheckpointingSettings checkpointingSettings ,
114
+ JobGraph checkpointingSettings ,
118
115
Supplier <CheckpointStatsTracker > checkpointStatsTrackerFactory ) {
119
- if (checkpointingSettings != null
120
- && checkpointingSettings
121
- .getCheckpointCoordinatorConfiguration ()
122
- .isCheckpointingEnabled ()) {
116
+ if (DefaultExecutionGraphBuilder .isCheckpointingEnabled (checkpointingSettings )) {
123
117
return checkpointStatsTrackerFactory .get ();
124
118
} else {
125
119
return NoOpCheckpointStatsTracker .INSTANCE ;
Original file line number Diff line number Diff line change @@ -512,7 +512,7 @@ public AdaptiveScheduler(
512
512
jobGraph , checkpointRecoveryFactory );
513
513
this .checkpointStatsTracker =
514
514
SchedulerUtils .createCheckpointStatsTrackerIfCheckpointingIsEnabled (
515
- jobGraph . getCheckpointingSettings () ,
515
+ jobGraph ,
516
516
() ->
517
517
checkpointStatsTrackerFactory .apply (
518
518
jobManagerJobMetricGroup , createCheckpointStatsListener ()));
Original file line number Diff line number Diff line change 94
94
import org .apache .flink .runtime .scheduler .DefaultSchedulerTest ;
95
95
import org .apache .flink .runtime .scheduler .SchedulerBase ;
96
96
import org .apache .flink .runtime .scheduler .SchedulerNG ;
97
+ import org .apache .flink .runtime .scheduler .SchedulerTestingUtils ;
97
98
import org .apache .flink .runtime .scheduler .TestingPhysicalSlot ;
98
99
import org .apache .flink .runtime .scheduler .VertexParallelismInformation ;
99
100
import org .apache .flink .runtime .scheduler .VertexParallelismStore ;
@@ -2228,6 +2229,7 @@ private AdaptiveScheduler createSchedulerThatReachesExecutingState(
2228
2229
.build (),
2229
2230
null ))
2230
2231
.build ();
2232
+ SchedulerTestingUtils .enableCheckpointing (jobGraph );
2231
2233
2232
2234
// testing SlotPool instance that would allow for the scheduler to transition to Executing
2233
2235
// state
You can’t perform that action at this time.
0 commit comments