Details
-
Task
-
Resolution: Done
-
Undefined
-
None
-
None
Description
Currently when calling the getInstancesByProduct() api one of the options is to sort the results by a measurement. Unfortunately today, the specification of the sortable items is an enum in the API spec [1]. This is a problem because the enumeration has to be updated whenever a new sortable measurement type is added. The possible values for metric id for a given product are coming from configuration. This puts us in a weird place where half the values cleanly map to an enumeration and half of them are custom per product.
This card is to investigate what the options are and present a proposal so that we do not have to update an enumeration in an API spec every time we add a new metricid for a new product.