[2.6] Cannot filter machines by fabric/vlan, subnet or even status when executing 'machines read'
Bug #1828444 reported by
Andres Rodriguez
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
MAAS |
Fix Released
|
High
|
Alberto Donato |
Bug Description
I want to read machines filtered by fabric/vlan, subnet, status but I'm unable to do so because the machines read endpoint only provides a few filtering options. Current filtering options are:
:param hostname:
:param mac_address:
:param id:
:param domain:
:param zone:
:param pool:
MAAS should allow me to filter by fabric/vlan combination and/or subnet, and by the status of the machine.
This is with the goal of reducing the amount of data we may have when running 'maas admin machines read' and we are attempting to filter machines out as much as possible.
e.g. in very large environments, like 1000s of machines, we are doing to want to filter by more advanced settings.
Related branches
~ack/maas:1828444-machines-read-filter
Merged
into
maas:master
- Newell Jensen (community): Approve
- Blake Rouse (community): Approve
-
Diff: 1421 lines (+522/-269)6 files modifiedsrc/maasserver/api/nodes.py (+47/-1)
src/maasserver/api/tests/test_machines.py (+20/-18)
src/maasserver/api/tests/test_nodes.py (+5/-2)
src/maasserver/enum.py (+6/-0)
src/maasserver/node_constraint_filter_forms.py (+150/-66)
src/maasserver/tests/test_node_constraint_filter_forms.py (+294/-182)
Changed in maas: | |
milestone: | none → 2.6.0rc1 |
assignee: | nobody → Alberto Donato (ack) |
importance: | Undecided → High |
description: | updated |
Changed in maas: | |
status: | New → Triaged |
Changed in maas: | |
status: | Triaged → In Progress |
Changed in maas: | |
status: | In Progress → Fix Committed |
Changed in maas: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
This should not be done just Adhoc, we should determine exactly what we want it to filter by and have it match how the UI will be filtered.
That will allow the same QuerySet building that the API does to be used by the Websocket for the UI when filter and paging are performed server-side.