Java Code Examples for org.apache.flink.runtime.jobgraph.tasks.JobCheckpointingSettings#getCheckpointCoordinatorConfiguration()
The following examples show how to use
org.apache.flink.runtime.jobgraph.tasks.JobCheckpointingSettings#getCheckpointCoordinatorConfiguration() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: CheckpointStatsTrackerTest.java From Flink-CEPplus with Apache License 2.0 | 5 votes |
/** * Tests access to the snapshotting settings. */ @Test public void testGetSnapshottingSettings() throws Exception { ExecutionJobVertex jobVertex = mock(ExecutionJobVertex.class); when(jobVertex.getJobVertexId()).thenReturn(new JobVertexID()); when(jobVertex.getParallelism()).thenReturn(1); JobCheckpointingSettings snapshottingSettings = new JobCheckpointingSettings( Collections.singletonList(new JobVertexID()), Collections.singletonList(new JobVertexID()), Collections.singletonList(new JobVertexID()), new CheckpointCoordinatorConfiguration( 181238123L, 19191992L, 191929L, 123, CheckpointRetentionPolicy.NEVER_RETAIN_AFTER_TERMINATION, false ), null); CheckpointStatsTracker tracker = new CheckpointStatsTracker( 0, Collections.singletonList(jobVertex), snapshottingSettings.getCheckpointCoordinatorConfiguration(), new UnregisteredMetricsGroup()); assertEquals(snapshottingSettings.getCheckpointCoordinatorConfiguration(), tracker.getJobCheckpointingConfiguration()); }
Example 2
Source File: CheckpointStatsTrackerTest.java From flink with Apache License 2.0 | 5 votes |
/** * Tests access to the snapshotting settings. */ @Test public void testGetSnapshottingSettings() throws Exception { ExecutionJobVertex jobVertex = mock(ExecutionJobVertex.class); when(jobVertex.getJobVertexId()).thenReturn(new JobVertexID()); when(jobVertex.getParallelism()).thenReturn(1); JobCheckpointingSettings snapshottingSettings = new JobCheckpointingSettings( Collections.singletonList(new JobVertexID()), Collections.singletonList(new JobVertexID()), Collections.singletonList(new JobVertexID()), new CheckpointCoordinatorConfiguration( 181238123L, 19191992L, 191929L, 123, CheckpointRetentionPolicy.NEVER_RETAIN_AFTER_TERMINATION, false, false, 0 ), null); CheckpointStatsTracker tracker = new CheckpointStatsTracker( 0, Collections.singletonList(jobVertex), snapshottingSettings.getCheckpointCoordinatorConfiguration(), new UnregisteredMetricsGroup()); assertEquals(snapshottingSettings.getCheckpointCoordinatorConfiguration(), tracker.getJobCheckpointingConfiguration()); }
Example 3
Source File: CheckpointStatsTrackerTest.java From flink with Apache License 2.0 | 5 votes |
/** * Tests access to the snapshotting settings. */ @Test public void testGetSnapshottingSettings() throws Exception { ExecutionJobVertex jobVertex = mock(ExecutionJobVertex.class); when(jobVertex.getJobVertexId()).thenReturn(new JobVertexID()); when(jobVertex.getParallelism()).thenReturn(1); JobCheckpointingSettings snapshottingSettings = new JobCheckpointingSettings( Collections.singletonList(new JobVertexID()), Collections.singletonList(new JobVertexID()), Collections.singletonList(new JobVertexID()), new CheckpointCoordinatorConfiguration( 181238123L, 19191992L, 191929L, 123, CheckpointRetentionPolicy.NEVER_RETAIN_AFTER_TERMINATION, false, false, false, 0 ), null); CheckpointStatsTracker tracker = new CheckpointStatsTracker( 0, Collections.singletonList(jobVertex), snapshottingSettings.getCheckpointCoordinatorConfiguration(), new UnregisteredMetricsGroup()); assertEquals(snapshottingSettings.getCheckpointCoordinatorConfiguration(), tracker.getJobCheckpointingConfiguration()); }