Commit Graph

1743 Commits

Author SHA1 Message Date
Björn Rabenstein 5cec1d0429 Merge pull request #354 from prometheus/brian-brazil-patch-1
Fix typo in comment
2017-10-05 13:29:15 +02:00
Brian Brazil 9f5d03c01f Fix typo in comment 2017-10-04 17:44:49 +01:00
Björn Rabenstein 353b8c3f37 Merge pull request #348 from dlespiau/2017-09-11-examples-docker-images
Create Docker images for the examples
2017-09-21 12:55:43 +02:00
Damien Lespiau ec06aca188 Create Docker images for the examples
When those are published on Dockerhub, people will be able to start those
examples in fewer steps than the current documentation:

  https://prometheus.io/docs/introduction/getting_started/#starting-up-some-sample-targets

While relying on Docker may not be always wished, giving the possibility to
quickly start a daemon that exposes metrics can be useful in many tutorials.

The simple and random example are build as static binaries and packaged as
single binaries in Docker images.

This commit tries really hard to limit the number of per-example maintenance
work by sharing most of the Makefile to build the Docker images. The tiny top
level Makefiles in each example directory are strictly identical.

Updates: #347
2017-09-19 13:59:05 +01:00
beorn7 50b3332fd6 Polishing some doc comments 2017-09-13 12:48:29 +02:00
Björn Rabenstein 5032813742 Merge pull request #349 from povilasv/summary-doc
Change summary docs
2017-09-13 12:42:30 +02:00
Povilas Versockas 77a1417b06 Change summary docs 2017-09-12 20:27:18 +03:00
Björn Rabenstein 671c87b047 Merge pull request #346 from prometheus/beorn7/versioning
Drop Go1.6 support, add test for Go1.9
2017-09-07 17:06:25 +02:00
beorn7 36f4ab6bce Drop Go1.6 support, add test for Go1.9
Also, document the version requirement.
2017-09-06 15:36:30 +02:00
Björn Rabenstein 00e08dd66d Merge pull request #345 from mattbostock/correct_docs
Correct DefaultRegistry to DefaultRegisterer
2017-09-05 11:18:01 +02:00
Matt Bostock b092a4bc11 Correct DefaultRegistry to DefaultRegisterer
`DefaultRegistry` no longer exists as of a6321dd0b.
2017-09-05 01:08:40 +01:00
Björn Rabenstein 967789050b Merge pull request #343 from prometheus/beorn7/http
Fix error reporting bug
2017-08-31 15:19:02 +02:00
beorn7 2cb8df16e3 Fix error reporting bug
That's the same bug fixed in #342 (which is the deprecated code only
replicated in the `prometheus` package until v0.10 is out).
2017-08-31 15:10:58 +02:00
Brian Brazil 535f493f5a Merge pull request #342 from wrouesnel/master
http.go: incorrect error message displayed when no metrics encoded error
2017-08-31 09:39:07 +01:00
Will Rouesnel a166207919 http.go: incorrect error message displayed when no metrics encoded error
The "No metrics encoded" error was erroneously displayed the value of err, not
lastErr.
2017-08-31 12:05:46 +10:00
Björn Rabenstein 61d8c3f402 Merge pull request #340 from prometheus/beorn7/deprecation
Remove the deprecated uses of Untyped metrics
2017-08-29 17:37:40 +02:00
beorn7 6164fff8ce Remove the deprecated uses of Untyped metrics
I couldn't find any use of the removed identifiers on sourcegraph.com
(outside of this repo itself).
2017-08-29 17:31:45 +02:00
Brian Brazil 140d476395 Merge pull request #339 from linlynn/master
fix spelling typo
2017-08-28 08:26:11 +01:00
Lynn Lin be904beebc fix spelling typo 2017-08-28 08:57:51 +08:00
Björn Rabenstein 3eb912b336 Merge pull request #335 from marco-jantke/check-validity-of-label-values
Check validity of label values
2017-08-25 18:06:44 +02:00
Marco Jantke a956c5fdd6 improve validation function naming 2017-08-25 17:58:59 +02:00
Marco Jantke 0b8aef084e implement review feedback 2017-08-25 14:51:19 +02:00
Marco Jantke 6df742e132 improve formatting of invalid label value error messages 2017-08-20 00:54:11 +02:00
Marco Jantke 555018f3c9 make code compatible with go 1.6 2017-08-20 00:53:55 +02:00
Marco Jantke 685a3c90d4 fail Gather'ing when label value is not utf8 2017-08-20 00:10:32 +02:00
Marco Jantke 7ee20d77cb validate ConstLabels values in NewDesc 2017-08-20 00:09:51 +02:00
Marco Jantke 703c4a9c6f add label value validation to NewConstMetric and friends 2017-08-20 00:09:51 +02:00
Marco Jantke 459e88167e extract and refactor label validation functions
so that we can reuse them in other parts of the code, not only as part
of a metricVec.
2017-08-20 00:09:50 +02:00
Marco Jantke 957bba6f68 add label value validation to GetMetricWith and friends 2017-08-19 22:55:41 +02:00
Björn Rabenstein 94ff84a9a6 Merge pull request #329 from infoverload/add_new_metric_go_info
Add new default metric go_info
2017-07-24 10:13:13 +02:00
hazey.dazey f36d4a3e73 Add new default metric go_info 2017-07-23 23:36:09 +02:00
Björn Rabenstein 95b6848b5c Merge pull request #325 from prometheus/beorn7/doc
Remove remaining references to MetricVec from doc comments
2017-07-12 18:53:59 +02:00
beorn7 ed379b7d99 Remove remaining references to MetricVec from doc comments
MetricVec is un-experted by now. godoc handles that correctly by
showing the methods of the embedded un-exported metricVec with the
exported type (CounterVec, SummaryVec, ...) that embeds metricVec.
2017-07-12 15:13:09 +02:00
Björn Rabenstein 26b8970019 Merge pull request #324 from maximesong/master
fix typo in comments
2017-07-07 19:33:55 +02:00
Maxime Song 90494ea7b1 fix typo in comments
Signed-off-by: Maxime Song <me@cppdo.com>
2017-07-07 23:28:24 +08:00
Björn Rabenstein 310ce84375 Merge pull request #319 from prometheus/beorn7/vec
Unexport MetricVec
2017-06-30 16:48:34 +02:00
Björn Rabenstein 77934284f4 Merge pull request #321 from prometheus/beorn7/doc
Document the use of Go1.9+ for monotonic time where applicable
2017-06-29 16:21:10 +02:00
beorn7 e04de4bfe3 Document the use of Go1.9+ for monotonic time where applicable 2017-06-29 16:07:12 +02:00
beorn7 f66cdf0736 Un-export MetricVec
This is in preparation for "curried" metric vecs, as discussed.

And it's a good thing anyway. The exported MetricVec was from a time
when I thought people would define own Metric types and then create
Vecs of it. That has never happened.
2017-06-28 17:55:59 +02:00
beorn7 721f93fda8 Deprecate UntypedVec 2017-06-28 17:00:33 +02:00
Brian Brazil ab4214782d Merge pull request #318 from AlekSi/patch-1
Minor documentation fix
2017-06-28 13:54:36 +01:00
Alexey Palazhchenko f0c4c478a2 Minor documentation fix 2017-06-28 15:40:03 +03:00
Björn Rabenstein de4d4ffe63 Merge pull request #308 from prometheus/beorn7/http
promhttp: Bite the bullet and implement all 32 possible interface combos
2017-06-06 12:22:53 +02:00
beorn7 14730c70c0 promhttp: Bite the bullet and implement all 32 possible interface combos
As it turned out, it's not that esay to guess "common" combination of
interface upgrades. So I decided to just implement all 32 possible
combination of interface upgrades. (Only 16 with Go 1.7 and earlier.)

Clearly, this calls for code generation. But right now, we still need
to find out what's the best form of the code. For later additions,
implementing code generation might be useful.

Note that newDelegator is called for each HTTP request. Thus, this
commit aims to make the upgrade selection quick. (After the type
checks, it's just directly accessing an element in a slice.)
2017-06-02 19:03:08 +02:00
Norbert Tretkowski e7e903064f Import "log", it is required for log.Fatal(... (#305)
Import "log" in the example doc comment

Package log is required for log.Fatal.
2017-05-31 15:00:54 +02:00
stuart nelson 2b3ab50dcd Add time to write header handler middleware (#304) 2017-05-29 11:42:43 +02:00
Björn Rabenstein 42552c195d Merge pull request #302 from prometheus/beorn7/http
Improve promhttp middleware
2017-05-11 16:12:51 +02:00
beorn7 023c31fd59 Fix handling of ConstLabels in checkLabels 2017-05-10 20:39:36 +02:00
beorn7 753a259e20 Improve promhttp tests
- Use local registry to avoid conflicts between tests.
- Expose https://github.com/prometheus/client_golang/issues/299 by
  using ConstLabels in a test.
- Improve example: Buckets and help string must be consistent, even
  if the former is not enforced as of now, but see
  https://github.com/prometheus/client_golang/issues/222
2017-05-10 19:49:36 +02:00
Björn Rabenstein b12dd9c58c Merge pull request #300 from prometheus/beorn7/http
Point to promhttp in deprecation notices
2017-05-09 23:03:59 +02:00