A batch job, which encapsulates a WorkflowJob and additional information used by a BatchService. More...
#include <BatchJob.h>
Public Member Functions | |
BatchJob (WorkflowJob *job, unsigned long jobid, unsigned long time_in_minutes, unsigned long number_nodes, unsigned long cores_per_node, double ending_time_stamp, double arrival_time_stamp) | |
Constructor. More... | |
unsigned long | getAllocatedCoresPerNode () |
Get the number of cores per node. More... | |
unsigned long | getAllocatedTime () |
Get the allocated time. More... | |
double | getArrivalTimeStamp () |
Get the arrival time stamp. More... | |
double | getBeginTimeStamp () |
Get the batch job's begin timestamp. More... | |
double | getEndingTimeStamp () |
Get the batch job's end timestamp. More... | |
unsigned long | getJobID () |
Get the id of this batch job. More... | |
double | getMemoryRequirement () |
Get the memory requirement. More... | |
unsigned long | getNumNodes () |
Get the number of allocated compute nodes (or hosts) More... | |
std::map< std::string, std::tuple< unsigned long, double > > | getResourcesAllocated () |
Get the resources allocated to this batch job. More... | |
WorkflowJob * | getWorkflowJob () |
Get the workflow job corresponding to this batch job. More... | |
void | setAllocatedResources (std::map< std::string, std::tuple< unsigned long, double >> resources) |
Set the resources allocated to this batch job. More... | |
void | setAllocatedTime (unsigned long time) |
Set the allocated time. More... | |
void | setBeginTimeStamp (double time_stamp) |
Set the batch job's begin timestamp. More... | |
void | setEndingTimeStamp (double time_stamp) |
Set the batch job's end timestamp. More... | |
Public Attributes | |
std::string | csv_allocated_processors |
The allocated processors field for BatSim-style CSV output. | |
std::string | csv_metadata |
The meta-data field for BatSim-style CSV output. | |
Detailed Description
A batch job, which encapsulates a WorkflowJob and additional information used by a BatchService.
Constructor & Destructor Documentation
◆ BatchJob()
wrench::BatchJob::BatchJob | ( | WorkflowJob * | job, |
unsigned long | jobid, | ||
unsigned long | time_in_minutes, | ||
unsigned long | num_nodes, | ||
unsigned long | cores_per_node, | ||
double | ending_time_stamp, | ||
double | arrival_time_stamp | ||
) |
Constructor.
- Parameters
-
job the workflow job corresponding to the batch job jobid the batch job id time_in_minutes the requested execution time in minutes num_nodes the requested number of compute nodes (hosts) cores_per_node the requested number of cores per node ending_time_stamp the job's end date arrival_time_stamp the job's arrival date
Member Function Documentation
◆ getAllocatedCoresPerNode()
unsigned long wrench::BatchJob::getAllocatedCoresPerNode | ( | ) |
Get the number of cores per node.
- Returns
- a number of cores
◆ getAllocatedTime()
unsigned long wrench::BatchJob::getAllocatedTime | ( | ) |
Get the allocated time.
- Returns
- a time in seconds
◆ getArrivalTimeStamp()
double wrench::BatchJob::getArrivalTimeStamp | ( | ) |
Get the arrival time stamp.
- Returns
- a date
◆ getBeginTimeStamp()
double wrench::BatchJob::getBeginTimeStamp | ( | ) |
Get the batch job's begin timestamp.
- Returns
- a date
◆ getEndingTimeStamp()
double wrench::BatchJob::getEndingTimeStamp | ( | ) |
Get the batch job's end timestamp.
- Returns
- a date
◆ getJobID()
unsigned long wrench::BatchJob::getJobID | ( | ) |
Get the id of this batch job.
- Returns
- a string id
◆ getMemoryRequirement()
double wrench::BatchJob::getMemoryRequirement | ( | ) |
Get the memory requirement.
- Returns
- a size in bytes
◆ getNumNodes()
unsigned long wrench::BatchJob::getNumNodes | ( | ) |
Get the number of allocated compute nodes (or hosts)
- Returns
- a number of nodes
◆ getResourcesAllocated()
std::map< std::string, std::tuple< unsigned long, double > > wrench::BatchJob::getResourcesAllocated | ( | ) |
Get the resources allocated to this batch job.
- Returns
- a list of resource, each as a <hostname, number of cores, bytes of RAM> tuple
◆ getWorkflowJob()
WorkflowJob * wrench::BatchJob::getWorkflowJob | ( | ) |
Get the workflow job corresponding to this batch job.
- Returns
- a workflow job
◆ setAllocatedResources()
void wrench::BatchJob::setAllocatedResources | ( | std::map< std::string, std::tuple< unsigned long, double >> | resources | ) |
Set the resources allocated to this batch job.
- Parameters
-
resources a list of resource, each as a <hostname, number of cores, bytes of RAM> tuple
◆ setAllocatedTime()
void wrench::BatchJob::setAllocatedTime | ( | unsigned long | time | ) |
Set the allocated time.
- Parameters
-
time a time in seconds
◆ setBeginTimeStamp()
void wrench::BatchJob::setBeginTimeStamp | ( | double | time_stamp | ) |
Set the batch job's begin timestamp.
- Parameters
-
time_stamp a date
◆ setEndingTimeStamp()
void wrench::BatchJob::setEndingTimeStamp | ( | double | time_stamp | ) |
Set the batch job's end timestamp.
- Parameters
-
time_stamp a date
The documentation for this class was generated from the following files:
- /home/wrench/wrench/include/wrench/services/compute/batch/BatchJob.h
- /home/wrench/wrench/src/wrench/services/compute/batch/BatchJob.cpp