Skip to content

Commit

Permalink
adding scrape protocol and ID for pr0metheus receiver
Browse files Browse the repository at this point in the history
  • Loading branch information
movence committed May 3, 2024
1 parent 5aaf26f commit e13d372
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,12 @@ func GetScraperConfig(hostInfoProvider hostInfoProvider) *config.ScrapeConfig {
InsecureSkipVerify: false,
},
},
ScrapeInterval: model.Duration(collectionInterval),
ScrapeTimeout: model.Duration(collectionInterval),
JobName: jobName,
Scheme: "https",
MetricsPath: scraperMetricsPath,
ScrapeInterval: model.Duration(collectionInterval),
ScrapeTimeout: model.Duration(collectionInterval),
ScrapeProtocols: config.DefaultScrapeProtocols,
JobName: jobName,
Scheme: "https",
MetricsPath: scraperMetricsPath,
ServiceDiscoveryConfigs: discovery.Configs{
&kubernetes.SDConfig{
Role: kubernetes.RoleService,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ func NewSimplePrometheusScraper(opts SimplePrometheusScraperOpts) (*SimplePromet
}

params := receiver.CreateSettings{
ID: component.MustNewID(opts.ScraperConfigs.JobName),
TelemetrySettings: opts.TelemetrySettings,
}

Expand Down

0 comments on commit e13d372

Please sign in to comment.