Skip to content

probeVersion error log #6430

@jan-mrm

Description

@jan-mrm

Hey,

currently I get regular errors because probing for the version of the alertmanager fails. The alertmanager endpoint that I am using does not expose metrics to me. I'd like to avoid these error logs if possible to not have static 'accepted' errors cluttering the logs.

Any ideas what could be done to avoid those error logs that are created here?

source, err := am.reader.Read(url, am.HTTPHeaders)
if err != nil {
log.Error().
Err(err).
Str("alertmanager", am.Name).
Str("uri", am.SanitizedURI()).
Msg("Request failed")
return ""
}

My ideas:

Change log level: Since there is a default behavior implemented that assumes the latest version would it be okay to change the log level from error to warning (or info)?

Option to overwrite the version manually: Offer a config field like alertmanager_version to the object of the servers (https://github.com/prymitive/karma/blob/main/docs/CONFIGURATION.md#alertmanagers) list to directly set the version manually and then skip the probeVersion function.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions