WRENCH  1.10
Cyberinfrastructure Simulation Workbench
Overview Installation Getting Started WRENCH 101 WRENCH 102
Creating a HTCondor compute service

Overview

HTCondor is a workload management framework that supervises task executions on various sets of resources. HTCondor is composed of six main service daemons (startd, starter, schedd, shadow, negotiator, and collector). In addition, each host on which one or more of these daemons is spawned must also run a master daemon, which controls the execution of all other daemons (including initialization and completion).

Creating an HTCondor Service

HTCondor is composed of a pool of resources in which jobs are submitted to perform their computation. In WRENCH, an HTCondor service represents a compute service (wrench::ComputeService), which is defined by the wrench::HTCondorComputeService class. An instantiation of an HTCondor service requires the following parameters:

The set of compute services may include compute service instances that are either wrench::BareMetalComputeService or wrench::BatchComputeService instances. The example below creates an instance of an HTCondor service with a pool of resources containing a Bare-metal server:

// Simulation
wrench::Simulation simulation;
simulation.init(&argc, argv);
// Create a bare-metal service
auto baremetal_service = simulation.add(
"execution_hostname",
{std::make_pair(
"execution_hostname",
std::make_tuple(wrench::Simulation::getHostNumCores("execution_hostname"),
"/scratch/"));
std::set<std::shared_ptr<wrench::ComputeService>> compute_services;
compute_services.insert(baremetal_service);
auto htcondor_compute_service = simulation->add(
std::move(compute_services),
));

Jobs submitted to the wrench::HTCondorComputeService instance will be dispatched automatically to one of the 'child' compute services available to that instance (only one in the above example).

wrench::Simulation::add
std::shared_ptr< T > add(T *t)
Method to add a service to the simulation.
Definition: Simulation.h:74
wrench::HTCondorComputeService
A workload management framework compute service.
Definition: HTCondorComputeService.h:27
wrench::BareMetalComputeService
A compute service that manages a set of multi-core compute hosts and provides access to their resourc...
Definition: BareMetalComputeService.h:48
wrench::Simulation::init
void init(int *, char **)
Initialize the simulation, which parses out WRENCH-specific and SimGrid-specific command-line argumen...
Definition: Simulation.cpp:97
wrench::Simulation::getHostMemoryCapacity
static double getHostMemoryCapacity(std::string hostname)
Get the memory_manager_service capacity of a host given a hostname.
Definition: Simulation.cpp:1014
wrench::Simulation::getHostNumCores
static unsigned long getHostNumCores(std::string hostname)
Get the number of cores of a host given a hostname.
Definition: Simulation.cpp:1023
wrench::Simulation
A class that provides basic simulation methods. Once the simulation object has been explicitly or imp...
Definition: Simulation.h:46
wrench::ComputeServiceProperty::SUPPORTS_PILOT_JOBS
static const std::string SUPPORTS_PILOT_JOBS
Whether the compute service supports pilot jobs (true or false)
Definition: ComputeServiceProperty.h:26