title: Count/increment is not working in logstash
body: <p>I filter some "status code" as output attribute from each line. like, <strong>code = 100, code = 100, code = 200, code = 200,code =  200,code =  300</strong></p>
  
  <p>Here, I'm trying to get the count of each type of status codes like <strong>100 = 2, 200 = 3, 300 = 1</strong> </p>
  
  <p>The config am working on looks like,</p>
  
  <pre><code>filter {
   grok {
      patterns_dir =&gt; ["./patterns"]
      match =&gt; [ "message", ["%{CUSTOMPATTERN:code}"  ]]
   }
   mutate {
      remove_field =&gt; ["host", "path", "@version", "@timestamp"]
   }
  }
  
  output {
   statsd {
         increment =&gt; "%{code}"
         count =&gt; ["code", "%{code}"]
         }
   stdout {
         codec =&gt; json
   }
  }
  </code></pre>
  
  <p>I know the statsd config is wrong, but couldn't fix it.</p>