Skip to content

Commit

Permalink
Merge pull request #171 from atc0005/i152-use-unknown-state-for-fetch…
Browse files Browse the repository at this point in the history
…ing-and-parsing-failures

Use UNKNOWN state for fetching & parsing failures
  • Loading branch information
atc0005 authored Apr 4, 2023
2 parents 4e793df + 80183d7 commit cf5ac4f
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions cmd/check_whois/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,10 +86,10 @@ func main() {
plugin.AddError(err)
plugin.ServiceOutput = fmt.Sprintf(
"%s: Error fetching WHOIS data for %s domain",
nagios.StateCRITICALLabel,
nagios.StateUNKNOWNLabel,
cfg.Domain,
)
plugin.ExitStatusCode = nagios.StateCRITICALExitCode
plugin.ExitStatusCode = nagios.StateUNKNOWNExitCode

return

Expand All @@ -102,10 +102,10 @@ func main() {
plugin.AddError(err)
plugin.ServiceOutput = fmt.Sprintf(
"%s: Error parsing WHOIS data for %s domain",
nagios.StateCRITICALLabel,
nagios.StateUNKNOWNLabel,
cfg.Domain,
)
plugin.ExitStatusCode = nagios.StateCRITICALExitCode
plugin.ExitStatusCode = nagios.StateUNKNOWNExitCode

return

Expand All @@ -118,10 +118,10 @@ func main() {
plugin.AddError(err)
plugin.ServiceOutput = fmt.Sprintf(
"%s: Error parsing WhoisInfo data for %s domain",
nagios.StateCRITICALLabel,
nagios.StateUNKNOWNLabel,
cfg.Domain,
)
plugin.ExitStatusCode = nagios.StateCRITICALExitCode
plugin.ExitStatusCode = nagios.StateUNKNOWNExitCode

return

Expand Down

0 comments on commit cf5ac4f

Please sign in to comment.