Modifying Exception logging mechanism