As a quick note, I just got a little bit better about logging stack traces when writing Java or Scala code. In Scala I used to get the text from a stack trace and then log it like this:
// this works, but it's not too useful/readable logger.error(exception.getStackTrace.mkString("\n"))
In that code,
getStackTrace returns a sequence, which I convert to a
String before printing it.