mirror of
https://github.com/cmur2/dyndnsd.git
synced 2026-11-25 13:51:36 +01:00
tracing: add opentracing for rack and dyndnsd with configurable jaeger-client support and spanmanager
This commit is contained in:
1 parent
21857959b5
commit
8d4e96a1dd
9 files changed
+132
-28
No files matched your search
@@ -9,14 +9,19 @@ module Dyndnsd
|
||||
end
|
||||
|
||||
def update(zone)
|
||||
# write zone file in bind syntax
|
||||
File.open(@zone_file, 'w') { |f| f.write(@generator.generate(zone)) }
|
||||
# call user-defined command
|
||||
pid = fork do
|
||||
exec @command
|
||||
Helper.span('updater_update') do |span|
|
||||
span.set_tag('dyndnsd.updater.name', self.class.name.split('::').last)
|
||||
|
||||
# write zone file in bind syntax
|
||||
File.open(@zone_file, 'w') { |f| f.write(@generator.generate(zone)) }
|
||||
# call user-defined command
|
||||
pid = fork do
|
||||
exec @command
|
||||
end
|
||||
|
||||
# detach so children don't become zombies
|
||||
Process.detach(pid)
|
||||
end
|
||||
# detach so children don't become zombies
|
||||
Process.detach(pid)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in new issue
Block a user