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

The demo custom_metrics can not working properly. #273

Open
cococolanosugar opened this issue May 11, 2022 · 0 comments
Open

The demo custom_metrics can not working properly. #273

cococolanosugar opened this issue May 11, 2022 · 0 comments

Comments

@cococolanosugar
Copy link

what:

when run the custom_metrics, I find it does not listen the port 9090 as expected.
so you can't fetch metrics data use curl like:

curl localhost:9090/metrics | grep 'my_'

why:

the config file config.yaml mismatch the BuilderConfig struct.

how to fix:

modify config.yaml like this can make it right.

pitaya:
  metrics:
    #prometheus:
    #  enabled: true
    custom:
      counters:
      - subsystem: room
        name: my_counter
        help: a counter example
        labels: ['tag1', 'tag2']
      gauges:
      - subsystem: room
        name: my_gauge_1
        help: a gauge example
        labels: ['tag1']
      - subsystem: room
        name: my_gauge_2
        help: a gauge example
        labels: ['tag2']
      summaries:
      - subsystem: room
        name: my_summary
        help: a summary example
        objectives: {0.7: 0.05, 0.9: 0.01, 0.99: 0.001}
        labels: ['tag1']
metrics:
  prometheus:
    enabled: true
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

No branches or pull requests

1 participant