Class ResourceAwareSchedulingInfo
- java.lang.Object
-
- com.facebook.buck.core.build.engine.config.ResourceAwareSchedulingInfo
-
public abstract class ResourceAwareSchedulingInfo extends Object
-
-
Field Summary
Fields Modifier and Type Field Description static ResourceAwareSchedulingInfo
NON_AWARE_SCHEDULING_INFO
-
Constructor Summary
Constructors Constructor Description ResourceAwareSchedulingInfo()
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description WeightedListeningExecutorService
adjustServiceDefaultWeightsTo(ResourceAmounts defaultAmounts, WeightedListeningExecutorService service)
abstract com.google.common.collect.ImmutableMap<String,ResourceAmounts>
getAmountsPerRuleType()
Map from the value ofHasNameAndType.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)
-
-
-
Field Detail
-
NON_AWARE_SCHEDULING_INFO
public static final ResourceAwareSchedulingInfo NON_AWARE_SCHEDULING_INFO
-
-
Method Detail
-
of
public static ResourceAwareSchedulingInfo of(boolean resourceAwareSchedulingEnabled, ResourceAmounts defaultResourceAmounts, Map<String,? extends ResourceAmounts> amountsPerRuleType)
-
isResourceAwareSchedulingEnabled
public abstract boolean isResourceAwareSchedulingEnabled()
-
getDefaultResourceAmounts
public abstract ResourceAmounts getDefaultResourceAmounts()
-
getAmountsPerRuleType
public abstract com.google.common.collect.ImmutableMap<String,ResourceAmounts> getAmountsPerRuleType()
Map from the value ofHasNameAndType.getType()
to the required resources.
-
getResourceAmountsForRule
public ResourceAmounts getResourceAmountsForRule(BuildRule rule)
-
adjustServiceDefaultWeightsTo
public WeightedListeningExecutorService adjustServiceDefaultWeightsTo(ResourceAmounts defaultAmounts, WeightedListeningExecutorService service)
-
-