public class TestUtils extends Object
Constructor and Description |
---|
TestUtils() |
Modifier and Type | Method and Description |
---|---|
static File |
getMostRecentCompletedCheckpoint(File checkpointDir)
Deprecated.
please use
CommonTestUtils.getLatestCompletedCheckpointPath(JobID,
MiniCluster) which is less prone to NoSuchFileException and IO-intensive. |
static Optional<File> |
getMostRecentCompletedCheckpointMaybe(File checkpointDir)
Deprecated.
please use
CommonTestUtils.getLatestCompletedCheckpointPath(JobID,
MiniCluster) which is less prone to NoSuchFileException and IO-intensive. |
static CheckpointMetadata |
loadCheckpointMetadata(String savepointPath) |
static void |
submitJobAndWaitForResult(ClusterClient<?> client,
JobGraph jobGraph,
ClassLoader classLoader) |
static void |
tryExecute(StreamExecutionEnvironment see,
String name)
Execute the job and wait for the job result synchronously.
|
static void |
waitUntilExternalizedCheckpointCreated(File checkpointDir)
Deprecated.
please use
org.apache.flink.runtime.testutils.CommonTestUtils#waitForCheckpoint(JobID, MiniCluster,
Deadline) which is less prone to NoSuchFileException and IO-intensive. |
static void |
waitUntilJobCanceled(JobID jobId,
ClusterClient<?> client) |
public static void tryExecute(StreamExecutionEnvironment see, String name) throws Exception
Exception
- If executing the environment throws an exception which does not have SuccessException
as a cause.public static void submitJobAndWaitForResult(ClusterClient<?> client, JobGraph jobGraph, ClassLoader classLoader) throws Exception
Exception
public static CheckpointMetadata loadCheckpointMetadata(String savepointPath) throws IOException
IOException
@Deprecated public static File getMostRecentCompletedCheckpoint(File checkpointDir) throws IOException
CommonTestUtils.getLatestCompletedCheckpointPath(JobID,
MiniCluster)
which is less prone to NoSuchFileException
and IO-intensive.IOException
@Deprecated public static Optional<File> getMostRecentCompletedCheckpointMaybe(File checkpointDir) throws IOException
CommonTestUtils.getLatestCompletedCheckpointPath(JobID,
MiniCluster)
which is less prone to NoSuchFileException
and IO-intensive.IOException
@Deprecated public static void waitUntilExternalizedCheckpointCreated(File checkpointDir) throws InterruptedException, IOException
org.apache.flink.runtime.testutils.CommonTestUtils#waitForCheckpoint(JobID, MiniCluster,
Deadline)
which is less prone to NoSuchFileException
and IO-intensive.InterruptedException
IOException
public static void waitUntilJobCanceled(JobID jobId, ClusterClient<?> client) throws ExecutionException, InterruptedException
Copyright © 2014–2024 The Apache Software Foundation. All rights reserved.