Log exception message and class.