Skip to content

Commit

Permalink
io_ hooks are risky to trace as it might cause re-entrancy.
Browse files Browse the repository at this point in the history
  • Loading branch information
ioquatix committed Nov 6, 2024
1 parent d3d7304 commit 254482c
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 37 deletions.
2 changes: 1 addition & 1 deletion config/traces.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@

def prepare
require 'traces/provider/async/task'
# require 'traces/provider/async/scheduler'
require 'traces/provider/async/scheduler'
end
36 changes: 0 additions & 36 deletions lib/traces/provider/async/scheduler.rb
Original file line number Diff line number Diff line change
Expand Up @@ -33,42 +33,6 @@
# Traces.trace("async.scheduler.address_resolve", attributes: attributes) {super}
# end

# def io_wait(io, events, timeout = nil)
# attributes = {
# io: io.to_s,
# events: events,
# timeout: timeout
# }

# Traces.trace("async.scheduler.io_wait", attributes: attributes) {super}
# end

# if Async::Scheduler.method_defined?(:io_read)
# def io_read(io, buffer, length, offset = 0)
# attributes = {
# io: io.to_s,
# buffer: buffer,
# length: length,
# offset: offset,
# }

# Traces.trace("async.scheduler.io_read", attributes: attributes) {super}
# end
# end

# if Async::Scheduler.method_defined?(:io_write)
# def io_write(io, buffer, length, offset = 0)
# attributes = {
# io: io.to_s,
# buffer: buffer,
# length: length,
# offset: offset,
# }

# Traces.trace("async.scheduler.io_write", attributes: attributes) {super}
# end
# end

# def process_wait(pid, flags)
# attributes = {
# pid: pid,
Expand Down

0 comments on commit 254482c

Please sign in to comment.