Added ability to customize trace data captured for debugging purposes.