Method: Logging::Appenders::RollingFile#reopen
- Defined in:
- lib/logging/appenders/rolling_file.rb
#reopen ⇒ Object
Reopen the connection to the underlying logging destination. If the connection is currently closed then it will be opened. If the connection is currently open then it will be closed and immediately opened.
130 131 132 133 134 135 136 137 138 139 140 |
# File 'lib/logging/appenders/rolling_file.rb', line 130 def reopen @mutex.synchronize { if defined? @io && @io flush @io.close rescue nil end @io = open_file } super self end |