提交 5ca06400 编写于 作者: G Greg Hogan

[hotfix] [runtime] Fix tests for JobManager metrics

上级 0efa6441
......@@ -148,7 +148,8 @@ public class JobManagerHARecoveryTest {
mySubmittedJobGraphStore,
new StandaloneCheckpointRecoveryFactory(),
new SavepointStore(new HeapStateStore()),
jobRecoveryTimeout);
jobRecoveryTimeout,
Option.apply(null));
jobManager = system.actorOf(jobManagerProps, "jobmanager");
ActorGateway gateway = new AkkaActorGateway(jobManager, leaderSessionID);
......
......@@ -19,7 +19,6 @@ package org.apache.flink.runtime.jobmanager;
import org.apache.flink.configuration.Configuration;
import org.apache.flink.runtime.jobgraph.JobGraph;
import org.apache.flink.runtime.jobgraph.JobStatus;
import org.apache.flink.runtime.jobgraph.JobVertex;
import org.apache.flink.runtime.jobgraph.JobVertexID;
import org.apache.flink.runtime.jobgraph.tasks.AbstractInvokable;
......@@ -74,7 +73,7 @@ public class JobManagerMetricTest {
flink.submitJobDetached(jobGraph);
Future<Object> jobRunning = flink.getLeaderGateway(deadline.timeLeft())
.ask(new TestingJobManagerMessages.NotifyWhenJobStatus(jobGraph.getJobID(), JobStatus.RUNNING), deadline.timeLeft());
.ask(new TestingJobManagerMessages.WaitForAllVerticesToBeRunning(jobGraph.getJobID()), deadline.timeLeft());
Await.ready(jobRunning, deadline.timeLeft());
MBeanServer mBeanServer = ManagementFactory.getPlatformMBeanServer();
......
......@@ -52,6 +52,7 @@ import org.junit.BeforeClass;
import org.junit.Rule;
import org.junit.Test;
import org.junit.rules.TemporaryFolder;
import scala.Option;
import scala.concurrent.Await;
import scala.concurrent.Future;
import scala.concurrent.duration.FiniteDuration;
......@@ -198,7 +199,8 @@ public class JobManagerLeaderElectionTest extends TestLogger {
submittedJobGraphStore,
checkpointRecoveryFactory,
savepointStore,
AkkaUtils.getDefaultTimeout()
AkkaUtils.getDefaultTimeout(),
Option.apply(null)
);
}
}
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册