logging functionality is added.