Skip to content

Commit 3435472

Browse files
fix: remove electrical component control mode (#359)
It was determined that we do not want to make this part of the common API definition for `ElectricalComponent`
2 parents d08fcfe + c1de523 commit 3435472

File tree

2 files changed

+2
-54
lines changed

2 files changed

+2
-54
lines changed

RELEASE_NOTES.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@
2424
- Added new message definitions for streaming events (Deleted, Created, Updated)
2525
- Remove unnecessary gap in numbering in the `ElectricalComponentCategory` enum.
2626
- Renumber variants in the `Metric` enum to remove unnecessary gaps.
27-
- Added a new enum `ElectricalComponentControlMode` to define control modes for electrical components.
2827
- Renamed `metric_sample.proto` to `metrics.proto` to better reflect its content.
2928
- Renamed electrical component category `COMPONENT_CATEGORY_GRID` to `ELECTRICAL_COMPONENT_CATEGORY_GRID_CONNECTION_POINT` to clarify its meaning. Note that the change in the enum change is a part of a larger refactoring of the electrical component category enum.
3029
- The oneof variant `ComponentCategoryMetadataVariant.metadata.grid` has been renamed to `ElectricalComponentCategorySpecificInfo.info.grid_connection_point` to better reflect its purpose.

proto/frequenz/api/common/v1/microgrid/electrical_components/electrical_components.proto

Lines changed: 2 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -164,54 +164,6 @@ enum ElectricalComponentStateCode {
164164
ELECTRICAL_COMPONENT_STATE_CODE_PRECHARGER_CLOSED = 42;
165165
}
166166

167-
// `ElectricalComponentControlMode` explicitly defines whether an electrical
168-
// component is intended to be active (enabled) or inactive (disabled). This
169-
// intentional setting directly determines component availability to downstream
170-
// agents, applications, and services.
171-
//
172-
// !!! note "Control Mode & Component Availability"
173-
// The Control Mode explicitly represents the user's or automation's
174-
// intention to make the component either ACTIVE or INACTIVE. This directly
175-
// impacts availability:
176-
// - ACTIVE indicates the component is intended to be available and usable
177-
// by downstream agents and services.
178-
// - INACTIVE indicates the component is intended to be unavailable for use
179-
// by downstream agents and services.
180-
//
181-
// !!! note "Relationship with Operational State"
182-
// Control Mode explicitly represents intention, distinct from the
183-
// component's actual internal Operational State.
184-
// Operational State is independently reported by the component hardware
185-
// (e.g., READY, CHARGING, DISCHARGING, ERROR).
186-
//
187-
// !!! caution "Immediate Operational Impact"
188-
// Changing the Control Mode of an electrical component (e.g., via the
189-
// Microgrid API) takes immediate effect on its availability to downstream
190-
// agents and services. Setting a component to `INACTIVE` can thus instantly
191-
// interrupt ongoing operations or cause service disruptions. Setting a
192-
// component to `ACTIVE` may immediately connect it with other components,
193-
// potentially causing electrical damage. Therefore, ensure changes are
194-
// coordinated or planned appropriately to avoid unintended impact and/or
195-
// damages.
196-
//
197-
// !!! example "Control Mode Change Impact"
198-
// If a battery component's Control Mode is switched from `ACTIVE` to
199-
// `INACTIVE`, it immediately becomes unavailable to downstream
200-
// services and agents, potentially disrupting scheduled
201-
// charging/discharging cycles.
202-
enum ElectricalComponentControlMode {
203-
// The control mode is unspecified (should never be explicitly used).
204-
ELECTRICAL_COMPONENT_CONTROL_MODE_UNSPECIFIED = 0;
205-
206-
// The component is explicitly enabled and intended to be available for
207-
// downstream usage.
208-
ELECTRICAL_COMPONENT_CONTROL_MODE_ACTIVE = 1;
209-
210-
// The component is explicitly disabled and intended to be unavailable for
211-
// downstream usage.
212-
ELECTRICAL_COMPONENT_CONTROL_MODE_INACTIVE = 2;
213-
}
214-
215167
// A representation of all possible diagnostic codes that can occur for
216168
// electrical component, across all their categories. These diagnostic codes
217169
// can be used to refer to warnings or errors that are reported by the
@@ -456,14 +408,11 @@ message ElectricalComponent {
456408
// The model name of the component.
457409
string model_name = 7;
458410

459-
// The control mode of the component.
460-
ElectricalComponentControlMode control_mode = 8;
461-
462411
// The operational lifetime of the component.
463-
frequenz.api.common.v1.microgrid.Lifetime operational_lifetime = 9;
412+
frequenz.api.common.v1.microgrid.Lifetime operational_lifetime = 8;
464413

465414
// List of rated bounds present for the component identified by Metric.
466-
repeated MetricConfigBounds metric_config_bounds = 10;
415+
repeated MetricConfigBounds metric_config_bounds = 9;
467416
}
468417

469418
// ElectricalComponentConnection describes a single electrical link between two

0 commit comments

Comments
 (0)