fluent-bit icon indicating copy to clipboard operation
fluent-bit copied to clipboard

out_http: don't retry non retryable 4xx status codes

Open seblaz opened this issue 1 year ago • 0 comments

Bug Report

Describe the bug Currently, the http output plugin retries all requests that respond with an 4xx status code: https://github.com/fluent/fluent-bit/blob/910009855636921dfeabd7defe1cae5c494a4bea/plugins/out_http/http.c#L268 Nevertheless, most 4xx status codes are non retryable and will keep retrying forever.

To Reproduce

  • Steps to reproduce the problem:
  1. Configure fluent-bit with an http output
  2. Make the http output return a 400 status code
  3. The chunks are retried forever

Expected behavior Don't retry 4xx status codes, except for 429.

Your Environment

  • Version used: 3.0.4
  • Configuration:
[INPUT]
    Name  cpu
    Tag   cpu

[OUTPUT]
    Name  http
    Match *
    Host  192.168.2.3
    Port  80
    URI   /something
  • Environment name and version (e.g. Kubernetes? What version?): Docker
  • Filters and plugins: out_http

seblaz avatar May 23 '24 14:05 seblaz