<commit_before>cookbook_file "/usr/local/collectd/collectd-mailstats.sh" do
  source "collectd-mailstats.sh"
  owner "root"
  group "wheel"
  mode 0755
end

node.default[:yagd][:additional_metrics][:mailstats] = {
  "messages received" => "collectd.#{node[:fqdn].gsub(".","_")}.mailstats-*.messages.rx",
  "messages sent" => "collectd.#{node[:fqdn].gsub(".","_")}.mailstats-*.messages.tx",
  "bytes received" => "collectd.#{node[:fqdn].gsub(".","_")}.mailstats-*.bytes.rx",
  "bytes sent" => "collectd.#{node[:fqdn].gsub(".","_")}.mailstats-*.bytes.tx"
}<commit_msg>generate yagd config for rejected/discarded/quarantined messages<commit_after>cookbook_file "/usr/local/collectd/collectd-mailstats.sh" do
  source "collectd-mailstats.sh"
  owner "root"
  group "wheel"
  mode 0755
end

node.default[:yagd][:additional_metrics][:mailstats] = {
  "messages received" => "collectd.#{node[:fqdn].gsub(".","_")}.mailstats-*.messages.rx",
  "messages sent" => "collectd.#{node[:fqdn].gsub(".","_")}.mailstats-*.messages.tx",
  "bytes received" => "collectd.#{node[:fqdn].gsub(".","_")}.mailstats-*.bytes.rx",
  "bytes sent" => "collectd.#{node[:fqdn].gsub(".","_")}.mailstats-*.bytes.tx",
  "messages rejected" => "collectd.#{node[:fqdn].gsub(".","_")}.mailstats-*.messages_rejected",
  "messages discarded" => "collectd.#{node[:fqdn].gsub(".","_")}.mailstats-*.messages_discarded",
  "messages quarantined" => "collectd.#{node[:fqdn].gsub(".","_")}.mailstats-*.messages_quarantined"
}
{'fraction_non_alphanumeric': 0.24949290060851928, 'fraction_numerical': 0.005409060175794456, 'mean_word_length': 5.91588785046729, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 14, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, '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': '4655037', 'n_tokens_mistral': 563, 'n_tokens_neox': 558, 'n_words': 64}