Update - Added logging, perf data and refactor code