lib/oboe/inst/moped.rb in oboe-1.4.2.2 vs lib/oboe/inst/moped.rb in oboe-2.1.1
- old
+ new
@@ -21,11 +21,11 @@
end
end
end
if defined?(::Moped) and Oboe::Config[:moped][:enabled]
- puts "[oboe/loading] Instrumenting moped" if Oboe::Config[:verbose]
+ Oboe.logger.info "[oboe/loading] Instrumenting moped" if Oboe::Config[:verbose]
if defined?(::Moped::Database)
module ::Moped
class Database
include Oboe::Inst::Moped
@@ -71,11 +71,11 @@
Oboe::Inst::Moped::DB_OPS.each do |m|
if method_defined?(m)
class_eval "alias #{m}_without_oboe #{m}"
class_eval "alias #{m} #{m}_with_oboe"
- else puts "[oboe/loading] Couldn't properly instrument moped (#{m}). Partial traces may occur."
+ else Oboe.logger.warn "[oboe/loading] Couldn't properly instrument moped (#{m}). Partial traces may occur."
end
end
end
end
end
@@ -131,11 +131,11 @@
Oboe::Inst::Moped::INDEX_OPS.each do |m|
if method_defined?(m)
class_eval "alias #{m}_without_oboe #{m}"
class_eval "alias #{m} #{m}_with_oboe"
- else puts "[oboe/loading] Couldn't properly instrument moped (#{m}). Partial traces may occur."
+ else Oboe.logger.warn "[oboe/loading] Couldn't properly instrument moped (#{m}). Partial traces may occur."
end
end
end
end
end
@@ -312,11 +312,11 @@
Oboe::Inst::Moped::QUERY_OPS.each do |m|
if method_defined?(m)
class_eval "alias #{m}_without_oboe #{m}"
class_eval "alias #{m} #{m}_with_oboe"
- else puts "[oboe/loading] Couldn't properly instrument moped (#{m}). Partial traces may occur."
+ else Oboe.logger.warn "[oboe/loading] Couldn't properly instrument moped (#{m}). Partial traces may occur."
end
end
end
end
end # ::Moped::Query
@@ -406,10 +406,10 @@
Oboe::Inst::Moped::COLLECTION_OPS.each do |m|
if method_defined?(m)
class_eval "alias #{m}_without_oboe #{m}"
class_eval "alias #{m} #{m}_with_oboe"
- else puts "[oboe/loading] Couldn't properly instrument moped (#{m}). Partial traces may occur."
+ else Oboe.logger.warn "[oboe/loading] Couldn't properly instrument moped (#{m}). Partial traces may occur."
end
end
end
end
end # ::Moped::Collection