Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/chonton/dogstatd-client
A java client to push UDP messages to a local dogstatd.
https://github.com/chonton/dogstatd-client
java metrics up-for-adoption
Last synced: 3 days ago
JSON representation
A java client to push UDP messages to a local dogstatd.
- Host: GitHub
- URL: https://github.com/chonton/dogstatd-client
- Owner: chonton
- License: apache-2.0
- Created: 2016-11-08T07:10:26.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2023-11-20T20:54:41.000Z (11 months ago)
- Last Synced: 2023-11-20T21:41:55.528Z (11 months ago)
- Topics: java, metrics, up-for-adoption
- Language: Java
- Homepage:
- Size: 235 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# UP FOR ADOPTION
# dogstatd-client
A java client to push UDP messages to a local [dogstatd](http://docs.datadoghq.com/guides/dogstatsd/).[Javadoc](https://chonton.github.io/dogstatd-client/0.0.3/apidocs/) and
[build reports](https://chonton.github.io/dogstatd-client/0.0.3/project-reports) are available.### Requirements
* Minimal latency in the mainline processing
* Some, but not extreme buffering of outgoing messages
* Non-blocking write of UDP message
* Thread-safe sender
* Lack of dogstatd collector will be noted, but not cause failure of mainline processing### Assumptions
* A local (on the same host) dogstatd collector
* Firing a UDP message per application event will be cheaper than in-process aggregation of events## Use with Maven
To include dogstatd-client in your maven build, use the following fragment in your pom.
```xml
org.honton.chas
dogstatd-client
0.0.3
```## Typical Java Use
### In setup code
```java
// you only need a single instance, Sender is thread safe and send method does not block caller
static public final Sender METRICS = new Sender();
```### Sending some example metrics
```java
METRICS.send(new Histogram("histogram.name", latency);
METRICS.send(new Gauge("round", i, tag));
METRICS.send(new Counter("pi", 3.14));
METRICS.send(new Event("title", "message", "tag1", "tag2"));
```## 0.2 to 0.3
- Added public constructors for Event
- Added public constructors for ServiceCheck
- Metric changed to abstract
- Tags changed to package protected
- Validator changed to package protected