I have a Prometheus Server Configuration and it looks like this...
(Actually a snippet of it)
scrape_configs:
- job_name: 'kubernetes-services-endpoints'
scrape_interval: 5s
action: keep
regex: true
source_labels: [__meta_kubernetes_service_annotation_prometheus_io_scrape]
# Microservices Metrics Jobs Goes There....
- job_name: 'customers-registered-prometheus-job'
scrape_interval: 5s
static_configs:
- targets: ["store-service.store-namespace.svc:8000"]
metrics_path: /metrics
scheme: http
scrape_timeout: 10s
- job_name: 'customers-online-prometheus-job'
scrape_interval: 5s
static_configs:
- targets: ["store-service.store-namespace.svc:8000"]
metrics_path: /metrics
scheme: http
scrape_timeout: 10s
So when I run it with Kubernetes it cannot find Some Fields for Some Reason But When I see other People running the familiar configuration everything works fine...
line 10: field action not found in type config.ScrapeConfig\n
line 11: field regex not found in type config.ScrapeConfig\n
line 12: field source_labels not found in type
config.ScrapeConfig\n line 25: field scrape_internal not found in type
config.ScrapeConfig\n line 81: field scrape_internal not found in type
config.ScrapeConfig\n line 111: field scrape_internal not found in type config.ScrapeConfig"
What can cause following output? Am I need to specify some extra fields?