Package com.netflix.genie.web.properties
Class JobResolutionProperties.Resources
java.lang.Object
com.netflix.genie.web.properties.JobResolutionProperties.Resources
- Enclosing class:
- JobResolutionProperties
Computation resource properties.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintgetCpu()Get the default number of CPUs.org.springframework.util.unit.DataSizegetDisk()Get the amount of disk space to allocate for the job.intgetGpu()Get the number of GPUs.org.springframework.util.unit.DataSizeGet the default amount of memory.org.springframework.util.unit.DataSizeGet the network bandwidth that should be allocated for the job.voidSet the new default CPU value.voidsetDisk(org.springframework.util.unit.DataSize disk) Set the new disk size.voidSet the new default amount of GPUs.voidsetMemory(org.springframework.util.unit.DataSize memory) Set the default amount of memory for the job runtime.voidsetNetwork(org.springframework.util.unit.DataSize network) Set the new network bandwidth default for jobs.
-
Constructor Details
-
Resources
public Resources()
-
-
Method Details
-
getCpu
public int getCpu()Get the default number of CPUs.- Returns:
- The default number of CPUs
-
setCpu
Set the new default CPU value.- Parameters:
cpu- The cpu value or null
-
getGpu
public int getGpu()Get the number of GPUs.- Returns:
- The number of GPUs.
-
setGpu
Set the new default amount of GPUs.- Parameters:
gpu- The new number of GPUs or null to set back to default
-
getMemory
public org.springframework.util.unit.DataSize getMemory()Get the default amount of memory.- Returns:
- The amount of memory as a
DataSizeinstance
-
setMemory
public void setMemory(@Nullable org.springframework.util.unit.DataSize memory) Set the default amount of memory for the job runtime.- Parameters:
memory- The new amount of memory or null to reset to default
-
getDisk
public org.springframework.util.unit.DataSize getDisk()Get the amount of disk space to allocate for the job.- Returns:
- The disk space as
DataSizeinstance
-
setDisk
public void setDisk(@Nullable org.springframework.util.unit.DataSize disk) Set the new disk size.- Parameters:
disk- The new disk size or null to set back to default
-
getNetwork
public org.springframework.util.unit.DataSize getNetwork()Get the network bandwidth that should be allocated for the job.- Returns:
- The network bandwidth as a
DataSizeinstance that should be converted to something like Mbps
-
setNetwork
public void setNetwork(@Nullable org.springframework.util.unit.DataSize network) Set the new network bandwidth default for jobs.- Parameters:
network- The new default or if null revert to hardcoded default
-