Module: Datadog::Contrib::Mysql2::Patcher

Includes:
Patcher
Defined in:
lib/ddtrace/contrib/mysql2/patcher.rb

Overview

Patcher enables patching of 'mysql2' module.

Class Method Summary collapse

Methods included from Patcher

included

Class Method Details

.patch ⇒ Object



18
19
20
# File 'lib/ddtrace/contrib/mysql2/patcher.rb', line 18

def patch
  patch_mysql2_client
end

.patch_mysql2_client ⇒ Object



22
23
24
# File 'lib/ddtrace/contrib/mysql2/patcher.rb', line 22

def patch_mysql2_client
  ::Mysql2::Client.include(Instrumentation)
end

.target_version ⇒ Object



14
15
16
# File 'lib/ddtrace/contrib/mysql2/patcher.rb', line 14

def target_version
  Integration.version
end