module Honeycomb::Redis::Configuration

Patches Redis with the option to configure the Honeycomb client.

When you load this integration, each Redis call will be wrapped in a span containing information about the command being invoked.

This module automatically gets mixed into the Redis class so you can change the underlying {Honeycomb::Client}. By default, we use the global {Honeycomb.client} to send events. A nil client will disable the integration altogether.

@example Custom client

Redis.honeycomb_client = Honeycomb::Client.new(...)

@example Disabling instrumentation

Redis.honeycomb_client = nil

Attributes

honeycomb_client[W]

Public Instance Methods

honeycomb_client() click to toggle source
# File lib/honeycomb/integrations/redis.rb, line 25
def honeycomb_client
  return @honeycomb_client if defined?(@honeycomb_client)

  Honeycomb.client
end