Merge lp:~jameinel/maas/space-from-name into lp:~maas-committers/maas/trunk
Status: | Rejected |
---|---|
Rejected by: | MAAS Lander |
Proposed branch: | lp:~jameinel/maas/space-from-name |
Merge into: | lp:~maas-committers/maas/trunk |
Diff against target: |
40 lines (+9/-3) 2 files modified
src/maasserver/forms_subnet.py (+2/-1) src/maasserver/models/space.py (+7/-2) |
To merge this branch: | bzr merge lp:~jameinel/maas/space-from-name |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
MAAS Maintainers | Pending | ||
Review via email: mp+276632@code.launchpad.net |
Description of the change
This is a couple of steps to make the API a bit nicer for humans to interact with. It allows looking up spaces and subnets by name instead of by ID, and allows forms to be filled in also with the name.
I'd like to get some feedback if this is actually interesting, or if it is too much of an API break (I didn't see a way to have Forms allow *either* an ID or a name, but "to_field_name" works to select what you want.)
The other issue is that space names are not currently Unique, which seems very strange to me. Certainly Juju isn't going to handle that well "juju deploy --constraints spaces=foo" is going to select "1 of the spaces named foo" ?
If you're interested in something like this, I'm interested in pushing it a bit further, and I'm happy to add tests, etc, but I'd want to know I was going in an acceptable direction.
Unmerged revisions
- 4458. By John A Meinel
-
allow friendlier names to be passed to the API instead of requiring them to be ids
Transitioned to Git.
lp:maas has now moved from Bzr to Git.
Please propose your branches with Launchpad using Git.
git clone https:/ /git.launchpad. net/maas