messagebird / pushprom Goto Github PK
View Code? Open in Web Editor NEWPushprom is a proxy to the Prometheus Go client.
Home Page: https://www.messagebird.com
License: BSD 2-Clause "Simplified" License
Pushprom is a proxy to the Prometheus Go client.
Home Page: https://www.messagebird.com
License: BSD 2-Clause "Simplified" License
[remek][~/.../github.com/messagebird/pushprom][master]$ make container
rm -fr bin pkg vendor/pkg
* go getting all dependencies into vendor/
find vendor/ -name .git -type d | xargs rm -rf
* Building pushprom for release
mv: cannot stat 'bin/linux_amd64/pushprom': No such file or directory
Makefile:28: recipe for target 'release_linux' failed
make: *** [release_linux] Error 1
[remek][~/.../github.com/messagebird/pushprom][master]$ pwd
/home/remek/go/src/github.com/messagebird/pushprom
[remek][~/.../github.com/messagebird/pushprom][master]$ ls bin/
pushprom
nobody creates linux_amd64 dir and/or puts anything into it
Pushprom 1.0.8 is too verbose on default INFO level.
Trying to use the “documented” -log-level argument for the application does not have effect.
Update from 1.0.7 to 1.0.8 resulting in thousands unnecessary log records polluting the INFO logs.
Pushprom 1.0.8 does not change behaviour when updating from 1.0.7 for logging.
or Pushprom 1.0.8 default verbosity level changes to “warn” and/or respect the -log-level documented argument.
@dstotijn published pushprom to https://hub.docker.com/r/messagebird/pushprom/
we need to add some text to the README letting the user know of that option.
@samwierema also mentioned that he wanted to automate pushing to the hub on build
I just updated to the latest prometheus go client and get this error when building
./delta.go:161: cannot use vec.With(delta.Labels) (type prometheus.Observer) as type
prometheus.Histogram in assignment:
prometheus.Observer does not implement prometheus.Histogram
(missing Collect method)
This will cause prompush to return from the listenUDP
function, causing it to close serverConn
:
echo "hello" | nc --udp localhost -p 9090
logs:
2016/11/09 17:20:37 udp.go:36: Error: invalid character 'h' looking for beginning of value
then a second nc
prints:
Ncat: Connection refused.
Just tried to update the golang client of prometheus to 0.8.0 and got some errors. Most importantly undefined: prometheus.RegisterOrGet
.
pushprom$ rm -rf vendor/src/github.com/prometheus/client_golang/
pushprom$ make dependencies
* go getting all dependencies into vendor/
# pushprom
src/pushprom/delta.go:63: undefined: prometheus.RegisterOrGet
src/pushprom/delta.go:75: undefined: prometheus.RegisterOrGet
src/pushprom/delta.go:86: metric.Set undefined (type prometheus.Counter has no field or method Set)
src/pushprom/delta.go:107: undefined: prometheus.RegisterOrGet
src/pushprom/delta.go:119: undefined: prometheus.RegisterOrGet
src/pushprom/delta.go:155: undefined: prometheus.RegisterOrGet
src/pushprom/delta.go:167: undefined: prometheus.RegisterOrGet
src/pushprom/delta.go:194: undefined: prometheus.RegisterOrGet
src/pushprom/delta.go:206: undefined: prometheus.RegisterOrGet
Makefile:51: recipe for target 'dependencies' failed
make: *** [dependencies] Error 2
It seems that adding labels / attributes to an existing metric does not use the added labels. It should actually recognise that labels were added and use them.
Scraping pushprom returns no timestamp for metrics, which may be very old. No staleness check is possible unless one metric contains a timestamp as a value.
Instead, pushprom could provide the timestamp when the metric was received.
The wire format allows it: https://prometheus.io/docs/instrumenting/exposition_formats/
Something like https://github.com/prometheus/promu can help to build and push to github
Specifying host to listen on prints:
$ pushprom -http-listen-address localhost:9091 -udp-listen-address localhost:9090
2016/11/10 17:04:43 http.go:36: exposing metrics on http://0.0.0.0:localhost:9091/metrics
2016/11/10 17:04:43 udp.go:10: listening for stats UDP on port localhost:9090
2016/11/10 17:04:43 http.go:39: listening for stats on http://0.0.0.0localhost:9091
Note the bogus http://0.0.0.0localhost:9091
https://hub.docker.com/r/messagebird/pushprom/ is not currently a Public/Automated build (the repo is of course public). Public/Automated builds are superior since a) they are updated and published more regularly and b) they are more easily trusted, since it is instantly clear exactly how the image was built and it was built by an automated system.
I don't think it is simple to change a repo to automated - Docker Hub support might be able to do that, or it may involve deleting/recreating or even renaming the image slug.
The steps for this are:
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.