Commit Graph

1081 Commits

Author SHA1 Message Date
Bernerd Schaefer 9ba7cdf4cf Merge pull request #15 'feature/expose-schema-through-content-type' 2013-04-29 10:18:09 +02:00
Matt T. Proud 4c1c13d109 Merge pull request #9 from prometheus/refactor/user-experience/standardized-directories
Rearrange file and package per convention.
2013-04-28 10:43:02 -07:00
Matt T. Proud 960107461e Migrate documentation to markdown. 2013-04-28 19:21:30 +02:00
Bernerd Schaefer f60c783b29 Adhere to telemetry schema 0.0.2
* The schema and version of telemetry data is exposed through the
  Content-Type header instead of through a custom HTTP Header.

See [Prometheus Client Data Exposition Format][1] for more details.

[1]: https://docs.google.com/a/soundcloud.com/document/d/1ZjyKiKxZV83VI9ZKAXRGKaUKK2BIWCT7oiGBKDBpjEY/edit#heading=h.wnviarbnyxcj
2013-04-25 17:43:03 +02:00
Bernerd Schaefer 04c7f7bc7f Merge pull request #12 from prometheus/refactor/reduce-marshaling-complexity
Refactor/reduce marshaling complexity
2013-04-19 06:12:13 -07:00
Bernerd Schaefer 71dd60e431 Registry and Metrics implement json.Marshaler
* Drop `AsMarshallable()` from the Metric interface. Use
  `json.Marshaler` and `MarshalJSON()`, and leverage JSON struct tags
  where possible.

* Add `MarshalJSON()` to Registry and remove `dumpToWriter`, which
  makes the registry handler much simpler.

In addition to simplifying some of the marshalling behavior, this also
has the nice side effect of cutting down the number of
`map[string]interface{}` instances.
2013-04-19 15:07:24 +02:00
Bernerd Schaefer 3433b798b3 Use raw string literals in tests 2013-04-19 15:04:07 +02:00
Bernerd Schaefer 0b30e065c8 Metrics explicitly implement Metric interface 2013-04-19 15:04:07 +02:00
Bernerd Schaefer c39c592874 Merge pull request #13 from prometheus/refactor/remove-timer
Remove timer.go and timer_test.go
2013-04-19 06:02:35 -07:00
Bernerd Schaefer 9fccb96989 Remove timer.go and timer_test.go 2013-04-19 14:44:15 +02:00
Matt T. Proud f320d28a6c Rearrange file and package per convention.
WIP - Please review but do not merge.
2013-04-04 15:27:09 +02:00
Matt T. Proud a087e013a5 Merge pull request #6 from prometheus/feature/user-love/http-mux-wrapper
Add HTTP multiplexor wrapper for automatic telemetry.
2013-04-02 03:41:10 -07:00
Matt T. Proud 643925d012 Merge pull request #7 from prometheus/refactor/pointers/only-on-mutation
Pointers to references for non-mutation calls.
2013-04-02 03:38:32 -07:00
Matt T. Proud c5b4952f97 Add HTTP multiplexor wrapper for automatic telemetry. 2013-04-02 12:10:12 +02:00
Matt T. Proud 9a416628a9 Pointers to references for non-mutation calls.
No performance differences, but more idiomatic with standard library.
2013-04-01 18:41:50 +02:00
juliusv 6c08aa2e95 Merge pull request #5 from prometheus/documentation/community/api-reference
Include link to generated API documentation.
2013-03-28 02:53:56 -07:00
Matt T. Proud e47bd1785d Include link to generated API documentation.
Include mailing list.
2013-03-28 10:46:16 +01:00
Matt T. Proud 552bef44bd Run gofmt on corpus and include deprecation. 2013-03-28 10:46:16 +01:00
juliusv ed0a3bcbc3 Merge pull request #4 from prometheus/usability/sundry
Run gofmt on corpus and include deprecation.
2013-02-18 07:34:00 -08:00
Matt T. Proud 95af66aca5 Run gofmt on corpus and include deprecation. 2013-02-18 09:30:47 -06:00
juliusv 339ecd434d Merge pull request #3 from prometheus/usability/sundry
Fix documentation after reading via server.
2013-02-18 04:59:08 -08:00
Matt T. Proud ee7ab62137 Fix documentation after reading via server.
Examining the existing documentation over the standard Go documentation
server revealed some serious formatting flaws.  Everything should be
readable now.
2013-02-17 22:28:56 -06:00
Matt T. Proud d822e70a37 Merge pull request #2 from prometheus/usability/sundry
Sundry cosmetic fixes across the board.
2013-02-13 09:24:06 -08:00
Matt T. Proud 6c3a2ddddb Sundry cosmetic fixes across the board.
- Comments are migrated from ``/* */`` to ``//`` per convention.

- ``NewDefaultHistogram`` helper.

- ``Registry.Handler`` and ``Registry.YieldExporter`` deprecation.

- Cleanup of legacy import paths.

- Updating examples to use acknowledged patterns.

- Parameterizing the random parameter namespaces for ``examples/random/main.go``, which is useful for demoing population behaviors.
2013-02-13 09:21:44 -08:00
juliusv e1bfb0c101 Merge pull request #1 from matttproud-soundcloud/feature/contrib/response-delegate
Include Daniel's ResponseWriter delegate type.
2013-01-31 06:36:22 -08:00
Matt T. Proud 13c269c19c Include Daniel's ResponseWriter delegate type. 2013-01-31 14:28:09 +01:00
Matt T. Proud b0dbdfcf11 Update wrong Travis CI path. 2013-01-25 18:06:33 +01:00
Matt T. Proud 989a398e79 Update paths to new repository location. 2013-01-25 17:50:41 +01:00
Matt T. Proud 5a29c27491 Merge pull request #13 from matttproud/feature/labels/base-exposed
Update client to reflect new API needs.
2013-01-23 04:09:17 -08:00
Matt T. Proud 0f93b588cd Update client to reflect new API needs.
1. The output format is now versioned per the Semantic Versioning scheme.  Mainline Prometheus will be adapted to use differing consumption methodologies as the generators' formats evolve to support legacy clients.

2. The telemetry outputter now supports GZIP output encoding.  In sample runs, this cuts the output size in half.

3. Basic sanity tests are added for registration with varying levels of pedanticness.

4. We have support for base labels in the registration and emission phases.

5. We have label support for individual metric mutation operations.

6. A number of simplications have been made.
2013-01-23 13:07:12 +01:00
Matt T. Proud 01c4092691 Merge pull request #12 from matttproud/refactor/decouple-from-bazaar
Decouple from Bazaar.
2013-01-18 07:36:48 -08:00
Matt T. Proud acf4e9ce2b Decouple from Bazaar.
Having to use Bazaar to access gocheck is onerous.  We have simply
forked it at a revision until all tests can be replaced with
table-driven ones.
2013-01-18 16:29:47 +01:00
Matt T. Proud c19702aca2 Merge pull request #11 from matttproud/feature/include-instance-uptime
Include instance uptime information in the stack.
2013-01-18 07:25:10 -08:00
Matt T. Proud 4cab4a892e Include instance uptime information in the stack. 2013-01-18 15:50:16 +01:00
juliusv d670ebaba5 Merge pull request #9 from matttproud/feature/base-labels-on-registration
Add ``baseLabels`` to the registration signature.
2013-01-15 11:36:00 -08:00
Matt T. Proud 1134be8073 Add ``baseLabels`` to the registration signature. 2013-01-15 20:18:43 +01:00
juliusv 32452fc15a Merge pull request #8 from matttproud/feature/docstrings-on-registration
Add docstrings in registration signature.
2013-01-15 11:13:15 -08:00
Matt T. Proud e53e7ec940 Add docstrings in registration signature. 2013-01-15 20:10:04 +01:00
juliusv 4aad7189f1 Merge pull request #7 from matttproud/feature/setable-ports-in-examples
Make listening port for examples to be settable.
2013-01-11 14:51:56 -08:00
Matt T. Proud 1800ee2925 Make listening port for examples to be settable.
This will be better for our own internal tests.
2013-01-11 22:52:36 +01:00
Matt T. Proud e9b12f3921 Merge pull request #6 from kesselborn/basic-auth-fix
Tell clients to authenticate with basic auth
2013-01-09 05:02:42 -08:00
Daniel Bornkessel 0f7fe643f0 Tell clients to authenticate with basic auth 2013-01-09 13:59:50 +01:00
Matt T. Proud 872a959b31 Merge pull request #5 from kesselborn/feature/basic-auth-support
Implement simple basic auth for the exporter
2013-01-09 03:51:09 -08:00
Daniel Bornkessel 3dbf5d550b Rename YieldProtectedExporter -> YieldBasicAuthExporter 2013-01-09 12:48:33 +01:00
Daniel Bornkessel 45f6fe3bf1 Constantize string 2013-01-09 12:47:33 +01:00
Matt T. Proud 397d68435c Merge pull request #4 from kesselborn/feature/correct-content-type
Remove explicit WriteHeader call to have correct content type
2013-01-09 03:35:29 -08:00
Daniel Bornkessel ca53ce1081 Implement simple basic auth for the exporter
So this can be quickly thrown into public projects until better
methods of authentications are available
2013-01-08 16:56:19 +01:00
Daniel Bornkessel 05891fd731 Remove explicit WriteHeader call to have correct content type
According to the documentation:

    // WriteHeader sends an HTTP response header with status code.
    // If WriteHeader is not called explicitly, the first call to Write
    // will trigger an implicit WriteHeader(http.StatusOK).
    // Thus explicit calls to WriteHeader are mainly used to
    // send error codes.

and

    // Header returns the header map that will be sent by WriteHeader.
    // Changing the header after a call to WriteHeader (or Write) has
    // no effect.

so calling `w.Header().Set(contentType, jsonContentType)` after calling
`w.WriteHeader` does not set the content type -- the call can be removed
though as it always set `http.StatusOK` which will be done anyways
2013-01-03 18:44:50 +01:00
Matt T. Proud 474d1d53d1 Merge pull request #3 from kesselborn/feature/extract-counter-from-gauge
Split Gauge into Gauge and Counter
2012-12-19 02:54:51 -08:00
Daniel Bornkessel 4cb006cce4 Split Gauge into Gauge and Counter
Counter is a separate metric now
2012-12-19 11:49:38 +01:00