<commit_before># `circonus-reaper`

The `circonus-reaper`:

- deactivates check bundles that were targeting hosts that are no longer present
  in Consul but are known to Circonus
- deactivates individual metrics in check bundles that belong to Nomad
  allocations that are no longer scheduled

## Installation

`go get -u github.com/sean-/circonus-reaper`

## Usage

```
Usage of circonus-reaper:
  -circonus-api-key string
    	Circonus API Key (CIRCONUS_API_KEY)
  -circonus-app-name string
    	Name to use as the application name in the Circonus API Token UI (default "reaper")
  -consul-addr string
    	Consul Agent Address (default "127.0.0.1:8500")
  -dry-run
    	Do not make any actual changes
  -exclude-target value
    	Targets to exclude (may be set more than once)
  -nomad-addr string
    	Nomad Agent Address (default "http://127.0.0.1:4646")
```

### Example Usage

```
$ circonus-reaper \
    -consul-addr=consul.service.consul:8500 \
    -exclude-target=127.0.0.1 \
    -exclude-target=q._caql \
    -exclude-target=rabbitmq.service.consul \
    -exclude-target=pg.example._aws \
    -nomad-addr=http://nomad.service.consul:4646/<commit_msg>Update the README to include the new `-exclude-regexp` arg.<commit_after># `circonus-reaper`

The `circonus-reaper`:

- deactivates check bundles that were targeting hosts that are no longer present
  in Consul but are known to Circonus
- deactivates individual metrics in check bundles that belong to Nomad
  allocations that are no longer scheduled

## Installation

`go get -u github.com/sean-/circonus-reaper`

## Usage

```
Usage of circonus-reaper:
  -circonus-api-key string
    	Circonus API Key (CIRCONUS_API_KEY)
  -circonus-app-name string
    	Name to use as the application name in the Circonus API Token UI (default "reaper")
  -consul-addr string
    	Consul Agent Address (default "127.0.0.1:8500")
  -dry-run
    	Do not make any actual changes
  -exclude-regexp value
    	Regexp for a targets to exclude (may be set more than once)
  -exclude-target value
    	Targets to exclude (may be set more than once)
  -nomad-addr string
    	Nomad Agent Address (default "http://127.0.0.1:4646")
```

### Example Usage

```
$ circonus-reaper \
    -consul-addr=consul.service.consul:8500 \
    -exclude-target=127.0.0.1 \
    -exclude-target=rabbitmq.service.consul \
    -exclude-regexp='.+\._(aws|caql)$' \
    -nomad-addr=http://nomad.service.consul:4646/
{'fraction_non_alphanumeric': 0.10699588477366255, 'fraction_numerical': 0.027983539094650206, 'mean_word_length': 3.2799295774647885, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 6, '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': '845737', 'n_tokens_mistral': 901, 'n_tokens_neox': 835, 'n_words': 244}