Skip to content

Commit

Permalink
Merge pull request #32 from kpetremann/refacto
Browse files Browse the repository at this point in the history
refacto: remove package events aliases
  • Loading branch information
kpetremann committed Jun 19, 2023
2 parents ae1d37c + 3aa95a5 commit cf5c1b5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions cmd/salt-exporter/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (

"github.com/kpetremann/salt-exporter/internal/logging"
"github.com/kpetremann/salt-exporter/internal/metrics"
events "github.com/kpetremann/salt-exporter/pkg/event"
"github.com/kpetremann/salt-exporter/pkg/event"
"github.com/kpetremann/salt-exporter/pkg/listener"
"github.com/kpetremann/salt-exporter/pkg/parser"
"github.com/prometheus/client_golang/prometheus/promhttp"
Expand Down Expand Up @@ -83,7 +83,7 @@ func main() {
defer stop()

log.Info().Msg("listening for events...")
eventChan := make(chan events.SaltEvent)
eventChan := make(chan event.SaltEvent)

// listen and expose metric
parser := parser.NewEventParser(false)
Expand Down
4 changes: 2 additions & 2 deletions internal/metrics/metrics.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"time"

"github.com/kpetremann/salt-exporter/internal/filters"
events "github.com/kpetremann/salt-exporter/pkg/event"
"github.com/kpetremann/salt-exporter/pkg/event"
"github.com/prometheus/client_golang/prometheus"
"github.com/prometheus/client_golang/prometheus/promauto"
"github.com/rs/zerolog/log"
Expand All @@ -19,7 +19,7 @@ func boolToFloat64(b bool) float64 {
return 0.0
}

func ExposeMetrics(ctx context.Context, eventChan <-chan events.SaltEvent, metricsConfig MetricsConfig) {
func ExposeMetrics(ctx context.Context, eventChan <-chan event.SaltEvent, metricsConfig MetricsConfig) {
newJobCounter := promauto.NewCounterVec(
prometheus.CounterOpts{
Name: "salt_new_job_total",
Expand Down

0 comments on commit cf5c1b5

Please sign in to comment.