Skip to content

Inspection API implementation#607

Merged
metal3-io-bot merged 1 commit intometal3-io:masterfrom
Nordix:inspection-feruz
Apr 1, 2021
Merged

Inspection API implementation#607
metal3-io-bot merged 1 commit intometal3-io:masterfrom
Nordix:inspection-feruz

Conversation

@fmuyassarov
Copy link
Copy Markdown
Member

Inspection API implementation.

@metal3-io-bot metal3-io-bot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Jul 29, 2020
@fmuyassarov
Copy link
Copy Markdown
Member Author

/hold
Need to add unit tests.

@metal3-io-bot metal3-io-bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jul 29, 2020
@fmuyassarov fmuyassarov changed the title WIP: Re-inspection API implementation WIP: Inspection API implementation Jul 29, 2020
Comment thread pkg/controller/baremetalhost/baremetalhost_controller.go Outdated
Comment thread pkg/controller/baremetalhost/baremetalhost_controller.go Outdated
Comment thread pkg/controller/baremetalhost/baremetalhost_controller.go Outdated
Comment thread pkg/controller/baremetalhost/baremetalhost_controller.go Outdated
Comment thread pkg/controller/baremetalhost/baremetalhost_controller.go Outdated
Comment thread pkg/controller/baremetalhost/baremetalhost_controller.go Outdated
if !status.Finished {
if !status.Finished || (nodes.ProvisionState(ironicNode.ProvisionState) == nodes.Inspecting || nodes.ProvisionState(ironicNode.ProvisionState) == nodes.InspectWait) {
details = nil
p.log.Info("inspection in progress", "started_at", status.StartedAt)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

As an alternative to the inspect flag... we know the time at which the inspection started (and, from memory, ended if it is complete?), and we also know the time at which we entered the Inspecting state (from Host.Status.OperationHistory.Inspect.Start). So we could assume that if any existing inspection was done before we entered the inspecting state, then we need to start a new inspection.

Comment thread pkg/provisioner/ironic/ironic.go Outdated
Comment thread pkg/provisioner/ironic/ironic.go
Comment thread pkg/provisioner/ironic/ironic.go Outdated
@fmuyassarov fmuyassarov force-pushed the inspection-feruz branch 5 times, most recently from 3ca7beb to acc6d3b Compare September 15, 2020 07:17
@fmuyassarov
Copy link
Copy Markdown
Member Author

/hold cancel

@metal3-io-bot metal3-io-bot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Sep 15, 2020
@fmuyassarov fmuyassarov changed the title WIP: Inspection API implementation Inspection API implementation Sep 15, 2020
@metal3-io-bot metal3-io-bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Sep 15, 2020
Copy link
Copy Markdown
Member Author

@fmuyassarov fmuyassarov left a comment

Choose a reason for hiding this comment

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

@zaneb Thanks a lot for the review and sorry for addressing the comments late.

Comment thread pkg/provisioner/ironic/ironic.go Outdated
Comment thread pkg/controller/baremetalhost/baremetalhost_controller.go Outdated
Comment thread pkg/provisioner/ironic/ironic.go Outdated
Comment thread pkg/provisioner/ironic/ironic.go
@fmuyassarov
Copy link
Copy Markdown
Member Author

/cc @maelk

@metal3-io-bot metal3-io-bot requested a review from maelk September 15, 2020 09:33
@fmuyassarov fmuyassarov requested a review from zaneb September 15, 2020 09:34
Comment thread pkg/controller/baremetalhost/baremetalhost_controller.go Outdated
Comment thread pkg/provisioner/ironic/ironic.go Outdated
Comment thread pkg/provisioner/ironic/ironic.go Outdated
Comment thread pkg/controller/baremetalhost/baremetalhost_controller.go Outdated
Comment thread pkg/provisioner/ironic/ironic.go Outdated
@dhellmann
Copy link
Copy Markdown
Member

I would like to freeze go code changes for a few days to try to land #650 without having to rebase it, because rebasing will mean redoing the work from scratch.

/hold

@metal3-io-bot metal3-io-bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Sep 24, 2020
@metal3-io-bot metal3-io-bot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Sep 25, 2020
@dhellmann
Copy link
Copy Markdown
Member

#655 has merged

/hold cancel

@metal3-io-bot metal3-io-bot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Oct 1, 2020
Comment thread controllers/metal3.io/host_state_machine.go Outdated
@fmuyassarov
Copy link
Copy Markdown
Member Author

/test-integration

@fmuyassarov
Copy link
Copy Markdown
Member Author

@andfasano @zaneb If you think #607 (comment) is also addressed, can we forward and merge the PR?

@fmuyassarov
Copy link
Copy Markdown
Member Author

fmuyassarov commented Mar 29, 2021

Seems I need to rebase. Are we ok to merge this @zaneb once I do the rebase?

@fmuyassarov fmuyassarov force-pushed the inspection-feruz branch 2 times, most recently from ae6f7b6 to 890b742 Compare March 29, 2021 23:17
@fmuyassarov
Copy link
Copy Markdown
Member Author

/test-integration

@s3rj1k
Copy link
Copy Markdown
Member

s3rj1k commented Mar 30, 2021

@fmuyassarov There is an interesting comment from @zaneb that could probably be fixed in this PR
#817 (comment)
Please take a look, thanks.

@fmuyassarov
Copy link
Copy Markdown
Member Author

@fmuyassarov There is an interesting comment from @zaneb that could probably be fixed in this PR
#817 (comment)
Please take a look, thanks.

Thanks @s3rj1k. If I understood right, err = nil is something that needs to be fixed. I can definitely fix it here, but I was expecting to get this patch in if all the comments have been addressed already.

@fmuyassarov
Copy link
Copy Markdown
Member Author

@fmuyassarov There is an interesting comment from @zaneb that could probably be fixed in this PR
#817 (comment)
Please take a look, thanks.

Thanks @s3rj1k. If I understood right, err = nil is something that needs to be fixed. I can definitely fix it here, but I was expecting to get this patch in if all the comments have been addressed already.

maybe we could fix it in a follow-up PR or within #817?

@s3rj1k
Copy link
Copy Markdown
Member

s3rj1k commented Mar 30, 2021

@fmuyassarov There is an interesting comment from @zaneb that could probably be fixed in this PR
#817 (comment)
Please take a look, thanks.

Thanks @s3rj1k. If I understood right, err = nil is something that needs to be fixed. I can definitely fix it here, but I was expecting to get this patch in if all the comments have been addressed already.

maybe we could fix it in a follow-up PR or within #817?

Yep, we need @zaneb feedback here

@fmuyassarov
Copy link
Copy Markdown
Member Author

@zaneb It would be nice if we get this merged if looks okay. Because, there is always something getting merged in master, and I have to rebase it again and again.

Copy link
Copy Markdown
Member

@zaneb zaneb left a comment

Choose a reason for hiding this comment

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

/approve

Comment thread controllers/metal3.io/baremetalhost_controller.go Outdated
@metal3-io-bot
Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: fmuyassarov, zaneb

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@metal3-io-bot metal3-io-bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Apr 1, 2021
@zaneb
Copy link
Copy Markdown
Member

zaneb commented Apr 1, 2021

/test-integration

This adds annotation based API to re-trigger inspection for Ready BMH.
@fmuyassarov
Copy link
Copy Markdown
Member Author

/test-integration
@hardys @andfasano Please take a look, I think all the comments are addressed. Thank you

Copy link
Copy Markdown
Member

@kashifest kashifest left a comment

Choose a reason for hiding this comment

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

/lgtm
/test-centos-integration

@metal3-io-bot metal3-io-bot added the lgtm Indicates that a PR is ready to be merged. label Apr 1, 2021
@metal3-io-bot metal3-io-bot merged commit 682bd4f into metal3-io:master Apr 1, 2021
@fmuyassarov fmuyassarov deleted the inspection-feruz branch May 3, 2021 13:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants