Added: logging mechanism