title: libuv logging best practice?
body: <p>I've got on my program a std::stringstream that is periodically flushed (with a timer) to a log file. The flushing and timer are on the default run loop.</p>
  
  <p>Other parts of the app just append to that std::stringstream and the timer takes care of the rest. I do limit the size of the stringstream (to 1mb) so I drop messages if the stream is "full".</p>
  
  <p>I'm just wondering, is this best practice for;</p>
  
  <ul>
  <li>performance? Is being on the main thread OK to handle this IO? Can I do better?</li>
  <li>Critical errors? The problem could be within my usage of libuv, which could mean that libuv based logging would be borked?</li>
  </ul>
  
  <p>How does node.js handle logging?</p>