Skip to main content
Faraday is an HTTP client library that provides a single interface over many HTTP adapters. AppSignal instruments Faraday requests automatically when the Faraday gem is detected on start. No manual setup is required. Faraday sends requests through an underlying adapter, which is Net::HTTP by default. AppSignal also instruments some of these adapters, such as Net::HTTP and Excon. To avoid recording the same request twice, AppSignal records each Faraday request once as a Faraday event and does not instrument the adapter for that request.

Performance monitoring

Requests made with Faraday appear in the event timeline of your application’s performance actions as request.faraday events, showing the request method and host. They also appear in the “Slow API requests” performance panel, where you can review the requests your application makes to other services and the impact they have on its performance.

Disabling the integration

To disable the Faraday integration, set the instrument_faraday config option to false.

Span attributes

Collector mode only: this applies when AppSignal for Ruby runs in collector mode. It has no effect otherwise.
The request’s span carries:
  • http.request.method — the request method.
  • server.address and server.port — the host that was called.
  • url.full — the full request URL.
  • http.response.status_code — the status the other service responded with.

Distributed tracing

Collector mode only: this applies when AppSignal for Ruby runs in collector mode. It has no effect otherwise.
Requests made with this library carry the current trace to the service being called, in a traceparent request header. When that service reports to AppSignal too, its work joins the same trace. You can open a slow outgoing request and see what the other service spent its time on. The HTTP servers AppSignal supports continue the trace. Any other service starts its own.