title: What are the best practices to write a log file on a web application?
body: <p>I'm currently creating a web application using node.js and I want to create log files. I want to know what the best practices are to create a log file. What fields should be included?
  For example, if I have a function <code>foo()</code> called by the service <code>service 1</code> should I add something like that on the log file:</p>
  
  <pre><code>[ dd:mm:yyyy hh:mm:ss ] foo was called by service1
  </code></pre>
  
  <p>What are the suitable things to include in such a file?</p>