liveBook · Manning

Http plugin

As explained in Logs and Telemetry

An HTTP output plugin is a Fluent Bit output component that sends processed event data to a destination over HTTP.

An HTTP output plugin sends processed Fluent Bit events to a destination over HTTP. Configure it with a match pattern, host, port, and destination URI; then choose the payload format and request headers. section 5.8

Use the plugin when you need to:

  • Deliver events to an HTTP or JSON endpoint when no destination-specific plugin is available. section 5.8
  • Send JSON payloads and control date-time serialization with the format and json_date_format properties. section 5.8
  • Add request metadata through configured HTTP headers and support authentication-oriented endpoint validation. section 5.8
  • Connect standard-protocol systems alongside forward, TCP, and OpenTelemetry integrations. section 3.1

Forward incoming HTTP events to a local endpoint

An input listens on port 9881 while the output matches every event and posts JSON to http://127.0.0.1:8080/simple. The configuration adds the header fluentbit: http and serializes dates as ISO 8601. WireMock can provide the local endpoint and validate the request. section 5.8

Listing 5.10 HTTP output example: http-output.conf
[SERVICE]
  flush 1
  log_level error

[INPUT]
  name http    
  listen 0.0.0.0
  port 9881
  tag http-in

[OUTPUT]
  match *
  name http     #1
  port 8080     #2
  host 127.0.0.1
  uri /simple                  #3
  format json               #4
  header fluentbit http         #5
  json_date_format iso8601    #6

Inspect the complete Fluent Bit configuration for the HTTP input, HTTP output, JSON formatting, custom header, and ISO 8601 dates. section 5.8

How Logs and Telemetry covers it

How deep it goes
Defines configuration, payload formatting, headers, and POST-only behavior, but does not descend into plugin implementation internals.
Examples
Demonstrates WireMock, a local HTTP endpoint, JSON payloads, custom headers, and ISO 8601 date formatting.
What it assumes
Assumes familiarity with Fluent Bit pipelines, event matching, and the host, port, URI, and header parts of an HTTP destination.
What you can do after
Operate/configure Fluent Bit to POST matched events as formatted JSON to an HTTP endpoint.
How it connects
Connects HTTP with Fluent Bit, Fluentd, the forward plugin, TCP, and OpenTelemetry protocol integrations.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Logs and Telemetry. The section links point to the parts of the book it draws on.