alertmanager: Replace typed fields with plain string values#4083
alertmanager: Replace typed fields with plain string values#4083jkroepke wants to merge 1 commit intoprometheus:mainfrom
Conversation
2b9b301 to
2c29787
Compare
Signed-off-by: Jan-Otto Kröpke <joe@cloudeteer.de>
|
As I commented in #3590 (comment), the need for elaborate custom YAML unmarshaling code would be avoided if Alertmanager updated to yaml.v3. I see there was an earlier PR (#3322) that attempted to update this, but it was not merged because:
I see at least one other open PR (#3944) which seems to be encountering a similar scenario. I found a little more context in this blog post about the release of yaml.v3 by its developer:
|
|
Where does this PR stand with respect to the soon-to-be-released v0.28.0? |
|
Had a conversation with in Slack about this and it feel not worth. |
|
That's unfortunate. If Alertmanager v0.28.0 goes ahead with depending on the large and apparently no longer maintained trivago library, I will most likely patch out that functionality in Debian. I don't have the inclination to package the trivago library just because one application depends on one small function from it. |
|
Closes #4110 |
Fixes #4029
The Jira API requests different fields value types depends on the custom field type itself.
Ref. https://developer.atlassian.com/server/jira/platform/jira-rest-api-examples/#setting-custom-field-data-for-other-field-types, for example:
While jiralert allowed field values with different types as well, it might be problematic in context of the Alertmanager.
github.com/trivago/tgowas necessary to cast all keys to strings. Ref. jira integration #3590 (comment)anyOf. From Kubernetes point of view, all field values must be declared as string and an additional transformation logic is necessary to convert string values to complex values.I feel that re-implement the logic from jiralert was design flaw while implement the jira notifier at Alertmanager.
WDYT: @simonpasquier @dswarbrick