def canonical_write( str )
      return self if @io.nil?
      str = str.force_encoding(encoding) if encoding and str.encoding != encoding
      @io.syswrite str
      self
    rescue StandardError => err
      self.level = :off
      ::Logsly::Logging182.log_internal {"appender #{name.inspect} has been disabled"}
      ::Logsly::Logging182.log_internal(-2) {err}
    end
def canonical_write( str )
      return self if @io.nil?
      str = str.force_encoding(encoding) if encoding and str.encoding != encoding
      @io.syswrite str
      self
    rescue StandardError => err
      self.level = :off
      ::Logsly::Logging182.log_internal {"appender #{name.inspect} has been disabled"}
      ::Logsly::Logging182.log_internal(-2) {err}
    end
This method is called by the buffering code when messages need to be
 written to the logging destination.