title: fluentd regex pattern not match error for NGINX logs
body: <p>I've setup fluentd to parse nginx access logs since I've added some extra fields to the logs I cannot use the nginx format. My configuration is:</p>
  
  <pre><code>   &lt;source&gt;
      @type tail
      @id service_www_accesslog
      path /var/log/containers/imager-nginx*.log
      pos_file /var/log/imager-nginx-containers.log.pos
      tag influxdb.*
      read_from_head true
      format /(?&lt;host&gt;[^ ]*) \[(?&lt;time&gt;[^\]]*)\] \[Cache:(?&lt;cache&gt;\b\w+\b)\] "(?&lt;CSMethod&gt;\b\w+\b) (?&lt;CSURIStem&gt;(?:\/[A-Za-z0-9$.+!*'(){},~:;=@#%&amp;_\-]*)+) (?&lt;request&gt;.*?)" (?&lt;SCStatus&gt;(?:(?:(?&lt;![0-9.+-])(?&gt;[+-]?(?:(?:[0-9]+(?:\.[0-9]+)?)|(?:\.[0-9]+)))))) (?&lt;image_size&gt;(?:(?:(?&lt;![0-9.+-])(?&gt;[+-]?(?:(?:[0-9]+(?:\.[0-9]+)?)|(?:\.[0-9]+)))))) "(?&lt;referer&gt;.*?)" "(?&lt;user_agent&gt;.*?)" "(?&lt;xforward&gt;.*?)" (?&lt;request_time&gt;(?:(?:(?&lt;![0-9.+-])(?&gt;[+-]?(?:(?:[0-9]+(?:\.[0-9]+)?)|(?:\.[0-9]+)))))) (?&lt;upstream_response&gt;.*?) (?&lt;upstream_connect&gt;.*?) (?&lt;upstream_header&gt;.*)/
      time_format %d/%b/%Y:%H:%M:%S %z
      @log_level debug
    &lt;/source&gt;
  </code></pre>
  
  <p>sample of the log:</p>
  
  <pre><code>10.244.1.0 [07/Dec/2018:16:51:49 +0000] [Cache:MISS] "GET /10e8cd74-94ec-4652-a5c9-d5df1110b9eb/475/400/60/false/blah.jpg HTTP/1.1" 200 60435 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.102 Safari/537.36" "172.23.8.123" 0.162 0.160 0.001 0.151
  </code></pre>
  
  <p>In the fluentd output I get an error:</p>
  
  <pre><code>2018-12-07 16:51:50 +0000 [warn]: #0 [service_www_accesslog] pattern not match: "{\"log\":\"10.244.1.0 [07/Dec/2018:16:51:49 +0000] [Cache:MISS] \\\"GET /10e8cd74-94ec-4652-a5c9-d5df1110b9eb/475/400/60/false/blah.jpg HTTP/1.1\\\" 200 60435 \\\"-\\\" \\\"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.102 Safari/537.36\\\" \\\"172.23.8.123\\\" 0.162 0.160 0.001 0.151\\n\",\"stream\":\"stdout\",\"time\":\"2018-12-07T16:51:49.224406444Z\"}"
  </code></pre>
  
  <p>I've tested the regex using several regex testers and it does have the correct output, I've also tested using <a href="http://fluentular.herokuapp.com/" rel="nofollow noreferrer">Fluentular</a> and used the output for the config.</p>
  
  <p>I'm not sure where to go from here in debugging this error. Any help would be appriciated</p>