Remove node name duplication in the ListUnits
and ListUnitFiles
API
#916
Labels
Milestone
ListUnits
and ListUnitFiles
API
#916
Please describe what you would like to see
For the API method
ListUnits
the returned structure is a list of all unit (files) and the name of the respective node
a(sssssssouso)
, for example:The node name is duplicated quite a lot in this structure. It would be more efficient to use a dict and store it only once, e.g.:
This could be achieved by changing the D-Bus API to
a{sa(ssssssouso)}
- where the dict has the node name as key (basic D-Bus type string) and the unit information as value (container D-Bus type). This way the node name isn't repeated n times for n units.Notes:
* The same applies for
ListUnitFiles
(added in #889)** This is a breaking API change
The text was updated successfully, but these errors were encountered: