Class CarbonObjective
java.lang.Object
com.eqixiac.equinix.design.sustainability.CarbonObjective
- All Implemented Interfaces:
Objective
"carbon": the grid carbon intensity of where a portfolio runs its workloads, in
"gCO2e/kWh", from a caller-supplied
CarbonIntensityTable. Smaller is better.
The value is the mean intensity of the metros the workloads' primaries run in (the
WorkloadPlacer's placement), weighted by each workload's bandwidth (an unsized workload, or a
design whose workloads are all unsized, counts 1 per workload); a portfolio with no placed workload is
the plain mean over its metros. It ranks where load runs; it is not an emissions inventory (it knows
no power draw).
Inert without a table: the SDK holds no emissions figures, so without one every portfolio is unknown and the objective never influences a ranking. A metro missing from the table makes the value unknown and names the metro; nothing is filled in.
-
Field Summary
FieldsFields inherited from interface Objective
COMPLIANCE, COST, LATENCY, PROVIDER_COVERAGE, RESILIENCEModifier and TypeFieldDescriptionstatic final StringShare of the stated compliance and sovereignty zones the portfolio satisfies, 0 to 100.static final StringTotal monthly cost of the portfolio in the spec's currency.static final StringSite-weighted round-trip latency from the sites to their nearest metro in the portfolio, in ms.static final StringShare of the required clouds and service providers reachable from the portfolio, 0 to 100.static final StringHow well the portfolio survives losing a metro or a region, 0 to 100. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionevaluate(MetroPortfolio portfolio, DesignContext context) Measures a portfolio.id()unit()Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Objective
scaleModifier and TypeMethodDescriptiondefault ValueScalescale(DesignContext context) How this objective's values become 0..100 scores for the weighted ranking.
-
Field Details
-
ID
-
-
Constructor Details
-
CarbonObjective
- Parameters:
table- the caller's intensity table, ornullfor an inert objective
-
-
Method Details
-
id
- Specified by:
idin interfaceObjective- Returns:
- the id weights refer to (for example
Objective.LATENCY); stable, lower_snake_case
-
direction
-
unit
- Specified by:
unitin interfaceObjective- Returns:
- the unit of
ObjectiveValue.value(), for display (for examplems,USD/month,score)
-
evaluate
Description copied from interface:ObjectiveMeasures a portfolio.- Specified by:
evaluatein interfaceObjective- Parameters:
portfolio- the metros of one candidate designcontext- the facts of this run- Returns:
- the measurement, or
ObjectiveValue.unknown(String)when it cannot be made
-