diff --git a/main.go b/main.go index 46811d6..1fc6326 100644 --- a/main.go +++ b/main.go @@ -1,30 +1,33 @@ /* - Copyright 2022 Dolysis Consulting Limited +Copyright 2022 Dolysis Consulting Limited - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - http://www.apache.org/licenses/LICENSE-2.0 - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at - For changes see the git log + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. + +For changes see the git log */ package main import ( "flag" + "net/http" + "os" + + "git.st8l.com/dolysis/cups-exporter/pkg" "github.com/go-logr/logr" "github.com/go-logr/zapr" - "git.st8l.com/dolysis/cups-exporter/pkg" "github.com/prometheus/client_golang/prometheus" "github.com/prometheus/client_golang/prometheus/promhttp" "go.uber.org/zap" - "net/http" - "os" ) type options struct { @@ -60,7 +63,7 @@ func main() { `)) if err != nil { - log.Info("An error occured while writing http response: %v", err) + log.Info("An error occurred while writing http response: %v", err) } }) diff --git a/pkg/jobs.go b/pkg/jobs.go index a471870..4bb46f8 100644 --- a/pkg/jobs.go +++ b/pkg/jobs.go @@ -58,7 +58,7 @@ func (e *Exporter) jobsMetrics(ch chan<- prometheus.Metric) error { if value <= 9 && value >= 3 { states[value]++ } else { - e.log.Info("Unknow job state : " + strconv.Itoa(int(value))) + e.log.Info("Unknown job state : " + strconv.Itoa(int(value))) } } else { e.log.Info("job state attribute missing")