use of io.cdap.cdap.app.runtime.spark.distributed.DistributedSparkProgramRunner in project cdap by caskdata.
the class DistributedProgramRunnerTxTimeoutTest method setup.
@BeforeClass
public static void setup() {
Application app = new AppWithAllProgramTypes();
DefaultAppConfigurer configurer = new DefaultAppConfigurer(Id.Namespace.DEFAULT, new Id.Artifact(Id.Namespace.DEFAULT, "artifact", new ArtifactVersion("0.1")), app);
app.configure(configurer, () -> null);
appSpec = configurer.createSpecification("app", "1.0");
// System.out.println(new GsonBuilder().setPrettyPrinting().create().toJson(appSpec));
cConf.setInt(TxConstants.Manager.CFG_TX_MAX_TIMEOUT, 60);
serviceRunner = new DistributedServiceProgramRunner(cConf, yConf, null, ClusterMode.ON_PREMISE, null);
workerRunner = new DistributedWorkerProgramRunner(cConf, yConf, null, ClusterMode.ON_PREMISE, null);
mapreduceRunner = new DistributedMapReduceProgramRunner(cConf, yConf, null, ClusterMode.ON_PREMISE, null);
sparkRunner = new DistributedSparkProgramRunner(SparkCompat.SPARK2_2_11, cConf, yConf, null, null, ClusterMode.ON_PREMISE, null);
workflowRunner = new DistributedWorkflowProgramRunner(cConf, yConf, null, ClusterMode.ON_PREMISE, null, null);
}
Aggregations