Add logging to Main program