OpenSLO / oslo

CLI tool for the OpenSLO spec
Apache License 2.0
203 stars 36 forks source link

Support labels with multiple values for a single key as described in OpenSLO spec #202

Closed programmer04 closed 1 year ago

programmer04 commented 1 year ago

Problem to solve

Currently, oslo supports only labels in the below format

...
metadata:
  labels:
    team: "a"
...

check the source code.

OpenSLO spec allows to define them as

...
metadata:
  labels:
    team:
      - "a"
      - "b"
...

too.

Proposal

Let's support both ways. Don't break the current workflow with oslo.

Further details

Under the hood, it should always be unmarshaled into []string. It's doable with the current YAML library.