run_server

Function run_server 

Source
pub fn run_server<S>(
    storage: &S,
    port: u16,
    mode: Option<OtelMode>,
) -> Result<(), Error>
where S: Storage,
Expand description

Run the OTLP HTTP server.

This function starts an HTTP server on the specified port that receives OpenTelemetry logs and stores them using the provided storage backend.

§Arguments

  • storage - Storage backend (only used in library mode)
  • port - Port to listen on
  • mode - Processing mode (None uses config default)

§Endpoints

  • POST /v1/logs - Receive and process OpenTelemetry log data
  • GET /health - Health check endpoint for service identification

§Panics

This function runs indefinitely and only returns on error.