API for aborting introspection
While should not be a common thing, sometimes stopping introspection might be useful.
Provide DELETE /v1/introspecti
* sets introspection state to "Cancelled by operator"
* clears node lookup table
* requests node power off
Blueprint information
- Status:
- Not started
- Approver:
- Dmitry Tantsur
- Priority:
- Low
- Drafter:
- Dmitry Tantsur
- Direction:
- Approved
- Assignee:
- milan k
- Definition:
- Approved
- Series goal:
- None
- Implementation:
- Not started
- Milestone target:
- None
- Started by
- Completed by
Related branches
Related bugs
Sprints
Whiteboard
yuikotakada:I agree with this proposal. Is this API will be called when Ironic node is deleted (not cancelled)? When Ironic node is deleted by operator, the record of Ironic-discoverd's database should be deleted synchronize with Ironic's database.
dtantsur: I'm afraid no. I really hope that node can't be deleted in "inspecting" state, and when discoverd is used standalone it has no means to know that node is deleted. This bp is mostly for debugging to be honest, I don't expect people to use it as part of normal workflow.
yuikotakada:OK, If you want to implement this feature just for debugging, you should not expose it as REST API because if this feature is available for end users(operators?), they will use it as normal workflow. We should interrupt it. How about just creating command or something like? :)
And I think my idea - deleting DB API is necessary for us, because it's weird that Ironic-discoverd's DB record is not deleted otherwise Ironic node is deleted. I agree with your idea "node can't be deleted in inspecting state", and then, we can realize this as "When node is in inspecting state, API returns the conflict error like 'Node xxx is in "inspecting state". Please retry later' or like this". And even if Ironic-discoverd is standalone, this API can be executed by something like curl command.
dtantsur: re Ironic, I already expect Ironic to disallow deletion in transient states. Next, "just create a command" involves creating an API :) because API is the only means of talking to discoverd. I for one does not like creating the API at all, but I'm also tired of people doing weird things to stop discovery (deleting underlying nodes is one of them) and then reporting bugs. My main concern right now is to make sure people don't shoot their legs with new API though...
yuikotakada:
> I already expect Ironic to disallow deletion in transient states.
OK, if you want to use this not as just for debug, no problem at all :)
> Next, "just create a command" involves creating an API :) because API is the only means of talking to discoverd.
Ah, my expression was bad, sorry. If you want to create a command, API is not necessary, but just client library(? like ironicclient) is necessary. But anyway, now API is necessary for us, so we can implement API ;)
I for one does not like creating the API at all, but I'm also tired of people doing weird things to stop discovery (deleting underlying nodes is one of them) and then reporting bugs. My main concern right now is to make sure people don't shoot their legs with new API though...
> Ahaha, OK OK, I agree.
dtantsur: anyway I've put a mail thread on this subject, so please feel free to put your opinion there: http://
yuikotakada: You can approve this.
dtantsur: priority low and postponing, as I'd like to see the outcome of Ironic discussion on "abort" action.
Work Items
Dependency tree
* Blueprints in grey have been implemented.