Commit Graph

1765 Commits

Author SHA1 Message Date
beorn7 9527eaa080 Cut v0.3.1. 2015-03-04 12:49:44 +01:00
beorn7 330e2c938a Use go1.4.2 in Makefile. 2015-03-04 12:41:07 +01:00
beorn7 cbe221c969 Switch to sync.Pool.
sync.Pool is after all faster than the home-made free list. Especially
under contention. To prove that, this commit also adds a benchmark for
concurrent fingerprint calculation.

Benchmark results:
(Run with -cpu=1,2,4. x-y -> x goroutines with GOMAXPROCS=y.)

benchmark                                     old ns/op     new ns/op     delta
BenchmarkMetricToFingerprintTripleConc4-4     320           138           -56.88%
BenchmarkMetricToFingerprintTripleConc8-4     314           141           -55.10%
BenchmarkMetricToFingerprintTripleConc4-2     344           264           -23.26%
BenchmarkMetricToFingerprintTripleConc2-4     331           256           -22.66%
BenchmarkMetricToFingerprintTripleConc8-2     338           263           -22.19%
BenchmarkMetricToFingerprintTripleConc1-4     599           505           -15.69%
BenchmarkMetricToFingerprintTripleConc4       553           493           -10.85%
BenchmarkMetricToFingerprintTripleConc2-2     327           292           -10.70%
BenchmarkMetricToFingerprintTripleConc8       554           496           -10.47%
BenchmarkMetricToFingerprintTripleConc2       555           501           -9.73%
BenchmarkMetricToFingerprintTripleConc1       554           509           -8.12%
BenchmarkMetricToFingerprintTripleConc1-2     551           513           -6.90%
2015-03-04 12:35:06 +01:00
beorn7 1002745d7b Fix whitespace. 2015-03-03 18:41:06 +01:00
Björn Rabenstein dbbb6c9e1d Merge pull request #88 from prometheus/beorn7/release
Cut release 0.3.0.
2015-03-03 18:23:59 +01:00
beorn7 9b11ef161e Cut release 0.3.0. 2015-03-03 18:17:26 +01:00
Björn Rabenstein cbe3ef2442 Merge pull request #87 from prometheus/beorn7/fingerprint
Unify fingerprinting aka signature calculation.
2015-03-03 18:03:08 +01:00
beorn7 af21d456db Unify fingerprinting aka signature calculation.
This fixes https://github.com/prometheus/client_golang/issues/74 .

IT CHANGES THE FINGERPRINTING AND THEREFORE INVALIDATES EACH AND EVERY
PERSISTED FINGERPRINT (I.E. YOU HAVE TO WIPE THE STORAGE TO USE THIS).

This commit removes the LabelValuesToSignature function as it is used
nowhere (and broken in the way it is implemented right now).

Also, remove one more golint warning.
2015-03-03 17:55:37 +01:00
Julius Volz de5f7a2db9 Merge pull request #86 from prometheus/unrewrite-godeps
Use non-rewritten Godep imports.
2015-02-27 16:55:31 +01:00
Julius Volz 738b69e61a Use non-rewritten Godep imports. 2015-02-27 16:49:40 +01:00
Björn Rabenstein a6c5e0f955 Merge pull request #83 from prometheus/godep-vendoring
Use godep with import rewriting for vendoring.
2015-02-26 15:04:24 +01:00
Julius Volz ea69be23d0 Add newly vendored libraries to NOTICE file. 2015-02-26 14:04:24 +01:00
Julius Volz 169c8a68e1 Use godep with import rewriting for vendoring.
The new vendoring was produced by running:

    godep save -r ./examples/... ./prometheus/... ./text/... ./model/... ./extraction/...

Two things to note:

- "extraction/processor0_0_{1,2}_test.go" imported a package from
  "github.com/prometheus/prometheus", all for just one tiny testing
  function. To not have to deal with a circular vendoring dependency, I
  simply replaced the usage of the function by some in-line logic.

- godep grouped the rewritten imports slightly differently for some
  reason, but at least the standard library imports are still in a
  separate section. Not sure if it's worth manually keeping our old
  import grouping scheme or if we should simply use that godep-generated
  one.
2015-02-26 00:47:03 +01:00
beorn7 39e4bc83f9 Release 0.2.0. 2015-02-23 17:51:34 +01:00
Björn Rabenstein 3f532e73b1 Merge pull request #81 from prometheus/beorn7/versioning
Update vendoring of beorn7/perks.
2015-02-23 16:53:10 +01:00
Björn Rabenstein 764e6a72c3 Merge pull request #82 from prometheus/beorn7/histogram
Add a histogram to the random example.
2015-02-23 16:36:40 +01:00
beorn7 28973f4d4f Add a histogram to the random example. 2015-02-23 16:19:01 +01:00
beorn7 14c2f30b35 Update vendoring of beorn7/perks. 2015-02-23 14:59:14 +01:00
Björn Rabenstein 54238dea8f Merge pull request #80 from peterbourgon/histogram-registry-fix
Fix for Histogram in registry.writePB
2015-02-20 19:23:41 +01:00
Peter Bourgon 69c8dc87e9 Fix for Histogram in registry.writePB 2015-02-20 19:08:36 +01:00
Björn Rabenstein bc1f2b27ad Merge pull request #79 from prometheus/beorn7/histogram
Use binary search to pick bucket.
2015-02-20 15:54:51 +01:00
beorn7 79efd06178 Use binary search to pick bucket.
With the usual number of buckets, this doesn't really make a
difference, but it should scale... See the added TODO for the precise
numbers.
2015-02-20 15:53:53 +01:00
Björn Rabenstein 38dbb2e268 Merge pull request #78 from prometheus/beorn7/histogram
Histograms for the exposition library.
2015-02-19 16:16:15 +01:00
beorn7 9eaf3705d2 Avoid "online serving system". 2015-02-19 16:03:24 +01:00
beorn7 000ef45157 Replaced http by HTTP if used as the name of the protocol in English. 2015-02-19 15:54:26 +01:00
beorn7 b1e7299877 Turned "le" and "quantile" label names into constants. 2015-02-19 15:54:26 +01:00
beorn7 3e50eddd64 Do not count the +Inf bucket for bucket creation.
Add explanation for DefBuckets.
2015-02-19 15:54:26 +01:00
beorn7 4c4f51d546 Catch illegal label names for summaries in histograms. 2015-02-19 15:54:26 +01:00
beorn7 6958242277 Add support for histograms to the Go client library. 2015-02-19 15:54:26 +01:00
beorn7 b37ca982a9 Add support for optionally missing +Inf bucket in protobuf.
Also, clean up style issues in metricfamilyprocessor.go.
2015-02-19 15:54:26 +01:00
beorn7 a7c56882af Mark slow test as such and exclude them from travis. 2015-02-19 15:51:11 +01:00
juliusv 4627d59e8a Merge pull request #77 from prometheus/update-protobuf-pkg
Update protobuf library package name.
2015-02-14 00:04:33 +01:00
Julius Volz 765fdaf37e Update protobuf library package name.
The Golang protocol buffer library has now moved to GitHub:

https://github.com/golang/protobuf

Although "go get"-ing the old package name still works, moving
everything to the new one will make vendoring cleaner.

See also https://github.com/matttproud/golang_protobuf_extensions/pull/7
2015-02-14 00:00:34 +01:00
Björn Rabenstein 70f54973fb Merge pull request #75 from prometheus/beorn7/timestamp
Reduce allocations during fingerprinting.
2015-02-12 20:02:02 +01:00
Björn Rabenstein 3d6b23ae05 Merge pull request #76 from prometheus/histogram
Add support for histograms to parsers, extraction and creation.
2015-02-12 19:33:48 +01:00
Brian Brazil 6f2f8f28e8 Add support for histograms to parsers, extraction and creation.
This does not include a histogram metric usable from the go client.

See https://docs.google.com/document/d/1uSenXRDjDaJLV3qnSD09GqgPdEEDPjER0mVsnGaCYF0/edit#
2015-02-12 18:29:26 +00:00
beorn7 a9bdd32c71 Reduce allocations during fingerprinting.
Also, add a test to expose
https://github.com/prometheus/client_golang/issues/74 .

benchmark           old ns/op     new ns/op     delta
BenchmarkMetric     7034          6272          -10.83%

benchmark           old allocs     new allocs     delta
BenchmarkMetric     52             32             -38.46%

benchmark           old bytes     new bytes     delta
BenchmarkMetric     1976          1800          -8.91%
2015-02-12 15:28:31 +01:00
Tobias Schmidt 3d127c266e Merge pull request #73 from ddysher/fix-doc
Fix document
2015-02-11 17:44:59 -05:00
Deyuan Deng 550b950411 Fix document 2015-02-11 17:35:04 -05:00
Tobias Schmidt acbd2d3eac Merge pull request #70 from prometheus/handle-process-collector-errors-gracefully
Handle process collector errors gracefully
2015-02-11 15:08:24 -05:00
Tobias Schmidt 98061eecab Add todo comment to bring back error reporting 2015-02-11 14:58:35 -05:00
Björn Rabenstein 6760c3aacd Merge pull request #71 from prometheus/beorn7/timestamp
Remove obsolete comment and add Earliest and Latest timestamp.
2015-02-11 17:44:10 +01:00
beorn7 7d560564f9 Remove obsolete comment and add Earliest and Latest timestamp.
The latter is to eradicate the various MaxInt64 and MinInt64 in the
codebase.
2015-02-11 17:34:59 +01:00
Tobias Schmidt 7faf9e76ef Handle process collector errors gracefully
As it is expected that the process collector can fail under certain
conditions (proc information for a process only readable by root or
other user for example) and as there is currently no option to configure
the error behavior of the client, this change reverts the error
reporting introduced in 159e96f. This effectively means that errors are
simply ignored and there won't be any samples for the process_* metrics
in case of an error.

Once a user can control how to behave in case of errors returned by
collectors, this change should probably be reverted.
2015-02-10 16:19:27 -05:00
Tobias Schmidt c70db11f1e Merge pull request #68 from prometheus/add-nocgo-flag
Add 'nocgo' tag to remove cgo dependency on build
2015-02-10 03:43:17 -05:00
Johannes 'fish' Ziemke 93d11c8e35 Remove procfs dependency unless cgo is enabled 2015-02-09 16:38:04 +01:00
juliusv 52186fc518 Merge pull request #67 from prometheus/arch-os-build-fixes
Fix Go download link for several archs and OSes.
2015-02-05 18:14:57 +01:00
Julius Volz ecf2329b22 Use HTTPS for Go download. 2015-02-05 18:14:34 +01:00
Julius Volz 2e52ab1271 Fix Go download link for several archs and OSes. 2015-02-05 18:14:34 +01:00
Tobias Schmidt 3823272e90 Merge pull request #65 from prometheus/procfs-build-tags
Remove dependency on procfs/cgo in non-procfs systems
2015-02-02 15:51:36 -05:00