Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TASK] add Prometheus #177

Closed
wants to merge 6 commits into from
Closed

[TASK] add Prometheus #177

wants to merge 6 commits into from

Conversation

genofire
Copy link
Member

@genofire genofire commented Jan 26, 2020

to run yanic with promtheus, you need both parts

  • [webserver.prometheus] <- the exporter
  • [[nodes.output.prometheus-sd]] <- service discovery to write json

example prometheus config to map the exporter (like blackbox-exporter)

  - job_name: 'yanic'
    metrics_path: /metric
    file_sd_configs:
      - files:
          - '/tmp/yanic.json'
    relabel_configs:
      - source_labels: [__address__]
        target_label: __param_node_id
      - source_labels: [__param_target]
        target_label: instance
      - target_label: __address__
        replacement: EXPORT_WEBSERVER:PORT
      - source_labels: [job]
        target_label: service

@genofire genofire changed the title Prometheus Exporter [TASK] add Prometheus Exporter Jan 26, 2020
@genofire genofire force-pushed the prom-exporter branch 2 times, most recently from f95fa6b to 251fa66 Compare January 26, 2020 15:46
@codecov-io
Copy link

codecov-io commented Jan 26, 2020

Codecov Report

Merging #177 into master will decrease coverage by 1.84%.
The diff coverage is 56.39%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #177      +/-   ##
==========================================
- Coverage   75.05%   73.21%   -1.85%     
==========================================
  Files          52       56       +4     
  Lines        1772     1975     +203     
==========================================
+ Hits         1330     1446     +116     
- Misses        404      491      +87     
  Partials       38       38
Impacted Files Coverage Δ
cmd/serve.go 7.69% <0%> (-1.4%) ⬇️
webserver/prometheus/exporter.go 0% <0%> (ø)
webserver/prometheus/config.go 0% <0%> (ø)
webserver/webserver.go 100% <100%> (ø) ⬆️
webserver/prometheus/transform.go 100% <100%> (ø)
webserver/prometheus/metric.go 100% <100%> (ø)

@genofire genofire force-pushed the prom-exporter branch 4 times, most recently from a3fb6c1 to 55dcddb Compare January 26, 2020 17:11
@genofire genofire changed the title [TASK] add Prometheus Exporter [TASK] add Prometheus Jan 26, 2020
@genofire genofire force-pushed the prom-exporter branch 2 times, most recently from 40ef32a to a2b6f16 Compare January 27, 2020 09:56
@genofire genofire force-pushed the prom-exporter branch 2 times, most recently from 6b05f47 to bdd8071 Compare June 14, 2020 11:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants