use of edu.iu.dsc.tws.api.JobConfig in project twister2 by DSC-SPIDAL.
the class WordCountJob method main.
public static void main(String[] args) {
// first load the configurations from command line and config files
Config config = ResourceAllocator.loadConfig(new HashMap<>());
// build JobConfig
JobConfig jobConfig = new JobConfig();
BasicJob.BasicJobBuilder jobBuilder = BasicJob.newBuilder();
jobBuilder.setName("batch-wordcount");
jobBuilder.setContainerClass(WordCountContainer.class.getName());
jobBuilder.setRequestResource(new ResourceContainer(2, 1024), 4);
jobBuilder.setConfig(jobConfig);
// now submit the job
Twister2Submitter.submitContainerJob(jobBuilder.build(), config);
}
use of edu.iu.dsc.tws.api.JobConfig in project twister2 by DSC-SPIDAL.
the class BaseAllReduceCommunication method main.
public static void main(String[] args) {
// first load the configurations from command line and config files
Config config = ResourceAllocator.loadConfig(new HashMap<>());
// build JobConfig
JobConfig jobConfig = new JobConfig();
// build the job
BasicJob basicJob = BasicJob.newBuilder().setName("basic-all-reduce").setContainerClass(BaseAllReduceCommunication.class.getName()).setRequestResource(new ResourceContainer(2, 1024), 4).setConfig(jobConfig).build();
// now submit the job
Twister2Submitter.submitContainerJob(basicJob, config);
}
use of edu.iu.dsc.tws.api.JobConfig in project twister2 by DSC-SPIDAL.
the class BaseBroadcastCommunication method main.
public static void main(String[] args) {
// first load the configurations from command line and config files
Config config = ResourceAllocator.loadConfig(new HashMap<>());
// build JobConfig
JobConfig jobConfig = new JobConfig();
// build the job
BasicJob basicJob = BasicJob.newBuilder().setName("basic-broadcast").setContainerClass(BaseBroadcastCommunication.class.getName()).setRequestResource(new ResourceContainer(2, 1024), 4).setConfig(jobConfig).build();
// now submit the job
Twister2Submitter.submitContainerJob(basicJob, config);
}
use of edu.iu.dsc.tws.api.JobConfig in project twister2 by DSC-SPIDAL.
the class BaseReduceBatchCommunication method main.
public static void main(String[] args) {
// first load the configurations from command line and config files
Config config = ResourceAllocator.loadConfig(new HashMap<>());
// build JobConfig
JobConfig jobConfig = new JobConfig();
// build the job
BasicJob basicJob = BasicJob.newBuilder().setName("basic-batch-reduce").setContainerClass(BaseReduceBatchCommunication.class.getName()).setRequestResource(new ResourceContainer(2, 1024), 4).setConfig(jobConfig).build();
// now submit the job
Twister2Submitter.submitContainerJob(basicJob, config);
}
use of edu.iu.dsc.tws.api.JobConfig in project twister2 by DSC-SPIDAL.
the class BaseReduceHLCommunication method main.
public static void main(String[] args) {
// first load the configurations from command line and config files
Config config = ResourceAllocator.loadConfig(new HashMap<>());
// build JobConfig
JobConfig jobConfig = new JobConfig();
// build the job
BasicJob basicJob = BasicJob.newBuilder().setName("basic-hl-reduce").setContainerClass(BaseReduceHLCommunication.class.getName()).setRequestResource(new ResourceContainer(2, 1024), 4).setConfig(jobConfig).build();
// now submit the job
Twister2Submitter.submitContainerJob(basicJob, config);
}
Aggregations