Skip to content

Conversation

@swagner-de
Copy link

This renames DeviceSpec.Bootstrap to Provisioning in order to have a
unified naming. We also implement a ProvisioningProvider interface and
state transitionings in the device controller.

@swagner-de swagner-de requested a review from a team as a code owner December 11, 2025 08:50
@swagner-de swagner-de force-pushed the feat/provisioning-logic branch 2 times, most recently from 4f5a453 to 9e59f4a Compare December 11, 2025 09:50
@swagner-de swagner-de force-pushed the feat/provisioning-logic branch from 9e59f4a to 24203e1 Compare December 11, 2025 14:48
@hardikdr hardikdr added the area/metal-automation Automation processes within the Metal project. label Dec 12, 2025
@hardikdr hardikdr added this to Roadmap Dec 12, 2025
@swagner-de swagner-de force-pushed the feat/provisioning-logic branch 2 times, most recently from d34c54d to e5aa346 Compare December 17, 2025 08:43
This renames `DeviceSpec.Bootstrap` to `Provisioning` in order to have a
unified naming. We also implement a ProvisioningProvider interface and
state transitionings in the device controller.
@swagner-de swagner-de force-pushed the feat/provisioning-logic branch 2 times, most recently from 1b1d271 to bb719f3 Compare December 17, 2025 08:48
@github-actions
Copy link

Merging this branch will decrease overall coverage

Impacted Packages Coverage Δ 🤖
github.com/ironcore-dev/network-operator/api/core/v1alpha1 0.00% (ø)
github.com/ironcore-dev/network-operator/internal/controller/core 69.59% (-0.14%) 👎
github.com/ironcore-dev/network-operator/internal/provider 20.00% (ø)
github.com/ironcore-dev/network-operator/internal/provider/cisco/nxos 12.56% (-0.09%) 👎

Coverage by file

Changed files (no unit tests)

Changed File Coverage Δ Total Covered Missed 🤖
github.com/ironcore-dev/network-operator/api/core/v1alpha1/device_types.go 0.00% (ø) 0 0 0
github.com/ironcore-dev/network-operator/api/core/v1alpha1/groupversion_info.go 0.00% (ø) 0 0 0
github.com/ironcore-dev/network-operator/api/core/v1alpha1/zz_generated.deepcopy.go 0.00% (ø) 0 0 0
github.com/ironcore-dev/network-operator/internal/controller/core/device_controller.go 71.11% (-3.59%) 180 (+14) 128 (+4) 52 (+10) 👎
github.com/ironcore-dev/network-operator/internal/provider/cisco/nxos/provider.go 0.09% (-0.00%) 1164 (+12) 1 1163 (+12) 👎
github.com/ironcore-dev/network-operator/internal/provider/provider.go 20.00% (ø) 25 5 20

Please note that the "Total", "Covered", and "Missed" counts above refer to code statements instead of lines of code. The value in brackets refers to the test coverage of that file in the old version of the code.

Changed unit test files

  • github.com/ironcore-dev/network-operator/api/core/v1alpha1/device_types_test.go
  • github.com/ironcore-dev/network-operator/internal/controller/core/device_controller_test.go
  • github.com/ironcore-dev/network-operator/internal/controller/core/suite_test.go

// +required
Endpoint Endpoint `json:"endpoint"`

// Bootstrap is an optional configuration for the device bootstrap process.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
// Bootstrap is an optional configuration for the device bootstrap process.
// Provisioning is an optional configuration for the device provisioning process.

nit: this comment should be updated.

if activeProv == nil {
err := errors.New("device went into provisioning completed phase, but no active provisioning found")
log.Error(err, "Failed to finalize provisioning")
return ctrl.Result{}, err
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
return ctrl.Result{}, err
return ctrl.Result{}, reconcile.TerminalError(err)

We should use a reconcile.TerminalError as there is no point in retrying on this error.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/metal-automation Automation processes within the Metal project.

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

4 participants