Implementing logging for trace level