Skip to content

Commit 46c761e

Browse files
authored
chore: nv-redfish 0.15.0 (#4979)
Update nv-redfish to 0.15.0 https://github.com/NVIDIA/nv-redfish/releases/tag/v0.15.0 ## Related issues ## Type of Change - [ ] **Add** - New feature or capability - [ ] **Change** - Changes in existing functionality - [ ] **Fix** - Bug fixes - [ ] **Remove** - Removed features or deprecated functionality - [x] **Internal** - Internal changes (refactoring, tests, docs, etc.) ## Breaking Changes - [ ] **This PR contains breaking changes** ## Testing - [ ] Unit tests added/updated - [ ] Integration tests added/updated - [ ] Manual testing performed - [x] No testing required (docs, internal refactor, etc.) ## Additional Notes --------- Signed-off-by: ianisimov <ianisimov@nvidia.com>
1 parent 1badba5 commit 46c761e

14 files changed

Lines changed: 51 additions & 17 deletions

File tree

Cargo.lock

Lines changed: 12 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,8 @@ opentelemetry-semantic-conventions = "0.32.1"
6262
tracing-opentelemetry = "0.33.0"
6363

6464
# NV-Redfish
65-
nv-redfish = { version = "0.14.2" }
66-
nv-redfish-dispatcher = { version = "0.14.2" }
65+
nv-redfish = { version = "0.15.0" }
66+
nv-redfish-dispatcher = { version = "0.15.0" }
6767

6868
########
6969
# MARK: - Pinned packages that we can't upgrade due to conflicts or just bugs

crates/api-model/src/site_explorer/mod.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1501,6 +1501,8 @@ pub enum PowerState {
15011501
PoweringOff,
15021502
PoweringOn,
15031503
Paused,
1504+
Hibernating,
1505+
Sleeping,
15041506
Unknown,
15051507
}
15061508

crates/bmc-explorer/src/computer_system.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -288,6 +288,8 @@ impl<B: Bmc> ExploredComputerSystem<B> {
288288
PowerState::PoweringOn => Some(ModelPowerState::PoweringOn),
289289
PowerState::PoweringOff => Some(ModelPowerState::PoweringOff),
290290
PowerState::Paused => Some(ModelPowerState::Paused),
291+
PowerState::Hibernating => Some(ModelPowerState::Hibernating),
292+
PowerState::Sleeping => Some(ModelPowerState::Sleeping),
291293
PowerState::UnsupportedValue => None,
292294
})
293295
.unwrap_or_default()

crates/rpc/proto/site_explorer.proto

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -263,6 +263,8 @@ enum PowerState {
263263
PoweringOn = 3;
264264
Paused = 4;
265265
Unknown = 5;
266+
Hibernating = 6;
267+
Sleeping = 7;
266268
}
267269

268270
// `Manager` definition. Matches redfish definition

crates/rpc/src/model/site_explorer.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -235,6 +235,8 @@ impl From<PowerState> for rpc::site_explorer::PowerState {
235235
PowerState::PoweringOff => rpc::site_explorer::PowerState::PoweringOff,
236236
PowerState::PoweringOn => rpc::site_explorer::PowerState::PoweringOn,
237237
PowerState::Paused => rpc::site_explorer::PowerState::Paused,
238+
PowerState::Hibernating => rpc::site_explorer::PowerState::Hibernating,
239+
PowerState::Sleeping => rpc::site_explorer::PowerState::Sleeping,
238240
PowerState::Unknown => rpc::site_explorer::PowerState::Unknown,
239241
}
240242
}

rest-api/api/pkg/api/model/exploredendpoint.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -572,6 +572,10 @@ func (r *APIExploredComputerSystemPowerState) FromProto(state corev1.ComputerSys
572572
*r = "Paused"
573573
case corev1.ComputerSystemPowerState_Unknown:
574574
*r = "Unknown"
575+
case corev1.ComputerSystemPowerState_Hibernating:
576+
*r = "Hibernating"
577+
case corev1.ComputerSystemPowerState_Sleeping:
578+
*r = "Sleeping"
575579
default:
576580
*r = "Unknown"
577581
}

rest-api/docs/index.html

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

rest-api/flow/internal/converter/dao/converter.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,10 @@ func powerStateFromDAO(ps *nicoapi.PowerState) string {
5454
return "off"
5555
case nicoapi.PowerStateDisabled:
5656
return "disabled"
57+
case nicoapi.PowerStateHibernating:
58+
return "hibernating"
59+
case nicoapi.PowerStateSleeping:
60+
return "sleeping"
5761
default:
5862
return "unknown"
5963
}

rest-api/flow/internal/nicoapi/model.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,8 @@ const (
110110
PowerStateOff
111111
PowerStateOn
112112
PowerStateDisabled
113+
PowerStateHibernating
114+
PowerStateSleeping
113115
)
114116

115117
// MachinePowerState is information about current and desired power states

0 commit comments

Comments
 (0)