Find, verify, and analyze leaked credentials
Go credentialsdevsecopsdynamic-analysisprecommitscanningsecretsecret-managementsecretssecuritysecurity-toolstrufflehogverification
[chore] Change job_id in metric to source_type (#5149)
Miccaha2ef4f51a5e3
diff --git a/pkg/engine/engine.go b/pkg/engine/engine.goindex f7698c891..b1a9dd642 100644--- a/pkg/engine/engine.go+++ b/pkg/engine/engine.go@@ -1183,7 +1183,7 @@ func (e *Engine) detectChunk(ctx context.Context, data detectableChunk) {detectorExecutionCount.WithLabelValues(detectorNameStr,- strconv.Itoa(int(data.chunk.JobID)),+ sourceTypeStr,data.chunk.SourceName,).Inc()detectorExecutionDuration.WithLabelValues(diff --git a/pkg/engine/metrics.go b/pkg/engine/metrics.goindex 3f1c032d7..b929c4f01 100644--- a/pkg/engine/metrics.go+++ b/pkg/engine/metrics.go@@ -16,7 +16,7 @@ var (Name: "detector_execution_count",Help: "Total number of times a detector has been executed.",},- []string{"detector_name", "job_id", "source_name"},+ []string{"detector_name", "source_type", "source_name"},)// Note this is the time taken to call FromData on each detector, not necessarily the time taken