<commit_before># Getting started

This project encompasses:

1. A Java client for the Riemann protocol
2. The Riemann protocol buffer definition, and
3. Its corresponding (autogenerated) Java classes
 
Artifacts are available through
[clojars](https://clojars.org/com.aphyr/riemann-java-client) which you can add
to your maven repository like so:

```xml
<repository>
  <id>clojars.org</id>
  <url>http://clojars.org/repo</url>
</repository>
```

## Example

``` java
RiemannClient c = RiemannClient.tcp("my.riemann.server", 5555);
c.event().
  service("fridge").
  state("running").
  metric(5.3).
  tags("appliance", "cold").
  send();

c.query("tagged \"cold\" and metric > 0"); // => List<Event>;
``` 

# Status

The TCP client is in its early stages; it does not handle server error
responses correctly and offers no pooling or retries. The top-level API for
sending events and querying the index is functional and threadsafe. A small DSL
is available to make sending events easier.<commit_msg>Updated code example in README.markdown to include calls to .connect() and .disconnect()<commit_after># Getting started

This project encompasses:

1. A Java client for the Riemann protocol
2. The Riemann protocol buffer definition, and
3. Its corresponding (autogenerated) Java classes
 
Artifacts are available through
[clojars](https://clojars.org/com.aphyr/riemann-java-client) which you can add
to your maven repository like so:

```xml
<repository>
  <id>clojars.org</id>
  <url>http://clojars.org/repo</url>
</repository>
```

## Example

``` java
RiemannClient c = RiemannClient.tcp("my.riemann.server", 5555);
c.connect();
c.event().
  service("fridge").
  state("running").
  metric(5.3).
  tags("appliance", "cold").
  send();

c.query("tagged \"cold\" and metric > 0"); // => List<Event>;
c.disconnect();
``` 

# Status

The TCP client is in its early stages; it does not handle server error
responses correctly and offers no pooling or retries. The top-level API for
sending events and querying the index is functional and threadsafe. A small DSL
is available to make sending events easier.
{'fraction_non_alphanumeric': 0.1241674595623216, 'fraction_numerical': 0.009514747859181731, 'mean_word_length': 4.434108527131783, 'pattern_counts': {'":': 0, '<': 17, '<?xml version=': 0, '>': 21, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 2}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3341647', 'n_tokens_mistral': 683, 'n_tokens_neox': 627, 'n_words': 238}