DataDog / fluent-plugin-datadog

Fluentd output plugin for Datadog: https://www.datadog.com
Apache License 2.0
39 stars 26 forks source link

Receiving error_type:Net::HTTP::Persistent::Error after upgrading to 12 #38

Closed jasonmartens closed 4 years ago

jasonmartens commented 4 years ago

Describe what happened: Hello, we've been using this plugin on version 0.10.5 for quite a while. Today I tried upgrading to version 0.12.0, but started getting hundreds of these log messages: [out_send_to_datadog] Logging flush error in out_send_to_datadog, error_type:Net::HTTP::Persistent::Error I'm not sure how many logs were getting through to datadog, and quickly reverted.

Describe what you expected: I expected to not see errors and have the logs continue to be sent to Datadog.

Steps to reproduce the issue: Update to 0.12.0, send logs to datadog via this output plugin.

Additional environment details (Operating System, Cloud provider, etc): Fluentd version 1.2.4 running in a Kubernetes environment.

Here's the datadog output plugin config:

  <label @send_to_datadog>
    <match output.**>
      @id out_send_to_datadog
      @type datadog
      @log_level info
      api_key <snip>
      host <snip>
      ssl_port 10516
      dd_tags foo:bar
      <buffer>
        @type file
        path /var/log/fluent/out_send_to_datadog.buffer
        chunk_limit_size 10m
        total_limit_size 64g
        flush_interval 2
        flush_thread_interval 0.02
        flush_thread_burst_interval 0.001
        flush_thread_count 32
        retry_max_interval 2m
        retry_timeout 24h
      </buffer>
    </match>
  </label>
gaetan-deputier commented 4 years ago

Hello! Thanks for the report and for using the plugin. It seems that you're using a specific SSL_PORT ssl_port 10516 which, with the upgrade to 0.12.0, will overwrite the default HTTPS port (443) and I think is the reason of your errors.

I'd recommend to reduce the chunk_limit_size 10m to 5m to reduce an extra chunk split step in the output plugin.

Do you mind trying again without this specific port in your config?

jasonmartens commented 4 years ago

Hi, thanks for the response. I've updated our config, and seems to be working just fine now.