Skip to content

How to make push work? #75

@olegantonyan

Description

@olegantonyan

I have problems with pushes.
curl to pushgate works, but this does not:

require 'prometheus/client'
require 'prometheus/client/push'
prometheus = Prometheus::Client.registry
counter = Prometheus::Client::Counter.new(:something_here, 'hello world')
counter.increment({ service: 'foo' })
counter.increment({ service: 'foo' })
counter.increment({ service: 'foo' })
counter.increment({ service: 'foo' })
Prometheus::Client::Push.new('job-1', nil, 'http://my-pushgate:9091').add(prometheus)

I don't see something_here counter in http://my-pushgate:9091/metrics. Only push_time_seconds

What am I doing wrong?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions