public abstract class ResourceAwareSchedulingInfo extends Object
Modifier and Type | Field and Description |
---|---|
static ResourceAwareSchedulingInfo |
NON_AWARE_SCHEDULING_INFO |
Constructor and Description |
---|
ResourceAwareSchedulingInfo() |
Modifier and Type | Method and Description |
---|---|
WeightedListeningExecutorService |
adjustServiceDefaultWeightsTo(ResourceAmounts defaultAmounts,
WeightedListeningExecutorService service) |
abstract com.google.common.collect.ImmutableMap<String,ResourceAmounts> |
getAmountsPerRuleType()
Map from the value of
HasNameAndType.getType() to the required resources. |
abstract ResourceAmounts |
getDefaultResourceAmounts() |
ResourceAmounts |
getResourceAmountsForRule(BuildRule rule) |
abstract boolean |
isResourceAwareSchedulingEnabled() |
static ResourceAwareSchedulingInfo |
of(boolean resourceAwareSchedulingEnabled,
ResourceAmounts defaultResourceAmounts,
Map<String,? extends ResourceAmounts> amountsPerRuleType) |
public static final ResourceAwareSchedulingInfo NON_AWARE_SCHEDULING_INFO
public static ResourceAwareSchedulingInfo of(boolean resourceAwareSchedulingEnabled, ResourceAmounts defaultResourceAmounts, Map<String,? extends ResourceAmounts> amountsPerRuleType)
public abstract boolean isResourceAwareSchedulingEnabled()
public abstract ResourceAmounts getDefaultResourceAmounts()
public abstract com.google.common.collect.ImmutableMap<String,ResourceAmounts> getAmountsPerRuleType()
HasNameAndType.getType()
to the required resources.public ResourceAmounts getResourceAmountsForRule(BuildRule rule)
public WeightedListeningExecutorService adjustServiceDefaultWeightsTo(ResourceAmounts defaultAmounts, WeightedListeningExecutorService service)