Documentation forSolarWinds Observability

Add a Ruby service

The SolarWinds Observability Ruby Library provides automatic tracing and metrics for Ruby applications. For new features, fixed issues, and updated components, see the Ruby Library Release Notes.

Get started

The SolarWinds Observability Ruby Library is a gem called solarwinds_apm hosted on RubyGems. The Ruby Library instruments applications based on the Ruby language and Ruby on Rails framework.

The Ruby Library collects detailed insights without any code modification. For a list of instrumented gems and components see platform support.

The gem is easy to install with the command gem install solarwinds_apm, and requires limited configuration. See Install the Ruby Library for full installation instructions for Ruby and different frameworks, and Configure the Ruby Library for library customization options.


Ensure that your application components are supported and the platform for your APM library is supported. Also, verify your firewall configuration permits TCP/HTTPS/TLS outbound connections to (where xx-yy is determined by the URL you use to access SolarWinds Observability, see Endpoint URIs) using port 443. See Firewall or access control requirements.

To enable instrumentation for a Ruby application and send the data to SolarWinds Observability:

  1. In SolarWinds Observability, click Add Data in the upper-right corner.

  2. In the Add Data dialog, click Services.

  3. Type a Name for your service and select the Ruby language.

  4. Create or select an API Ingestion token to use when sending your collected service data by doing either of the following:

    • Select Generate New Token and enter an Ingestion Token Name, then click Next.
    • Select Use Existing Token and select an ingestion token from the list, then click Next.
  5. Install and require the solarwinds_apm gem. See Install.

  6. Set the SW_APM_SERVICE_KEY system environment variable. The Service key for the service you are adding is shown in the Add Data dialog. See Configuration.

  7. When the Ruby Library successfully connects to the SolarWinds APM collector, the Waiting for Connection button in SolarWinds Observability changes to OK.

  8. Click OK to finish setting up the service.

Custom instrumentation

If you have code or a library that is not on the platform support list, use our SDK to customize the instrumentation.