The interface door half-applies a body: a refused change still lands #1425
Labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
jaylouisw/packetforge#1425
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
POST /api/topologies/:name/interfaces/:device/:portwrites four things — the address,enabled,descriptionand the cage's role — and it writes them as it goes, in that order, answering400the moment one of them is refused. Measured against a live server on a managed switch:The caller is told the change failed while half of it happened. After that the board and the sentence about the board disagree, and a person who reads "refused", reloads, and finds a configured port has no way to know which of the two to believe. #1413 promised this door "changes nothing on refusal" — that held only when the refused field happened to come first.
Two more questions in the same handler are asked wrongly:
And a role refusal reads
1 cannot be bogus; it has no configurable role, which parses as a count of one, not as a port named1.What should be true
enabledis a boolean or a refusal that quotes what it was given;descriptionis a string or a refusal;port 1 cannot be bogus);